Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 15391 - ORBit2-2.6.0 fails to compile due to possible glibc-2.3.1 problem
Summary: ORBit2-2.6.0 fails to compile due to possible glibc-2.3.1 problem
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High major (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-02-09 17:50 UTC by Doug Goldstein (RETIRED)
Modified: 2003-10-12 15:34 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
A log file of the latest emerge (config.log,36.89 KB, text/plain)
2003-03-02 22:37 UTC, Doug Goldstein (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Doug Goldstein (RETIRED) gentoo-dev 2003-02-09 17:50:43 UTC
I have recompiled gcc and glibc and it hasn't fixed it. It's a problem in the
/usr/lib/libpthread.a obviously... as far as libdl not being included as the
possible cause in the compile line it has -ldl so that's not the problem...
Could it be that it's getting optimized out?

Reproducible: Always
Steps to Reproduce:
1. emerge gnome or emerge ORBit2
2.
3.

Actual Results:  
gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../include -I../../include -I../../src
-I../../src/ORBitutil -I../../src/orb -I../../src -I../../src/services/imodule
-DORBIT2_INTERNAL_API -DTEST_SRCDIR=\""../.."/test/everything\" -Wall -Wunused
-Wmissing-prototypes -Wmissing-declarations -pthread -I/usr/include/linc-1.0
-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -I/usr/include/libIDL-2.0
-I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include      -march=pentium3 -O3
-pipe -fomit-frame-pointer -fforce-addr -falign-functions=4
-fexpensive-optimizations -fprefetch-loop-arrays -ffast-math -funroll-loops
-foptimize-sibling-calls -maccumulate-outgoing-args -c client.c
/bin/sh ../../libtool --mode=link gcc  -march=pentium3 -O3 -pipe
-fomit-frame-pointer -fforce-addr -falign-functions=4 -fexpensive-optimizations
-fprefetch-loop-arrays -ffast-math -funroll-loops -foptimize-sibling-calls
-maccumulate-outgoing-args  -o client -static -module everything-skels.o
everything-stubs.o everything-common.o client.o ../../src/orb/libORBit-2.la
../../src/services/imodule/libORBit-imodule-2.la -Wl,--export-dynamic -lIDL-2
-lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0   -pthread -Wl,--export-dynamic
-llinc -lgthread-2.0 -lgobject-2.0 -lgmodule-2.0 -ldl -lglib-2.0   
gcc -march=pentium3 -O3 -pipe -fomit-frame-pointer -fforce-addr
-falign-functions=4 -fexpensive-optimizations -fprefetch-loop-arrays -ffast-math
-funroll-loops -foptimize-sibling-calls -maccumulate-outgoing-args -o client
everything-skels.o everything-stubs.o everything-common.o client.o
-Wl,--export-dynamic -pthread -Wl,--export-dynamic 
../../src/orb/.libs/libORBit-2.a -L/usr/lib -ldl /usr/lib/libpopt.a
../../src/services/imodule/.libs/libORBit-imodule-2.al /usr/lib/libIDL-2.a -ldl
-ldl /usr/lib/liblinc.a -lssl -lcrypto /usr/lib/libgthread-2.0.so
/usr/lib/libpthread.a -lm /usr/lib/libgobject-2.0.so /usr/lib/libgmodule-2.0.so
-ldl -ldl /usr/lib/libglib-2.0.so
/usr/lib/libpthread.a(pthread.o)(.text+0x136): In function
`__pthread_initialize_minimal':
: undefined reference to `_dl_cpuclock_offset'
/usr/lib/libpthread.a(pthread.o)(.text+0x13b): In function
`__pthread_initialize_minimal':
: undefined reference to `_dl_cpuclock_offset'
collect2: ld returned 1 exit status
make[3]: *** [client] Error 1
make[3]: Leaving directory
`/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0/test/everything'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0/test'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0'
make: *** [all-recursive-am] Error 2

!!! ERROR: gnome-base/ORBit2-2.6.0 failed.
!!! Function gnome2_src_compile, Line 41, Exitcode 2
!!! compile failure



Expected Results:  
Compiled successfully

Portage 2.0.46-r12 (default-x86-1.4, gcc-3.2.2, glibc-2.3.1-r3)
=================================================================
System uname: 2.5.46 i686 Pentium III (Coppermine)
GENTOO_MIRRORS="http://www.ibiblio.org/pub/Linux/distributions/gentoo"
CONFIG_PROTECT="/etc /var/qmail/control /usr/kde/2/share/config
/usr/kde/3/share/config /usr/X11R6/lib/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/gconf /etc/env.d"
PORTDIR="/usr/portage"
DISTDIR="/usr/portage/distfiles"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR_OVERLAY="/usr/local/portage/"
USE="x86 3dnow apm encode gif jpeg libg++ mikmod mmx mpeg ncurses pdflib png
qtmt spell xml2 xv zlib gdbm berkdb slang readline bonobo svga tcltk guile sdl
tcpd pam libwww ssl perl python esd imlib motif opengl cdr scanner X gtk -gnome
alsa -nls cups kde qt -gpm xmms mozilla crypt truetype gtk2 avi java oggvorbis
-arts quicktime -oss"
COMPILER="gcc3"
CHOST="i686-pc-linux-gnu"
CFLAGS="-march=pentium3 -O3 -pipe -fomit-frame-pointer -fforce-addr
-falign-functions=4 -fexpensive-optimizations -fprefetch-loop-arrays -ffast-math
-funroll-loops -foptimize-sibling-calls -maccumulate-outgoing-args"
CXXFLAGS="-march=pentium3 -O3 -pipe -fomit-frame-pointer -fforce-addr
-falign-functions=4 -fexpensive-optimizations -fprefetch-loop-arrays -ffast-math
-funroll-loops -foptimize-sibling-calls -maccumulate-outgoing-args"
ACCEPT_KEYWORDS="x86 ~x86"
MAKEOPTS="-j3"
AUTOCLEAN="yes"
SYNC="rsync://rsync2.us.gentoo.org/gentoo-portage"
FEATURES="sandbox ccache digest prelink"
Comment 1 foser (RETIRED) gentoo-dev 2003-02-09 18:20:13 UTC
yeah maybe lowering those mad opts is an idea, actually its the first thing you should do when something breaks.
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2003-02-09 21:14:44 UTC
(unpleasent comments directed to foser)

Firstly, glibc is compiled with -march=pentium3 -pipe -O2 and that's it. Secondly I've attempted to compile ORBit2 with the same optimizations. Thirdly it's something missing, not segfaulting.

And to make some additional notes to your wiseassness... The glibc ebuild locks optimizations down to -O2 anyway which is considered safe as is even -O3 as Mandrake and Redhat use -O3 on their glibc. And the problem exists in glibc files ( run a qpkg -f /usr/lib/libpthread.a and /usr/lib/libdl.(so|a) ) and not in ORBit 2 so I have NO IDEA why you sent it to the Gnome guys. As far as it being a glibc bug, if you actually researched or looked into bugs or possible issues with glibc then you'd know that the latest ~x86 ebuild of glibc which you can see that I'm using by emerge info has problems with some .a libraries which low and behold this is a .a library in glibc so I was making a bug note of a problem in it.
Comment 3 Doug Goldstein (RETIRED) gentoo-dev 2003-02-09 21:17:31 UTC
And it appears that something is weird with the nightly Phoenix I used to submit
that so I apologize for the lack of the word wrap.
Comment 4 foser (RETIRED) gentoo-dev 2003-02-10 06:40:46 UTC
well, if i see output and emerge info with those flags i assume you use them (and you did). Gentoo allows for mad opts, doesn't mean we have to support them.

Anyway, yeah i know glibc and gcc are smart enough to keep the flags down a bit and what RH and -any other distro here- does is their problem.

And sorry for my wiseassness, im only wasting my free time here for your pleasure, i know it was dumb to begin with.

If i weer you i'd recompile the whole binutils/gcc/glibc with some conservative opts (in that order).

Please reassign to Az or something, i do not feel like this flaming.

- sorry to flame in the first place, i shouldve been more mature -
Comment 5 Doug Goldstein (RETIRED) gentoo-dev 2003-02-12 02:09:35 UTC
I've now recompiled most of my system with -O2 -pipe -march=pentium3 and still have the same problem. I've even stepped down to glibc-2.3.1-r2 and gcc-3.2.1-r7 because gcc-3.2.2 started to cause some serious system issues for me. Still having this issue along with the fact that I can't load the hid module for my USB mouse cause of "keybdev" can't be found... but that's another story.
Comment 6 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-16 08:21:52 UTC
1) It compiles fine for me with glibc-2.3.1-r3.

2) I have checked bugzilla, but cannot find the problems you are referring to
   related to glibc-2.3.1-r3 and static libs.  Please point me in the correct
   direction so that I can try to fix those bugs.

3) Possible cause could be a missing /usr/lib/libpthread.so symlink .. check
   that you have it as a link to /lib/libpthread.so.0:

   ------------------------------------------------------------------------
    # ls /usr/lib/libpthread.so -l
     /usr/lib/libpthread.so -> ../../lib/libpthread.so.0
   ------------------------------------------------------------------------

   If that symlink is missing, it will cause ld to incorrectly link things
   to the static library which will have this effect.

4) The module issue was experienced after modutils update recently .. just
   recompile and install your kernel.  It is also an issue with 2.5 kernels,
   but should not prevent 'hid' from loading:

   -----------------------------------------------------
    # modprobe hid
    FATAL: Module keybdev not found.
    FATAL: Module mousedev not found.
    # lsmod | grep hid
    hid                    22784  0 
    usbcore                93172  4 hid,uhci_hcd
   -----------------------------------------------------

5) Why foser asked about optimizations, is that we have seen weird breakages
   with gcc3 and some optimizations.  Its usually a good place to start if we
   see a failure that we have not gotten before, and the user have all the
   -f* and -m* optimizations that comes out of the dark corners of gcc's info
   page *g*.   Anyhow, just a please understand, and be nice to foser type of
   thing =)
Comment 7 Doug Goldstein (RETIRED) gentoo-dev 2003-02-17 02:04:49 UTC
Still having the same problem.

Re: 2) It's a comment in the actual ebuild itself. I didn't search around on bugzilla for that info.

Re: 3) the symlink is there.

Re: 4) I ended up editing the ebuild to use modutils-2.4.20
Comment 8 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-17 14:49:06 UTC
Same system as the previous one that had the glibc-2.3.1 issues ?
Comment 9 Doug Goldstein (RETIRED) gentoo-dev 2003-02-18 18:34:38 UTC
Yes. This is all on one system.
Comment 10 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-19 18:34:40 UTC
Wanna have a shot at upgrading to gcc-3.2.2, binutils-2.13.90.0.18, and then
remerging glibc ?
Comment 11 Doug Goldstein (RETIRED) gentoo-dev 2003-02-24 08:56:36 UTC
Been running that version of binutils the whole time. I also tried this with gcc-3.2.2 and it didn't work and then I downgraded to gcc-3.2.1 to test but now I'm at gcc-3.2.2-r1 and still the same version of binutils. However Portage to upgrade me to glibc-2.3.2_pre1 and here are the errors I get.

/bin/sh ../../libtool --mode=link gcc  -march=pentium3 -O3 -pipe -fomit-frame-po
inter -fforce-addr -falign-functions=4 -fexpensive-optimizations -fprefetch-loop
-arrays -ffast-math -funroll-loops -foptimize-sibling-calls -maccumulate-outgoin
g-args  -o client -static -module everything-skels.o everything-stubs.o everythi
ng-common.o client.o ../../src/orb/libORBit-2.la ../../src/services/imodule/libO
RBit-imodule-2.la -Wl,--export-dynamic -lIDL-2 -lgobject-2.0 -lgmodule-2.0 -ldl
-lglib-2.0   -pthread -Wl,--export-dynamic -llinc -lgthread-2.0 -lgobject-2.0 -l
gmodule-2.0 -ldl -lglib-2.0
gcc -march=pentium3 -O3 -pipe -fomit-frame-pointer -fforce-addr -falign-function
s=4 -fexpensive-optimizations -fprefetch-loop-arrays -ffast-math -funroll-loops
-foptimize-sibling-calls -maccumulate-outgoing-args -o client everything-skels.o
 everything-stubs.o everything-common.o client.o -Wl,--export-dynamic -pthread -
Wl,--export-dynamic  ../../src/orb/.libs/libORBit-2.a -L/usr/lib -ldl /usr/lib/l
ibpopt.a ../../src/services/imodule/.libs/libORBit-imodule-2.al /usr/lib/libIDL-
2.a -ldl -ldl /usr/lib/liblinc.a -lssl -lcrypto /usr/lib/libgthread-2.0.so /usr/
lib/libpthread.a -lm /usr/lib/libgobject-2.0.so /usr/lib/libgmodule-2.0.so -ldl
-ldl /usr/lib/libglib-2.0.so
/usr/lib/libpthread.a(ptw-write.o)(.text+0x25): In function `__libc_write':
__libc_write: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-write.o)(.text+0x55):__libc_write: undefined reference
 to `__syscall_error'
/usr/lib/libpthread.a(ptw-read.o)(.text+0x25): In function `__libc_read':
__libc_read: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-read.o)(.text+0x55):__libc_read: undefined reference t
o `__syscall_error'
/usr/lib/libpthread.a(ptw-close.o)(.text+0x1f): In function `__libc_close':
__libc_close: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-close.o)(.text+0x4a):__libc_close: more undefined refe
rences to `__syscall_error' follow
/usr/lib/libpthread.a(pthread.o)(.text+0x67): In function `__pthread_initialize_
minimal':
: undefined reference to `_dl_cpuclock_offset'
/usr/lib/libpthread.a(pthread.o)(.text+0x6c): In function `__pthread_initialize_
minimal':
: undefined reference to `_dl_cpuclock_offset'
/usr/lib/libpthread.a(pthread.o)(.text+0x134): In function `pthread_initialize':
: undefined reference to `_res'
/usr/lib/libpthread.a(pthread.o)(.text+0xaf4): In function `__pthread_reset_main
_thread':
: undefined reference to `_errno'
/usr/lib/libpthread.a(pthread.o)(.text+0xaff): In function `__pthread_reset_main
_thread':
: undefined reference to `_h_errno'
/usr/lib/libpthread.a(pthread.o)(.text+0xb0a): In function `__pthread_reset_main
_thread':
: undefined reference to `_res'
/usr/lib/libpthread.a(pthread.o)(.data+0x1b8): undefined reference to `_errno'
/usr/lib/libpthread.a(pthread.o)(.data+0x1c0): undefined reference to `_h_errno'
/usr/lib/libpthread.a(pthread.o)(.data+0x1c8): undefined reference to `_res'
/usr/lib/libpthread.a(ptw-nanosleep.o)(.text+0x23): In function `__libc_nanoslee
p':
__libc_nanosleep: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-nanosleep.o)(.text+0x51):__libc_nanosleep: undefined r
eference to `__syscall_error'
collect2: ld returned 1 exit status
make[3]: *** [client] Error 1
make[3]: Leaving directory `/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0/test
/everything'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0/test
'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/ORBit2-2.6.0/work/ORBit2-2.6.0'
make: *** [all-recursive-am] Error 2

!!! ERROR: gnome-base/ORBit2-2.6.0 failed.
!!! Function gnome2_src_compile, Line 41, Exitcode 2
!!! compile failure
Comment 12 Martin Schlemmer (RETIRED) gentoo-dev 2003-02-24 09:32:57 UTC
Please include ORBit2's config.log.  For some reason it tries to link to all
the static version of things.
Comment 13 Doug Goldstein (RETIRED) gentoo-dev 2003-03-02 22:37:38 UTC
Created attachment 8886 [details]
A log file of the latest emerge
Comment 14 Doug Goldstein (RETIRED) gentoo-dev 2003-03-12 02:59:05 UTC
ping
Comment 15 Doug Goldstein (RETIRED) gentoo-dev 2003-03-16 16:14:54 UTC
gcc -march=pentium3 -O2 -pipe -o client everything-skels.o everything-stubs.o everything-common.o client.o -Wl,--export-dynamic -pthread -Wl,--export-dynamic  ../../src/orb/.libs/libORBit-2.a -L/usr/lib /usr/lib/libpopt.a ../../src/services/imodule/.libs/libORBit-imodule-2.a /usr/lib/libIDL-2.a /usr/lib/liblinc.a -lssl -lcrypto /usr/lib/libgthread-2.0.so /usr/lib/libpthread.a -lm /usr/lib/libgobject-2.0.so /usr/lib/libgmodule-2.0.so -ldl /usr/lib/libglib-2.0.so
/usr/lib/libpthread.a(ptw-write.o)(.text+0x25): In function `__libc_write':
__libc_write: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-write.o)(.text+0x55):__libc_write: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-read.o)(.text+0x25): In function `__libc_read':
__libc_read: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-read.o)(.text+0x55):__libc_read: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-close.o)(.text+0x1f): In function `__libc_close':
__libc_close: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-close.o)(.text+0x4a):__libc_close: more undefined references to `__syscall_error' follow
/usr/lib/libpthread.a(pthread.o)(.text+0x67): In function `__pthread_initialize_minimal':
: undefined reference to `_dl_cpuclock_offset'
/usr/lib/libpthread.a(pthread.o)(.text+0x6c): In function `__pthread_initialize_minimal':
: undefined reference to `_dl_cpuclock_offset'
/usr/lib/libpthread.a(pthread.o)(.text+0x134): In function `pthread_initialize':
: undefined reference to `_res'
/usr/lib/libpthread.a(pthread.o)(.text+0xaf4): In function `__pthread_reset_main_thread':
: undefined reference to `_errno'
/usr/lib/libpthread.a(pthread.o)(.text+0xaff): In function `__pthread_reset_main_thread':
: undefined reference to `_h_errno'
/usr/lib/libpthread.a(pthread.o)(.text+0xb0a): In function `__pthread_reset_main_thread':
: undefined reference to `_res'
/usr/lib/libpthread.a(pthread.o)(.data+0x1b8): undefined reference to `_errno'
/usr/lib/libpthread.a(pthread.o)(.data+0x1c0): undefined reference to `_h_errno'
/usr/lib/libpthread.a(pthread.o)(.data+0x1c8): undefined reference to `_res'
/usr/lib/libpthread.a(ptw-nanosleep.o)(.text+0x23): In function `__libc_nanosleep':
__libc_nanosleep: undefined reference to `__syscall_error'
/usr/lib/libpthread.a(ptw-nanosleep.o)(.text+0x51):__libc_nanosleep: undefined reference to `__syscall_error'
collect2: ld returned 1 exit status
make[3]: *** [client] Error 1
make[3]: Leaving directory `/var/tmp/portage/ORBit2-2.6.1/work/ORBit2-2.6.1/test/everything'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/ORBit2-2.6.1/work/ORBit2-2.6.1/test'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/ORBit2-2.6.1/work/ORBit2-2.6.1'
make: *** [all-recursive-am] Error 2

!!! ERROR: gnome-base/ORBit2-2.6.1 failed.
!!! Function gnome2_src_compile, Line 41, Exitcode 2
!!! compile failure
Comment 16 Martin Schlemmer (RETIRED) gentoo-dev 2003-04-08 15:02:59 UTC
I really do not know.  That box of yours got issues if you ask me :(  I cannot
repreduce, or figure what is causeing it, except that it tries to link to the
static libraries, and NOT the dynamic.
Comment 17 Martin Holzer (RETIRED) gentoo-dev 2003-10-12 15:34:34 UTC
latest stable ORBit2-2.8.1 works