diff options
author | Fred Wright <fw@fwright.net> | 2018-11-17 17:43:07 -0800 |
---|---|---|
committer | Fred Wright <fw@fwright.net> | 2018-11-17 17:43:07 -0800 |
commit | 294ad21471906c4d44d723f73e46aa68a4b9311e (patch) | |
tree | 5190cabab60e31914af8d8d52074558fbe9c45d0 /SConstruct | |
parent | e900dae226203d8d99f6fd7ce068ef7e50ee6bd3 (diff) | |
download | gpsd-294ad21471906c4d44d723f73e46aa68a4b9311e.tar.gz |
Make sure 'python-versions' uses the right Python.
Although in-tree testing is sometimes able to find the Python
libraries via program-relative addressing, later Python versions name
compiled extensions in a version-dependent manner. This means that
programs need to run with the specific version of Python that the
extensions were compiled for. This change invokes the "target_python"
explicitly for the version checks, rather than using the
system-default Python. This is the same approach that is taken by all
other Python-based tests.
TESTED:
The 'python-versions' test now passes with "target_python=python3.7",
while the system-default Python is 2.7. This is after already
building the extensions; another commit will add the missing
dependencies.
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1913,7 +1913,7 @@ if env['python']: verenv['DISPLAY'] = '' # Avoid launching X11 in X11 progs pp = [] for p in python_progs: - pp.append("$SRCDIR/%s -V" % p) + pp.append("$PYTHON $SRCDIR/%s -V" % p) python_versions = Utility('python-versions', python_progs, pp, ENV=verenv) else: |