diff options
author | Chris Lamb <chris@chris-lamb.co.uk> | 2017-09-05 20:24:16 +0100 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2017-09-05 14:24:16 -0500 |
commit | cb4d8026f0cf5e25a61ecb1deb644656ed3bc3be (patch) | |
tree | 3fa1290b710afbeb41c19f0633495d719f57708d /numpy/distutils/misc_util.py | |
parent | 7951a0947890ee481b06adbc9595331aef64dd3d (diff) | |
download | numpy-cb4d8026f0cf5e25a61ecb1deb644656ed3bc3be.tar.gz |
Make system_info output reproducible (#9652)
Whilst working on the Reproducible Builds effort [0], we noticed
that python-numpy generates output that is not reproducible. This
affects "downstream" packages such as numexpr.
This occurs as it encodes the absolute pathname into the generated file.
[0] https://reproducible-builds.org/
Signed-off-by: Chris Lamb <chris@chris-lamb.co.uk>
Diffstat (limited to 'numpy/distutils/misc_util.py')
-rw-r--r-- | numpy/distutils/misc_util.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/distutils/misc_util.py b/numpy/distutils/misc_util.py index 01376a7ff..102af874f 100644 --- a/numpy/distutils/misc_util.py +++ b/numpy/distutils/misc_util.py @@ -2278,7 +2278,7 @@ def generate_config_py(target): from distutils.dir_util import mkpath mkpath(os.path.dirname(target)) f = open(target, 'w') - f.write('# This file is generated by %s\n' % (os.path.abspath(sys.argv[0]))) + f.write('# This file is generated by numpy\'s %s\n' % (os.path.basename(sys.argv[0]))) f.write('# It contains system_info results at the time of building this package.\n') f.write('__all__ = ["get_info","show"]\n\n') |