This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: Patch to fix 2.1 versioned symbols for MIPS...
- From: "Steven J. Hill" <sjhill at cotw dot com>
- To: "H . J . Lu" <hjl at lucon dot org>
- Cc: libc-alpha at sources dot redhat dot com
- Date: Thu, 17 Jan 2002 15:18:10 -0600
- Subject: Re: Patch to fix 2.1 versioned symbols for MIPS...
- References: <3C470C57.A564636C@cotw.com> <20020117130741.A4847@lucon.org>
- Reply-to: sjhill at cotw dot com
"H . J . Lu" wrote:
>
> I see nothing wrong with the current glibc on mips. A symbol with the
> version name GLIBC_2.1 means it was introduced in glibc 2.1. Unless
> it is obsoleted by a new version, we still need it.
>
I disagree. There IS a problem. If I attempt to compile GLIBC for
target 'mipsel-linux'. Observe the output:
[SNIP]
a - elf/dl-sym.os
a - elf/unwind-dw2-fde-glibc.os
a - elf/framestate.os
: /opt/build-glibc/libc_pic.a
mipsel-linux-gcc -nostdlib -nostartfiles -r -o /opt/build-glibc/elf/librtld.os
'-Wl,-(' /opt/build-glibc/elf/dl-allobjs.os /opt/build-glibc/libc_pic.a -lgcc '
-Wl,-)'
mipsel-linux-gcc -nostdlib -nostartfiles -shared -o /opt/build-glibc/elf/ld.so
\
/opt/build-glibc/elf/librtld.os \
-Wl,--version-script=/opt/build-glibc/ld.map -Wl,-soname=ld.so.1
/opt/toolchains/mips/lib/gcc-lib/mipsel-linux/3.1/../../../../mipsel-linux/bin/l
d: /opt/build-glibc/elf/ld.so: undefined versioned symbol name __xstat64@GLIBC_2
.1
/opt/toolchains/mips/lib/gcc-lib/mipsel-linux/3.1/../../../../mipsel-linux/bin/l
d: failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status
make[2]: *** [/opt/build-glibc/elf/ld.so] Error 1
make[2]: Leaving directory `/opt/glibc-2.2.5/elf'
make[1]: *** [elf/subdir_lib] Error 2
make[1]: Leaving directory `/opt/glibc-2.2.5'
make: *** [all] Error 2
Now, let's see where the symbol is coming from:
root@dev1:/opt/build-glibc$ find . -name '*.o*' -exec mipsel-linux-nm -A {} \;
2>/dev/null | grep __xstat64\@GLIBC_2
./elf/librtld.os:000137e0 T __xstat64@GLIBC_2.1
./io/xstat64.os:00000000 T __xstat64@GLIBC_2.1
root@dev1:/opt/build-glibc$
-Steve
--
Steven J. Hill - Embedded SW Engineer