public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: WENG Binyang <binyang.weng@forvia.com>
Cc: "gcc-help@gcc.gnu.org" <gcc-help@gcc.gnu.org>
Subject: Re: How to enable GLIBCXX & CXXABI in yocto
Date: Wed, 27 Apr 2022 10:26:54 +0100	[thread overview]
Message-ID: <CAH6eHdQdgvvs+crQbYENjmTnsVoLMr4PEpJtxYOXFgrNtRCgwA@mail.gmail.com> (raw)
In-Reply-To: <PR1P264MB3509D6C5852BBD80C38D588AF1FA9@PR1P264MB3509.FRAP264.PROD.OUTLOOK.COM>

On Wed, 27 Apr 2022 at 07:30, WENG Binyang <binyang.weng@forvia.com> wrote:
>
> Hi gcc-help team,
>
> I am working on create a arm toolchain by yocto.
> I confirmed the generated toolchain, but found no GLIBCXX_3.* and CXXABI in libstdc++ for arm64. Please refer to the following.
>
> xxx:~/Workspace/EMIRROR/sdk/linux/yocto-build/toolchain/sysroots/aarch64-linux/usr/lib$ strings libstdc++.so.6.0.28 | grep GLIBCXX
> GLIBCXX_FORCE_NEW
> GLIBCXX_DEBUG_MESSAGE_LENGTH
>
> Could you tell me how to enable GLIBCXX_3* and CXXABI in yocto build?

It depends on linker support and the value of the --enable-symvers
configure option.

See https://gcc.gnu.org/onlinedocs/libstdc++/manual/configure.html

--enable-symvers[=style]

In 3.1 and later, tries to turn on symbol versioning in the shared
library (if a shared library has been requested). Values for 'style'
that are currently supported are 'gnu', 'gnu-versioned-namespace',
'darwin', 'darwin-export', and 'sun'. Both gnu- options require that a
recent version of the GNU linker be in use. Both darwin options are
equivalent. With no style given, the configure script will try to
guess correct defaults for the host system, probe to see if additional
requirements are necessary and present for activation, and if so, will
turn symbol versioning on. This option can change the library ABI.

And the comments in libstdc++-v3/acinclude.m4

dnl
dnl Add version tags to symbols in shared library (or not), additionally
dnl marking other symbols as private/local (or not).
dnl
dnl Sets libtool_VERSION, and determines shared library SONAME.
dnl
dnl  This depends on GLIBCXX CHECK_LINKER_FEATURES, but without it assumes no.
dnl
dnl --enable-symvers=style adds a version script to the linker call when
dnl       creating the shared library.  The choice of version script is
dnl       controlled by 'style'.
dnl --disable-symvers does not.
dnl
dnl  +  Usage:  GLIBCXX_ENABLE_SYMVERS[(DEFAULT)]
dnl       Where DEFAULT is either 'yes' or 'no'.  Passing `yes' tries to
dnl       choose a default style based on linker characteristics.  Passing
dnl       'no' disables versioning.
dnl

  parent reply	other threads:[~2022-04-27  9:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-27  6:29 WENG Binyang
2022-04-27  7:03 ` Xi Ruoyao
2022-04-27  9:26 ` Jonathan Wakely [this message]
2022-04-28  1:59   ` WENG Binyang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAH6eHdQdgvvs+crQbYENjmTnsVoLMr4PEpJtxYOXFgrNtRCgwA@mail.gmail.com \
    --to=jwakely.gcc@gmail.com \
    --cc=binyang.weng@forvia.com \
    --cc=gcc-help@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).