From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9118 invoked by alias); 28 Sep 2007 01:23:06 -0000 Received: (qmail 7938 invoked from network); 28 Sep 2007 01:22:49 -0000 Received: from unknown (202.108.59.148) by sourceware.org with QMTP; 28 Sep 2007 01:22:49 -0000 Received: (qmail 29329 invoked from network); 28 Sep 2007 09:17:13 +0800 Received: from unknown (HELO xchen) (Authenticated?user:?xchen@sunrisetelecom.com.cn@[219.142.163.192]) (envelope-sender ) by 0 (qmail-ldap-1.03) with SMTP for ; 28 Sep 2007 09:17:13 +0800 From: "xchen" To: "'xchen'" , Subject: RE: (Rising Spam Alert)gdb search wrong source file Date: Fri, 28 Sep 2007 03:39:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook, Build 11.0.5510 In-Reply-To: X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2007-09/txt/msg00238.txt.bz2 Message-ID: <20070928033900.BbdUQGNsPiCicspx4n4pmwgUvq6JqCma46j0xxhnTdM@z> I have solve this problem. I forgot to modify some makefile. -----Original Message----- From: gdb-owner@sourceware.org [mailto:gdb-owner@sourceware.org] On Behalf Of xchen Sent: 2007年9月27日 16:29 To: gdb@sourceware.org Subject: (Rising Spam Alert)gdb search wrong source file Hi, I use gdbserver run on my board. The problem is that gdb search wrong source file.Blowed is my snapshot. Breakpoint 1, 0x1000a5cc in main () (gdb) list 1 in ../sysdeps/powerpc/powerpc32/elf/start.S (gdb) info source Current source file is ../sysdeps/powerpc/powerpc32/elf/start.S Compilation directory is /var/tmp/BUILD/glibc-2.3.2/csu Source language is asm. Compiled with DWARF 2 debugging format. Does not include preprocessor macro info. (gdb) list 1 in ../sysdeps/powerpc/powerpc32/elf/start.S (gdb) info sharedlibrary >From To Syms Read Shared Object Library 0x0ff940c0 0x0ff9cc84 Yes /opt/montavista/pro/devkit/ppc/8xx/target/mnt/cf/shared/lib/libpthread.so.0 0x0ff5fc24 0x0ff63bb4 Yes /opt/montavista/pro/devkit/ppc/8xx/target/mnt/cf/shared/lib/librt.so.1 0x0feb9a78 0x0ff198bc Yes /opt/montavista/pro/devkit/ppc/8xx/target/mnt/cf/shared/lib/libstdc++.so.5 0x0fdae728 0x0fe1e998 Yes /opt/montavista/pro/devkit/ppc/8xx/target/mnt/cf/shared/lib/libm.so.6 0x0fd7da40 0x0fd86f3c Yes /opt/montavista/pro/devkit/ppc/8xx/target/lib/libgcc_s.so.1 0x0fc32ad0 0x0fd3a1fc Yes /opt/montavista/pro/devkit/ppc/8xx/target/lib/libc.so.6 0x30001f90 0x30013760 Yes /opt/montavista/pro/devkit/ppc/8xx/target/lib/ld.so.1 (gdb) pwd Working directory /home/chenxi/cpu_io_v106_20070910/cpu_v106_af/cpu_v/Debug. (gdb) show directories Source directories searched: $cdir:$cwd Library loaded correctly. I try to use dir to add all my path, but gdb think current source file is start.s. Actually root.cpp should be the current file. How can I make it right. BTW last month, gdbserver don't have this bug when I use it debug. Thx, Xi