This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: ./map_insert.exe: relocation error: ./map_insert.exe: undefined symbol: _ZSt14_S_rb_tree_red
- From: Benjamin Kosnik <bkoz at redhat dot com>
- To: John David Anglin <dave at hiauly1 dot hia dot nrc dot ca>
- Cc: bug-binutils at gnu dot org, libstdc++ at gcc dot gnu dot org
- Date: Fri, 15 Feb 2002 09:43:16 -0800 (PST)
- Subject: Re: ./map_insert.exe: relocation error: ./map_insert.exe: undefined symbol: _ZSt14_S_rb_tree_red
> Are you sure?
Yep. I'm sure. Phil did an excellent job.
You'll see this with the link map support on when building the .so:
-Wl,--version-script=linker.map -Wl,-soname -Wl,libstdc++.so.4 -o
.libs/libstdc++.so.4.0.0
Without it:
-Wl,-soname -Wl,libstdc++.so.4 -o .libs/libstdc++.so.4.0.0
Then, after you've created a shared executable, the undefined symbols are
versioned, like so
nm a.out | grep GLIBCPP_3.1
[snip]
U _ZNSt6locale5_ImplC1ERKS0_j@@GLIBCPP_3.1
U _ZNSt6locale5facetC2Ej@@GLIBCPP_3.1
U _ZNSt6locale5facetD2Ev@@GLIBCPP_3.1
U _ZNSt6locale7classicEv@@GLIBCPP_3.1
ok?
-benjamin