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]

Patch installed to fix compilation of all m88k cross-targets


When cross-compiling any of the remaining m88k targets, I get an abort
when building underscore.c (used in collect2.)

Creating underscore.c requires running xgcc/cc1 on a trivially small
program (see the rule for s-under in the Makefile.)

I traced the abort to a call to fprintf in ASM_OUTPUT_SOURCE_FILENAME
which had its arguments reversed.  I fixed it by using fputs and
keeping the arguments in the order as they appeared.

Tested by cross-compiling cc1 and collect2 to:
m88k-unknown-aout m88k-unknown-openbsd m88k-unknown-sysv4

Installed as obvious.


2002-08-14  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>

	* m88k.h (ASM_OUTPUT_SOURCE_FILENAME): Fix incorrect argument
	order in call to fprintf.

diff -rup orig/egcc-CVS20020813/gcc/config/m88k/m88k.h egcc-CVS20020813/gcc/config/m88k/m88k.h
--- orig/egcc-CVS20020813/gcc/config/m88k/m88k.h	2002-07-30 22:07:56.000000000 -0400
+++ egcc-CVS20020813/gcc/config/m88k/m88k.h	2002-08-14 11:32:27.941909437 -0400
@@ -1734,7 +1734,7 @@ enum reg_class { NO_REGS, AP_REG, XRF_RE
 
 #define ASM_OUTPUT_SOURCE_FILENAME(FILE, NAME) \
   do {                                         \
-    fprintf (FILE_ASM_OP, FILE);               \
+    fputs (FILE_ASM_OP, FILE);                 \
     output_quoted_string (FILE, NAME);         \
     putc ('\n', FILE);                         \
   } while (0)


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