glibc-2.3.2 build error

Nai Chang nchang at fairfield.com
Fri Jun 4 14:00:00 PDT 2004


I am building glibc-2.3.2 from LFS 5.0 (section 5.9 Installing Glibc-2.3.2) and
encountered a multiple definition error. Since this is not mentioned in
the LFS 5.0 book. Any idea how to fix this? Thanks for the help.
 
 
Nai Chang
 
 
(The following is a sample of the configure command and the linking error message)
 
 
[lfs at Linux6 glibc-build]$ ../glibc-2.3.2/configure --prefix=/tools --disable-profile
--enable-add-ons --with-headers=/tools/include --with-binutils=/tools/bin --without-gd

[lfs at Linux6 glibc-build]$ make
   .
   .
   .
make[2]: Leaving directory `/mnt/lfs/glibc-2.3.2/elf'
gcc -B/tools/bin/   -nostdlib -nostartfiles -r -o /mnt/lfs/glibc-build/libc_pic.os \
 -Wl,-d -Wl,--whole-archive /mnt/lfs/glibc-build/libc_pic.a
/mnt/lfs/glibc-build/libc_pic.a(iofread_u.os)(.text+0x0): In function `*__GI_fread_unlocked':
/mnt/lfs/glibc-2.3.2/libio/iofread_u.c:39: multiple definition of `__GI_fread_unlocked'
/mnt/lfs/glibc-build/libc_pic.a(iofread.os)(.text+0x0):/mnt/lfs/glibc-2.3.2/libio/iofread.c:36: first defined here
/mnt/lfs/glibc-build/libc_pic.a(iofputs_u.os)(.text+0x0): In function `*__GI_fputs_unlocked':
/mnt/lfs/glibc-2.3.2/libio/iofputs_u.c:36: multiple definition of `__GI_fputs_unlocked'
/mnt/lfs/glibc-build/libc_pic.a(iofputs.os)(.text+0x0):/mnt/lfs/glibc-2.3.2/libio/iofputs.c:35: first defined here
/tools/bin/ld: Warning: size of symbol `__GI_fputs_unlocked' changed from 224 in /mnt/lfs/glibc-build/libc_pic.a(iofputs_u.os) to 216 in /mnt/lfs/glibc-build/libc_pic.a(iofputs_u.os)
collect2: ld returned 1 exit status
make[1]: *** [/mnt/lfs/glibc-build/libc_pic.os] Error 1
make[1]: Leaving directory `/mnt/lfs/glibc-2.3.2'
make: *** [all] Error 2
 
[lfs at Linux6 glibc-build]$ 
[lfs at Linux6 glibc-build]$ # the following shows 3 libraries were built at this point:
[lfs at Linux6 glibc-build]$ 
[lfs at Linux6 glibc-build]$ ls -l *.a
-rw-r--r--   1 lfs      lfs      25623068 Jun  4 15:33 libc.a
-rw-r--r--   1 lfs      lfs         56348 Jun  4 15:33 libc_nonshared.a
-rw-r--r--   1 lfs      lfs      25515250 Jun  4 15:31 libc_pic.a

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfromscratch.org/pipermail/lfs-support/attachments/20040604/b154222e/attachment.html>


More information about the lfs-support mailing list