--- gmp-impl.h.dist +++ gmp-impl.h @@ -114,6 +114,10 @@ # endif #endif +#ifdef __sgi /* stdint.h is C99-only */ +typedef unsigned int uint_least32_t; +#endif + #ifdef __cplusplus #include <cstring> /* for strlen */ #include <string> /* for std::string */ --- gmp.h.dist +++ gmp.h @@ -353,6 +353,14 @@ #define _GMP_H_HAVE_VA_LIST 1 #endif +/* On IRIX, the va_list defintion can somehow get lost, even if <stdarg.h> + or <varargs.h> is included - (re)defining it here shouldn't break anything + and prevents build errors, although it is noisy. */ + +#ifdef __sgi +typedef char *va_list; +#endif + /* Test for gcc >= maj.min, as per __GNUC_PREREQ in glibc */ #if defined (__GNUC__) && defined (__GNUC_MINOR__) #define __GMP_GNUC_PREREQ(maj, min) \
[tefnut:gmp-4.3.1/work/gmp-4.3.1] % find . -name gmp.h [tefnut:gmp-4.3.1/work/gmp-4.3.1] % and for the Xth time, please attach a patch, your patch copied and pasted doesn't apply, which doesn't help me spend my time well, and doesn't help you get the patch in the tree. Thanks.
Created attachment 205573 [details, diff] Correct stdarg.h/stdint.h IRIX problems ... to be fair, it wouldn't have worked even if I had attached a file ;) gmp.h is generated from gmp-h.in during the build process - and I patched a previously failed build, and so didn't notice that thie file was new.
gmp already makes an attempt at defining uint_least32_t when C99 isnt available. throwing a typedef into the header kind of defeats that.
(In reply to comment #3) > gmp already makes an attempt at defining uint_least32_t when C99 isnt > available. throwing a typedef into the header kind of defeats that. > I'd agree if it worked - but the code builds on IRIX with this patch, and doesn't without. Go figure... (Note that the IRIX platform compilers are C99-compliant, but not GNU-compliant. Also, given that C99 is a C standard and not a C++ standard, anything built with CC/$CXX will not accept C99 syntax. This can be a problem when configure runs with cc/$CC and finds C99 compliance, but then builds with CC/$CXX and it is not longer available. I'm not sure if that's the problem in this case, though...)
We are sorry to close this bug. We lack the man-power and devotion to support mips-irix in the tree.