public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* undefined versioned symbol from GLIBCPP_3.2
@ 2002-11-13 10:52 Nicolas F Rouquette
  2002-11-13 12:21 ` Nicolas F Rouquette
  0 siblings, 1 reply; 2+ messages in thread
From: Nicolas F Rouquette @ 2002-11-13 10:52 UTC (permalink / raw)
  To: gcc-help

Can someone provide some advice about resolving this type of error?

undefined versioned symbol name std::basic_string<char, 
std::char_traits<char>, std::allocator<char> >::find_first_not_of(char 
const*, unsigned, unsigned) const@@GLIBCPP_3.2

In principle, I understand that the linker is telling me that this 
versioned symbol isn't found in any of the libraries given.
However,  I'm puzzled that this is a symbol from the standard library, 
not one of my own.

I built from sources gcc 3.2 on RedHat 7.3.
I'm trying to link a shared library made of C++ object files.

/opt/gcc-3.2/bin/g++ -v-ldl -lpthread -lrt 
-Wl,-rpath-lin\k,/opt/gcc-3.2/lib -Wl,-rpath,/opt/gcc-3.2/lib [... 
object files ...] -shared -o mylib.so
Reading specs from /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/specs
Configured with: ../gcc-3.2/configure --prefix=/opt/gcc-3.2
Thread model: posix
gcc version 3.2
 /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/collect2 -m elf_i386 
-shared -o mylib.so /usr/lib/crti.o 
/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtbeginS.o  -L/lib 
-L/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2 
-L/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/../../.. -lstdc++ -ldl 
-lpthread -lrt -rpath-link /opt/gcc-3.2/lib -rpath /opt/gcc-3.2/lib
[... object files ...]
 -lstdc++ -lm -lgcc_s -lc -lgcc_s 
/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtendS.o /usr/lib/crtn.o
/usr/bin/ld: mylib.so: undefined versioned symbol name 
std::basic_string<char, std::char_traits<char>, std::allocator<char> 
 >::find_first_not_of(char const*, unsigned, unsigned) const@@GLIBCPP_3.2
/usr/bin/ld: failed to set dynamic section sizes: Bad value

Any suggestions?

-- Nicolas.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: undefined versioned symbol from GLIBCPP_3.2
  2002-11-13 10:52 undefined versioned symbol from GLIBCPP_3.2 Nicolas F Rouquette
@ 2002-11-13 12:21 ` Nicolas F Rouquette
  0 siblings, 0 replies; 2+ messages in thread
From: Nicolas F Rouquette @ 2002-11-13 12:21 UTC (permalink / raw)
  To: Nicolas F Rouquette; +Cc: gcc-help

I figured it out. It was a problem with the -rpath & -rpath-link 
options. -- Nicolas.

Nicolas F Rouquette wrote:

> Can someone provide some advice about resolving this type of error?
>
> undefined versioned symbol name std::basic_string<char, 
> std::char_traits<char>, std::allocator<char> >::find_first_not_of(char 
> const*, unsigned, unsigned) const@@GLIBCPP_3.2
>
> In principle, I understand that the linker is telling me that this 
> versioned symbol isn't found in any of the libraries given.
> However,  I'm puzzled that this is a symbol from the standard library, 
> not one of my own.
>
> I built from sources gcc 3.2 on RedHat 7.3.
> I'm trying to link a shared library made of C++ object files.
>
> /opt/gcc-3.2/bin/g++ -v-ldl -lpthread -lrt 
> -Wl,-rpath-lin\k,/opt/gcc-3.2/lib -Wl,-rpath,/opt/gcc-3.2/lib [... 
> object files ...] -shared -o mylib.so
> Reading specs from /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/specs
> Configured with: ../gcc-3.2/configure --prefix=/opt/gcc-3.2
> Thread model: posix
> gcc version 3.2
> /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/collect2 -m elf_i386 
> -shared -o mylib.so /usr/lib/crti.o 
> /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtbeginS.o  -L/lib 
> -L/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2 
> -L/opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/../../.. -lstdc++ 
> -ldl -lpthread -lrt -rpath-link /opt/gcc-3.2/lib -rpath /opt/gcc-3.2/lib
> [... object files ...]
> -lstdc++ -lm -lgcc_s -lc -lgcc_s 
> /opt/gcc-3.2/lib/gcc-lib/i686-pc-linux-gnu/3.2/crtendS.o /usr/lib/crtn.o
> /usr/bin/ld: mylib.so: undefined versioned symbol name 
> std::basic_string<char, std::char_traits<char>, std::allocator<char> 
> >::find_first_not_of(char const*, unsigned, unsigned) const@@GLIBCPP_3.2
> /usr/bin/ld: failed to set dynamic section sizes: Bad value
>
> Any suggestions?
>
> -- Nicolas.
>
>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-11-13 20:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-11-13 10:52 undefined versioned symbol from GLIBCPP_3.2 Nicolas F Rouquette
2002-11-13 12:21 ` Nicolas F Rouquette

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).