From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2484 invoked by alias); 19 Nov 2004 10:34:13 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 2394 invoked from network); 19 Nov 2004 10:34:02 -0000 Received: from unknown (HELO kharon.iss.org.ua) (212.109.61.230) by sourceware.org with SMTP; 19 Nov 2004 10:34:02 -0000 Received: from Vladimir (gizmo.iss.org.ua [212.109.61.228]) by kharon.iss.org.ua (8.13.1/8.13.1) with ESMTP id iAJAaO4a075657 for ; Fri, 19 Nov 2004 12:36:25 +0200 (EET) (envelope-from vladimir.vorobyov@iss.org.ua) Content-Type: text/plain; charset="us-ascii" From: Vladimir Vorobyov Organization: ISS To: gdb@sources.redhat.com Subject: pthreads debug with gdbserver Date: Fri, 19 Nov 2004 14:23:00 -0000 User-Agent: KMail/1.4.3 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200411191233.22357.vladimir.vorobyov@iss.org.ua> X-SW-Source: 2004-11/txt/msg00197.txt.bz2 Hi, Im using gbd 6.2 + gdbserver for m68k target and able to debug programs wit= h=20 it. But when I tried to debug application with pthreads I could not get=20 correct threads information. During debbuging I receive a well known SIG32 but searching this mail list = I=20 did not find the solution for my problem. What I did: ***************************************************************************= *************** [root@Vlad]# ./m68k-linux-gdb GNU gdb 6.2 Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain condition= s. Type "show copying" to see the conditions. There is absolutely no warranty for GDB. Type "show warranty" for details. This GDB was configured as "--host=3Di686-pc-linux-gnu --target=3Dm68k-linu= x". (gdb) file /tftpboot/Linux_BSP2/rootfsdir/bin/hello Reading symbols from=20 /opt/Embedix/home/vladimir/project/rootfsdir/bin/hello...done. (gdb) maintenance info breakpoints Num Type Disp Enb Address What -1 longjmp resume keep n 0x00000000 (gdb) set solib-absolute-prefix /tftpboot/Linux_BSP2/rootfsdir/ (gdb) target remote 192.168.1.27:3000 Remote debugging using 192.168.1.27:3000 0x400020c0 in ?? () (gdb) maintenance info breakpoints Num Type Disp Enb Address What -1 longjmp resume keep n 0x00000000 -2 shlib events keep y 0x4000dd04 (gdb) c Continuing. Program received signal SIG32, Real-time event 32. 0x400a8b2e in ?? () (gdb) maintenance info breakpoints Num Type Disp Enb Address What -1 longjmp resume keep n 0x00000000 -2 shlib events keep y 0x4000dd04 breakpoint already hit 3 times ***************************************************************************= ************************ I see that shlib breakpoint is set and hit but gdb does not load the=20 libraries. I can see in strace that it successfully loads ld.so. What shoul= d=20 I look at? Next, what libthread_db.so is for? It was not included for compilation for= =20 m68k target and I added it manually but when I try to load all libraries=20 manually using add-symbol-file, every library loads fine except=20 libthread_db.so - gdbserver reports "gbd: error initializing thread_db=20 library." If I type in gdb: info threads I always get only one thread. p.s. All libraries are not stripped. Any help would be very appreciated.