From: "Tim Van Holder" To: Cc: , "Eli Zaretskii" Subject: Re: ANNOUNCE: Binutils 2.11 released Date: Fri, 27 Apr 2001 21:15:50 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) In-reply-to: <3028-Fri27Apr2001202824+0300-eliz@is.elta.co.il> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > Are you sure? Here's what I see in the assembly of a file whose name > was passed to GCC as an absolute file name: > > .file "command.c" > gcc2_compiled.: > ___gnu_compiled_c: > .stabs "d:/usr/djgpp/gnu/less-340/",100,0,0,Ltext0 > .stabs "d:/usr/djgpp/gnu/less-340/command.c",100,0,0,Ltext0 > > and here's what I see for a file whose name was simply command.c: > > .file "command.c" > gcc2_compiled.: > ___gnu_compiled_c: > .stabs "d:/usr/djgpp/gnu/less-340/",100,0,0,Ltext0 > .stabs "command.c",100,0,0,Ltext0 > > To me, this looks like the first entry is the leading directory, while > the second is supposed to be the basename. Close - first is the current dir, second is the path passed. With cwd=E:/Tmp, containing foo.c, I tried gcc -S foo.c gcc -S ../tmp/foo.c gcc -S /tmp/foo.c gcc -S e:/tmp/foo.c gcc -S e:\tmp/foo.c gcc -S e:\tmp\foo.c In each case, the first entry was "e:/Tmp/", and the second the path exactly as passed (with backslashes preserved). objdump -g shows as filenames for the above: E:/Tmp/foo.c E:/Tmp/../tmp/foo.c /tmp/foo.c e:/tmp/foo.c e:\tmp/foo.c e:\tmp\foo.c So I cannot reproduce the bug (either with my local cvs binutils, or Mark's 2.11 package) In any case, using the basename would be wrong, as that would break debug info for files compiled in a subdir (gcc -c foo/bar.c would produce a reference to $CWD/bar.c instead of $CWD/foo/bar.c).