diff --git a/SWIG/Lib/swigarch.i b/SWIG/Lib/swigarch.i index df4f2fcc6..019462f24 100644 --- a/SWIG/Lib/swigarch.i +++ b/SWIG/Lib/swigarch.i @@ -39,7 +39,7 @@ #ifndef LONG_MAX #include #endif -#if LONG_MAX != INT_MAX +#if (__WORDSIZE == 64) || (LONG_MAX != INT_MAX) # error "SWIG wrapped code invalid in 64 bit architecture, regenarete code using -DSWIGWORDSIZE64" #endif %} @@ -51,7 +51,7 @@ #ifndef LONG_MAX #include #endif -#if LONG_MAX == INT_MAX +#if (__WORDSIZE == 32) || (LONG_MAX == INT_MAX) # error "SWIG wrapped code invalid in 32 bit architecture, regenarete code using -DSWIGWORDSIZE32" #endif %}