diff options
Diffstat (limited to 'test/SWIG/remove-modules.py')
-rw-r--r-- | test/SWIG/remove-modules.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/SWIG/remove-modules.py b/test/SWIG/remove-modules.py index 964970b..f5ce60d 100644 --- a/test/SWIG/remove-modules.py +++ b/test/SWIG/remove-modules.py @@ -56,6 +56,11 @@ if not os.path.exists(Python_h): # handle testing on other platforms: ldmodule_prefix = '_' +# On Windows, build a 32-bit exe if on 32-bit python. +if sys.platform == 'win32' and sys.maxsize <= 2**32: + swig_arch_var="TARGET_ARCH='x86'," +else: + swig_arch_var="" test.write("module.i", """\ %module modulename @@ -63,6 +68,7 @@ test.write("module.i", """\ test.write('SConstruct', """ foo = Environment(SWIGFLAGS='-python', + %(swig_arch_var)s CPPPATH=['%(python_include)s'], LDMODULEPREFIX='%(ldmodule_prefix)s', LDMODULESUFFIX='%(_dll)s', |