distutils & OS X universal binaries

Robin Becker robin at NOSPAMreportlab.com
Sun Dec 9 05:49:33 EST 2007


Martin v. Löwis wrote:
>> I prefer to continue using WORDS_BIGENDIAN so fewer changes need to be
>> made to the code. It just makes resynching with the upstream code
>> easier. If neither are defined we get to use the definition from
>> setup.py if it's needed.
> 
> 
> Ok. Still, I would write it as
> 
> #if defined(__LITTLE_ENDIAN__)
>   #undef WORDS_BIGENDIAN
> #elif defined(__BIG_ENDIAN__)
>   #undef WORDS_BIGENDIAN
>   #define WORDS_BIGENDIAN 1
> #endif
> 
> Regards,
> Martin
I'm never sure if undef gives an error if the variable isn't defined, 
but that is cleaner

thanks for the assistance
-- 
Robin Becker



More information about the Python-list mailing list