From 77c9be7998b85da24ae292f7eda1e478b32f2e64 Mon Sep 17 00:00:00 2001 From: dhewg Date: Mon, 23 Jan 2012 18:22:50 +0100 Subject: COMMON: Fix compilation with mingw-w64 setjmp and longjmp are being used in system headers. Allow these symbols globally instead of hacking the appropriate defines in every file including windows.h. --- common/forbidden.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'common') diff --git a/common/forbidden.h b/common/forbidden.h index 95c1a47d65..8b5a2f738e 100644 --- a/common/forbidden.h +++ b/common/forbidden.h @@ -182,7 +182,8 @@ #define putchar(a) FORBIDDEN_SYMBOL_REPLACEMENT #endif - +// mingw-w64 uses [set|long]jmp in system headers +#ifndef __MINGW64__ #ifndef FORBIDDEN_SYMBOL_EXCEPTION_setjmp #undef setjmp #define setjmp(a) FORBIDDEN_SYMBOL_REPLACEMENT @@ -192,6 +193,7 @@ #undef longjmp #define longjmp(a,b) FORBIDDEN_SYMBOL_REPLACEMENT #endif +#endif // __MINGW64__ #ifndef FORBIDDEN_SYMBOL_EXCEPTION_system #undef system -- cgit v1.2.3