From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21570 invoked by alias); 24 Jun 2006 07:04:58 -0000 Received: (qmail 21561 invoked by uid 22791); 24 Jun 2006 07:04:57 -0000 X-Spam-Check-By: sourceware.org Received: from nitzan.inter.net.il (HELO nitzan.inter.net.il) (192.114.186.20) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 24 Jun 2006 07:04:56 +0000 Received: from HOME-C4E4A596F7 (IGLD-80-230-201-39.inter.net.il [80.230.201.39]) by nitzan.inter.net.il (MOS 3.7.3-GA) with ESMTP id DVQ27599 (AUTH halo1); Sat, 24 Jun 2006 10:04:52 +0300 (IDT) Date: Sat, 24 Jun 2006 07:08:00 -0000 Message-Id: From: Eli Zaretskii To: Joel Brobecker CC: gdb@sources.redhat.com In-reply-to: <20060624065920.GB22750@adacore.com> (message from Joel Brobecker on Fri, 23 Jun 2006 23:59:20 -0700) Subject: Re: Should "dir" override the full path encoded in debug info? Reply-to: Eli Zaretskii References: <20060623201019.GX22750@adacore.com> <20060624065920.GB22750@adacore.com> X-IsSubscribed: yes Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2006-06/txt/msg00204.txt.bz2 > Date: Fri, 23 Jun 2006 23:59:20 -0700 > From: Joel Brobecker > Cc: gdb@sources.redhat.com > > Next step, we debug the binary we copied. Because we know the relevant > sources are in dup, and not in the original location where they were > located when we did the built, the user used the "dir" command to > point GDB to the new location: > > (gdb) dir dup > Source directories searched: //dup:$cdir:$cwd > > But then, trying to print the contents of foo.c reveals that we display > the file from the original location. So the "dir" command was not taken > into account: > > (gdb) list foo.c:1 > warning: Source file is more recent than executable. What happens if you remove or rename the file foo.c in the original location?