PATCH: hpux NM_FLAGS
John David Anglin
dave@hiauly1.hia.nrc.ca
Mon May 7 21:00:00 GMT 2001
> The $CODE$ subspace names are for section symbols. I can think of ways
> that we could get section symbols for those truncated section names. Hmm,
> let me think on this a little.
Here is an example of the problem:
/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/../../gcc/g++ -B/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/../../gcc/ -ggdb3 -DDEBUG_ASSERT -ffunction-sections -fdata-sections -nostdinc++ -I/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/include -I/xxx/gnu/gcc-3.0/libstdc++-v3/include/std -I/xxx/gnu/gcc-3.0/libstdc++-v3/include/c_std -I/xxx/gnu/gcc-3.0/libstdc++-v3/include -I/xxx/gnu/gcc-3.0/libstdc++-v3/libsupc++ -I/xxx/gnu/gcc-3.0/libstdc++-v3/libio -I/xxx/gnu/gcc-3.0/libstdc++-v3/testsuite -nodefaultlibs /xxx/gnu/gcc-3.0/libstdc++-v3/testsuite/27_io/ios_manip_fmtflags.cc -o ./ios_manip_fmtflags.st-exe /xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/src/../libsupc++/.libs/libsupc++.a -L/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/src -L/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/src/.libs -lm -L/xxx/gnu/gcc-3.0/objdir/gcc -L/usr/local/hppa1.1-hp-hpux10.20/bin -L/usr/local/lib/gcc-lib/hppa1.1-hp-hpux10.2!
0/3.0 -L/usr/ccs/bin -L/usr/ccs/lib -L/opt/langtools/lib -L/usr/local/lib/gcc-lib/hppa1.1-hp-hpux10.20/3.0/../../.. -lgcc -lgcc /xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/src/.libs/libstdc++.a -lm -lm -lm -lgcc -lgcc -lm -lgcc -lgcc -lc -lgcc -lc -Wl,+b -Wl,/xxx/gnu/gcc-3.0/objdir/hppa1.1-hp-hpux10.20/libstdc++-v3/../../gcc
/xxx/gnu/gcc-3.0/libstdc++-v3/testsuite/27_io/ios_manip_fmtflags.cc:0: warning:
-ffunction-sections
may affect debugging on some targets.
/usr/ccs/bin/ld: Unsatisfied symbols:
_GLOBAL__I__ZNK4MyNP11do_truen (code)
_GLOBAL__D__ZNK4MyNP11do_truen (code)
collect2: ld returned 1 exit status
Generating ios_manip_fmtflags.o, it appears that the link error arises from
these two section symbols:
0000000000 t ._GLOBAL__D__ZNK4MyNP11do_truen
0000000000 t ._GLOBAL__I__ZNK4MyNP11do_truen
When section names aren't truncated, I believe collect2 would use
0000000003 T _GLOBAL__D__ZNK4MyNP11do_truenameEv
0000000003 T _GLOBAL__I__ZNK4MyNP11do_truenameEv
This seems like a collect problem, aggravated by truncating section
names and leaving the _GLOBAL_ part of the name.
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
More information about the Gcc-patches
mailing list