Bug 110038 - Can't debug multithread programs with GDB
Can't debug multithread programs with GDB
Product: Red Hat Linux
Classification: Retired
Component: glibc (Show other bugs)
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jakub Jelinek
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2003-11-14 07:00 EST by Marco Fais
Modified: 2016-11-24 10:20 EST (History)
9 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-08-26 00:26:29 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Marco Fais 2003-11-14 07:00:33 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET 
CLR 1.1.4322)

Description of problem:

In the last glibc release for RedHat 8, the shared 
library /lib/libthread_db-1.0.so is stripped

root@dalmata[/lib]# file libthread_db-1.0.so 
libthread_db-1.0.so: ELF 32-bit LSB shared object, Intel 80386, 
version 1 (SYSV), stripped

This prevents multithread programs from being debugged with gdb.

This is the signal that I get:

Program received signal SIG32, Real-time event 32.
0x40038a35 in pthread_getconcurrency () from /lib/i686/libpthread.so.0

This problem is described here:


I'm currently rebuilding the glibc package to see if the unstripped 
library solve this problem.


Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Try to debug a multithread program
2. GDB doesn't handle properly some signals

Actual Results:  The program stops with a SIG32

Expected Results:  The programs continues making new threads and 
executing correctly

Additional info: The library is stripped also in the i686 package
Comment 1 Marco Fais 2003-11-14 07:04:10 EST
In the previous version (glibc-2.3.2-4.80.6) this library wasn't 

root@asgw[/lib]# file libthread_db-1.0.so 
libthread_db-1.0.so: ELF 32-bit LSB shared object, Intel 80386, 
version 1 (SYSV), not stripped

and multithreaded programs debug correctly with GDB.
Comment 2 Marco Fais 2003-11-14 19:23:46 EST
Seems that also this lib create problems to gdb when it's stripped:


In my case, rebuilding the glibc package without stripping:

solves all the problems with gdb and multithreaded programs.
Comment 3 Ulrich Drepper 2003-11-18 03:34:43 EST
Confirmed.  Some screwup in the build system which conflicts with the
settings in the RPM.  We'll probably provide a new version, but only
after we are sure we cover other potential problems with this errata.
Comment 4 R.K.Aa. 2004-02-10 11:56:52 EST
Has anything happened here? Or does anyone know of "contrib" packages
of a functional current glibc for RH8?
Comment 5 Ron Wolf 2004-03-22 16:15:55 EST
I'm having this problem, running RH8, with the latest glibc2.3.2-
4.80.8.  Has there been any updates since 2/10?
Comment 6 Keith McDuffee 2004-03-29 16:23:25 EST
In case anyone needs to know, here's the diff of the glibc.spec file
for rebuilding the RPM's with unstripped libraries using "rpmbuild -bb

# diff glibc.spec-orig glibc.spec
<     if [ "$i" = libc.so -o "$i" = libpthread.so ]; then
>     if [ "$i" = libc.so -o "$i" = libpthread.so -o "$i" =
libpthread-0.10.so -o "$i" = libthread_db-1.0.so ]; then

Comment 7 Ulrich Drepper 2004-08-26 00:26:29 EDT
Out-of-date release.  The current RPMs should not have any such
problems.  And if they have, a separate bug should be filed.

Note You need to log in before you can comment on or make changes to this bug.