Bug#261361: gcc-3.4: Please disable --enable-threads=posix for hurd-i386
Package: gcc-3.4
Severity: important
--enable-threads=posix results in pthreads (instead of cthreads) being
used on hurd-i386. However, there is a problem with this, resulting in
libgcc_s.so having undefined references. Jeroen Dekkers has summarized
the problem as follows:
|Michael Banck reported on IRC that the libgcc_s.so of the gcc 3.4
|debian packages fail with the following error:
|/lib/libgcc_s.so: undefined reference to `_pthread_mutex_lock'
|objdump -T /lib/libgcc_s.so | grep pthread gives the following:
|23:19 < azeem> 00000000 D *UND* 00000000 _pthread_mutex_lock
|23:19 < azeem> 00000000 w D *UND* 00000000 pthread_create
|23:19 < azeem> 00000000 w D *UND* 00000000 pthread_once
|23:19 < azeem> 00000000 w D *UND* 00000000 pthread_mutex_unlock
|The problem here is that gcc declares all the pthread functions weak
|with a #pragma weak. When calling pthread_mutex_lock() however, the
|inline function from /include/bits/mutex.h
|(libpthread/sysdeps/generic/bits/mutex.h in the Hurd sources) is used.
|This inline function calls _pthread_mutex_lock, which of course isn't
|declared weak by gcc.
(This is from
http://lists.gnu.org/archive/html/bug-hurd/2004-07/msg00106.html
)
Could you please not add --enable-threads=posix to $CONFARGS on
hurd-i386 for the time being, while the problem is being worked on
upstream?
thanks,
Michael
Reply to: