[pycrypto] compiling on AIX patch
Brent S. Elmer Ph.D.
webe3vt at aim.com
Wed May 7 12:55:22 PDT 2014
When building on AIX using the xlc family of compilers, -std=c99 is not
valid. Instead it should be -qlanglvl=stdc99. Here is a patch to
setup.py to test and apply the change.
$ diff -u setup.py ../../pycrypto-2.6.1/setup.py
--- setup.py 2013-10-14 17:38:10.000000000 -0400
+++ ../../pycrypto-2.6.1/setup.py 2014-05-07 15:39:32.000000000
-0400
@@ -118,8 +118,12 @@
self.__add_compiler_option("-std=c99")
# ... but don't tell that to the aCC compiler on HP-UX
+ # or the xlc compiler on AIX
if self.compiler.compiler_so[0] == 'cc' and
sys.platform.startswith('hp-ux'):
self.__remove_compiler_option("-std=c99")
+ elif self.compiler.compiler_so[0].startswith('xlc') and
sys.platform.startswith('aix'):
+ self.__remove_compiler_option("-std=c99")
+ self.__add_compiler_option("-qlanglvl=stdc99")
# Make assert() statements always work
self.__remove_compiler_option("-DNDEBUG")
More information about the pycrypto
mailing list