mirror of
https://github.com/Cantera/cantera.git
synced 2025-02-25 18:55:29 -06:00
[SCons] Fix to skip Python startup messages
This fixes an issue when the Python interpreter prints startup messages that appear before the expected output lines. Known to be a problem with the Anaconda Python distribution.
This commit is contained in:
@@ -941,7 +941,7 @@ if env['python3_package'] in ('y', 'default'):
|
||||
info = getCommandOutput(env['python3_cmd'], '-c', script)
|
||||
(env['python3_version'],
|
||||
env['python3_usersitepackages'],
|
||||
cython_version) = info.splitlines()
|
||||
cython_version) = info.splitlines()[-3:]
|
||||
except OSError:
|
||||
info = False
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ def configure_numpy(python_command):
|
||||
"print(get_python_version())",
|
||||
"print(numpy.get_include())"))
|
||||
info = getCommandOutput(python_command, '-c', script)
|
||||
module_ext, py_version, numpy_include = info.splitlines()
|
||||
module_ext, py_version, numpy_include = info.splitlines()[-3:]
|
||||
|
||||
incDirs = (".", "../../include", numpy_include,
|
||||
localenv['sundials_include'], localenv['boost_inc_dir'])
|
||||
|
||||
Reference in New Issue
Block a user