scons,python: Add warning for when python3-config is not used
We cannot say for certain whether 'python-config' is python2 or python3, but this patch will produce a warning if 'python3-config' is not used, stating that support for python2 will be dropped in future releases of gem5. Change-Id: I114da359c8768071bf7dd7f2701aae85e3459678 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/35256 Reviewed-by: Jason Lowe-Power <power.jg@gmail.com> Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com> Maintainer: Jason Lowe-Power <power.jg@gmail.com> Maintainer: Andreas Sandberg <andreas.sandberg@arm.com> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
@@ -637,6 +637,10 @@ if main['USE_PYTHON']:
|
||||
main['PYTHON_CONFIG'])
|
||||
|
||||
print("Info: Using Python config: %s" % (python_config, ))
|
||||
if python_config != 'python3-config':
|
||||
warning('python3-config could not be found.\n'
|
||||
'Future releases of gem5 will drop support for python2.')
|
||||
|
||||
py_includes = readCommand([python_config, '--includes'],
|
||||
exception='').split()
|
||||
py_includes = list(filter(
|
||||
|
||||
Reference in New Issue
Block a user