diff options
author | Gary E. Miller <gem@rellim.com> | 2018-11-01 16:49:25 -0700 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2018-11-01 16:49:25 -0700 |
commit | 98ea16daf99bb38df1561b2e3fb39a0126cc3ca4 (patch) | |
tree | 047136ee93ff403dec02357e832d8c288bffe2bf /SConstruct | |
parent | 02d21faebec245e1526449fb54e7078914d75db7 (diff) | |
download | gpsd-98ea16daf99bb38df1561b2e3fb39a0126cc3ca4.tar.gz |
SConstruct: improve the error message when Python detection fails.
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -626,8 +626,7 @@ def GetPythonValue(context, name, imp, expr, brief=False): if not env['target_python']: status, value = 0, str(eval(expr)) else: - command = [target_python_path, '-c', - '%s; print(%s)' % (imp, expr)] + command = [target_python_path, '-c', '%s; print(%s)' % (imp, expr)] try: status, value = _getstatusoutput(command, shell=False) except OSError: @@ -636,7 +635,9 @@ def GetPythonValue(context, name, imp, expr, brief=False): value = value.strip() else: value = '' - announce("Python command failed - disabling Python.") + announce('Python command "%s" failed - disabling Python.\n' + 'Python components will NOT be installed' % + command[2]) env['python'] = False context.Result('failed' if status else 'ok' if brief else value) return value |