diff options
author | Mats Wichmann <mats@linux.com> | 2018-08-15 14:16:11 (GMT) |
---|---|---|
committer | Mats Wichmann <mats@linux.com> | 2018-08-15 14:16:11 (GMT) |
commit | 52ecb92eb30698b67de2662a892e20be3f1fda20 (patch) | |
tree | 4f93ce6501a5fa057005b5e5a72b4e819d9343de /test/SWIG/SWIGOUTDIR-python.py | |
parent | 2a39eb278ecca56f66011f2d602e12b924ad0e2c (diff) | |
download | SCons-52ecb92eb30698b67de2662a892e20be3f1fda20.zip SCons-52ecb92eb30698b67de2662a892e20be3f1fda20.tar.gz SCons-52ecb92eb30698b67de2662a892e20be3f1fda20.tar.bz2 |
Move checking for python header to common location
A previous change added a check for Python.h in one SWIG test which did
not have it which turns that test into a skip instead of a fail if the
header is not installed. It was pointed out that having 12 tests check
for the same thing might be optimised by putting the check in the routine
which returns info about the python development environment, so this
change makes that modification.
Signed-off-by: Mats Wichmann <mats@linux.com>
Diffstat (limited to 'test/SWIG/SWIGOUTDIR-python.py')
-rw-r--r-- | test/SWIG/SWIGOUTDIR-python.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/test/SWIG/SWIGOUTDIR-python.py b/test/SWIG/SWIGOUTDIR-python.py index db0cc95..53b5bdf 100644 --- a/test/SWIG/SWIGOUTDIR-python.py +++ b/test/SWIG/SWIGOUTDIR-python.py @@ -30,7 +30,6 @@ that Python files are created in the specified output directory. """ import TestSCons -import os import sys test = TestSCons.TestSCons() @@ -39,11 +38,8 @@ swig = test.where_is('swig') if not swig: test.skip_test('Can not find installed "swig", skipping test.\n') -python, python_include, python_libpath, python_lib = \ +python, python_include, python_libpath, python_lib, python_h = \ test.get_platform_python_info() -Python_h = os.path.join(python_include, 'Python.h') -if not os.path.exists(Python_h): - test.skip_test('Can not find %s, skipping test.\n' % Python_h) # On Windows, build a 32-bit exe if on 32-bit python. if sys.platform == 'win32' and sys.maxsize <= 2**32: |