This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

input suffix


This fixes a problem with the input suffix code...  The problem is
that infiles[i].language can be 0 for normal input files for which we
want to set the input for.  This patch ensures we call set_input in
that case.  This regression was recently intruduced (2005).

Ok?  Ok for 4.2?

Doing diffs in .:
--- ./gcc.c.~1~	2007-05-10 10:39:19.000000000 -0700
+++ ./gcc.c	2007-05-31 17:15:56.000000000 -0700
@@ -6733,7 +6733,7 @@ main (int argc, char **argv)
       int i;
 
       for (i = 0; i < n_infiles ; i++)
-	if (infiles[i].language && infiles[i].language[0] != '*')
+	if (infiles[i].language == 0 || infiles[i].language[0] != '*')
 	  {
 	    set_input (infiles[i].name);
 	    break;
--------------


On darwin, this shows up as a regression in the ability to debug, due to dsymutil not
being called.

Before the fix:

mrs $ ./xgcc -B./ -v -g -lm /tmp/t.m -o /tmp/a.out -lm
Reading specs from ./specs
Target: powerpc-apple-darwin9
Configured with: ../gcc/configure --prefix=/Volumes/mrs3/Packages/gcc-20061107 --disable-bootstrap --enable-checking=assert --build=powerpc-apple-darwin9 --enable-werror build_alias=powerpc-apple-darwin9 --enable-languages=c,c++,fortran,java,objc,obj-c++,treelang --no-create --no-recursion
Thread model: posix
gcc version 4.3.0 20070516 (experimental)
 ./cc1obj -quiet -v -iprefix /Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/ -isystem ./include -isystem ./include-fixed -D__DYNAMIC__ /tmp/t.m -feliminate-unused-debug-symbols -mmacosx-version-min=10.1 -fPIC -quiet -dumpbase t.m -auxbase t -g -version -o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//ccyI1wMI.s
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/include-fixed"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/../../../../powerpc-apple-darwin9/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/include-fixed"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/../../../../powerpc-apple-darwin9/include"
#include "..." search starts here:
#include <...> search starts here:
 ./include
 ./include-fixed
 /usr/local/include
 /usr/include
 /System/Library/Frameworks
 /Library/Frameworks
End of search list.
GNU Objective-C version 4.3.0 20070516 (experimental) (powerpc-apple-darwin9)
    compiled by GNU C version 4.0.1 (Apple Computer, Inc. build 5449).
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 0f7a63a0fa4192362907f2a0ba961d01
 ./as -arch ppc -o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//cc2Fi4nc.o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//ccyI1wMI.s
 ./collect2 -dynamic -arch ppc -macosx_version_min 10.1 -weak_reference_mismatches non-weak -o /tmp/a.out -lcrt1.o ./crt2.o -L. -lm /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//cc2Fi4nc.o -lm -lgcc -lSystemStubs -lSystem

and after the fix:

mrs $ ./xgcc -B./ -v -g -lm /tmp/t.m -o /tmp/a.out -lm
Reading specs from ./specs
Target: powerpc-apple-darwin9
Configured with: ../gcc/configure --prefix=/Volumes/mrs3/Packages/gcc-20061107 --disable-bootstrap --enable-checking=assert --build=powerpc-apple-darwin9 --enable-werror build_alias=powerpc-apple-darwin9 --enable-languages=c,c++,fortran,java,objc,obj-c++,treelang --no-create --no-recursion
Thread model: posix
gcc version 4.3.0 20070524 (experimental)
 ./cc1obj -quiet -v -iprefix /Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/ -isystem ./include -isystem ./include-fixed -D__DYNAMIC__ /tmp/t.m -feliminate-unused-debug-symbols -mmacosx-version-min=10.1 -fPIC -quiet -dumpbase t.m -auxbase t -g -version -o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//ccskggyJ.s
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/include-fixed"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/powerpc-apple-darwin9/4.3.0/../../../../powerpc-apple-darwin9/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/include"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/include-fixed"
ignoring nonexistent directory "/Volumes/mrs3/net/gcc-darwin/gcc/../lib/gcc/../../lib/gcc/powerpc-apple-darwin9/4.3.0/../../../../powerpc-apple-darwin9/include"
#include "..." search starts here:
#include <...> search starts here:
 ./include
 ./include-fixed
 /usr/local/include
 /usr/include
 /System/Library/Frameworks
 /Library/Frameworks
End of search list.
GNU Objective-C version 4.3.0 20070516 (experimental) (powerpc-apple-darwin9)
    compiled by GNU C version 4.0.1 (Apple Computer, Inc. build 5449).
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 0f7a63a0fa4192362907f2a0ba961d01
 ./as -arch ppc -o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//cc365zjV.o /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//ccskggyJ.s
 ./collect2 -dynamic -arch ppc -macosx_version_min 10.1 -weak_reference_mismatches non-weak -o /tmp/a.out -lcrt1.o ./crt2.o -L. -lm /var/folders/DB/DB69CC19-49E5-4DC6-9BC8-5293FA5F9ADB.4382/TemporaryItems//cc365zjV.o -lm -lgcc -lSystemStubs -lSystem
 dsymutil /tmp/a.out

The significant point being the last line.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]