0

I'm compiling version 10.1 of GCC using the following configuration:

../configure --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --prefix=/home/user/toolchain/gcc  --enable-checking=release --enable-languages=c,c++,fortran --disable-multilib --enable-shared --enable-gnu-unique-object --with-linker-hash-style=gnu

After compilation is finished it seems i don't have any version symbols in the compiled listdc++.so:

> strings ./x86_64-linux-gnu/libstdc++-v3/src/.libs/libstdc++.so.6.0.28 | grep GLIBCXX
  GLIBCXX_FORCE_NEW
  GLIBCXX_DEBUG_MESSAGE_LENGTH

(and nothing else) (btw I get the same result if I 'make install' gcc before checking on the installed lib)

Going to another system, the same command issues (output truncated):

> strings /usr/lib64/libstdc++.so.6.0.28 | grep GLIBCXX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.5
[ ... ]
GLIBCXX_3.4.26
GLIBCXX_3.4.27
GLIBCXX_3.4.28
[ ... ]

Why am I not getting the version symbols in my freshly new compiled gcc/libstdc++ version ?

0
1

Actually found the error, when configuring GCC for the system, i found this in the config.log of libstdc++v3:

configure:74963: WARNING: === Linker version 2501 is too old for
configure:74965: WARNING: === full symbol versioning support in this release of GCC.
configure:74967: WARNING: === You would need to upgrade your binutils to version
configure:74969: WARNING: === 21400 or later and rebuild GCC.
configure:74971: WARNING: === Symbol versioning will be disabled.

Compiling a newer version of (binutils) ld and rebuilding gcc with it did the trick.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.