This is the mail archive of the 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]

3.4 PATCH: Fix IRIX 6.5 internal/stdio_core.h

Analysing mips-sgi-irix6.5 testsuite failures, I came across two sets that
should have been fixed by fixincludes:

FAIL: gcc.c-torture/execute/920501-8.c compilation,  -O0 
/vol/gnu/src/gcc/gcc-dist/gcc/testsuite/gcc.c-torture/execute/920501-8.c:24: error: first argument to `va_arg' not of type `va_list'

FAIL: g++.old-deja/g++.other/vaarg1.C (test for excess errors)
Excess errors:
/vol/gnu/src/gcc/gcc-dist/gcc/testsuite/g++.old-deja/g++.other/vaarg1.C:12: error: invalid conversion from `void*' to `char*'

The first set happens because some recent IRIX 6.5 update moved the bulk of
stdio.h to internal/stdio_core.h.  So the change from va_list to
__gnuc_va_list didn't happen and the definition of va_list from the latter
file took effect.  Applying the stdio_va_list fix to internal/stdio_core.h
fixes this.

The second set happens for a similar reason: even the new
internal/stdio_core.h needs to irix_stdio_va_list fix to properly use
va_list in some prototypes.

This patch implements this and fixed the testsuite failures.  Verified by
rerunning failing tests manually, full bootstrap and regtest in progress
(mips-sgi-irix6.5 didn't bootstrap for some time).

Ok for mainline if it passes?


Rainer Orth, Faculty of Technology, Bielefeld University

Fri Jun 13 18:04:29 2003  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>

	* fixinc/inclhack.def (stdio_va_list): Apply to IRIX 6.5
	<internal/stdio_core.h> too.
	(irix_stdio_va_list): Likewise.
	* fixinc/fixincl.x: Regenerate.
Index: gcc/fixinc/inclhack.def
RCS file: /cvs/gcc/gcc/gcc/fixinc/inclhack.def,v
retrieving revision 1.157
diff -u -p -r1.157 inclhack.def
--- gcc/fixinc/inclhack.def	28 May 2003 11:53:34 -0000	1.157
+++ gcc/fixinc/inclhack.def	16 Jun 2003 18:20:23 -0000
@@ -1440,12 +1440,14 @@ fix = {
- *  IRIX 5.x's stdio.h declares some functions that take a va_list as
+ *  IRIX 5.x's stdio.h and IRIX 6.5's internal/stdio_core.h declare
+ *  some functions that take a va_list as
  *  taking char *.  However, GCC uses void * for va_list, so
  *  calling vfprintf with a va_list fails in C++.  */
 fix = {
     hackname  = irix_stdio_va_list;
     files     = stdio.h;
+    files     = internal/stdio_core.h;
     select = '(printf\(.*), /\* va_list \*/ char \*';
     c_fix  = format;
@@ -2332,6 +2334,7 @@ fix = {
 fix = {
     hackname = stdio_va_list;
     files    = stdio.h;
+    files    = internal/stdio_core.h;
     bypass   = '__gnuc_va_list|_BSD_VA_LIST_|__DJ_va_list|_G_va_list';

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