diff options
author | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-07-07 17:46:50 +0200 |
---|---|---|
committer | Bernhard Schommer <bernhardschommer@gmail.com> | 2015-07-07 17:46:50 +0200 |
commit | 437ac77449d759469ab4d5c8e0f37b80c0ad6e31 (patch) | |
tree | 4c8d9ae51d94ad26231da3102f55f4a2d56f7304 | |
parent | 0c7c17e087d91a8a61c5679df45f4b09c286d08b (diff) | |
download | compcert-437ac77449d759469ab4d5c8e0f37b80c0ad6e31.tar.gz compcert-437ac77449d759469ab4d5c8e0f37b80c0ad6e31.zip |
Better define the __GNUC__ macro which avoids the inclusion of va_list header and set the __VA_LIST macro if it is not defined.
-rwxr-xr-x | configure | 2 | ||||
-rw-r--r-- | runtime/include/stdarg.h | 4 |
2 files changed, 5 insertions, 1 deletions
@@ -113,7 +113,7 @@ case "$target" in struct_return="int1-8" system="diab" cc="${toolprefix}dcc" - cprepro="${toolprefix}dcc -E -D__Iva_list" + cprepro="${toolprefix}dcc -E -D__GNUC__" casm="${toolprefix}das" asm_supports_cfi=false clinker="${toolprefix}dcc" diff --git a/runtime/include/stdarg.h b/runtime/include/stdarg.h index b2e7eadd..272b6320 100644 --- a/runtime/include/stdarg.h +++ b/runtime/include/stdarg.h @@ -50,6 +50,10 @@ typedef __builtin_va_list __gnuc_va_list; typedef __builtin_va_list va_list; #endif +#ifndef __VA_LIST +#define __VA_LIST +#endif + #define va_start(v,l) __builtin_va_start(v,l) #define va_end(v) __builtin_va_end(v) #define va_arg(v,l) __builtin_va_arg(v,l) |