failure building gcc-3.3 (broken libiberty/vsprintf.c or build?)

Kaveh R. Ghazi ghazi@caip.rutgers.edu
Tue May 20 20:59:00 GMT 2003


 > > gcc-3.3/lbiberty/vsprintf.c, indeed includes <varargs.h> (which gcc
 > > supplies), so if gcc-3.3 has killed support for varargs,h, why is
 > > libiberty/vsprintf.c trying to include it.
 > 
 > That code in libiberty is ancient.  If it's broken now, that means
 > that whoever dropped support for varargs.h didn't test it well enough.

FWIW, it appears to be fixed on mainline.  We can backport vsprintf.c
to 3.3.1 if you think it's worth fixing.  Here's the diff:

--- cvs-egcc-3.3/gcc/libiberty/vsprintf.c	2002-01-22 15:03:29.000000000 -0500
+++ cvs-egcc/gcc/libiberty/vsprintf.c	2003-04-15 16:34:40.516093000 -0400
@@ -26,9 +26,13 @@ the resulting executable to be covered b
 This exception does not however invalidate any other reasons why
 the executable file might be covered by the GNU General Public License. */
 
+#include <ansidecl.h>
+#ifdef ANSI_PROTOTYPES
+#include <stdarg.h>
+#else
 #include <varargs.h>
+#endif
 #include <stdio.h>
-#include <ansidecl.h>
 #undef vsprintf
 
 #if defined _IOSTRG && defined _IOWRT



------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com



More information about the crossgcc mailing list