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

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


 > > 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



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