History

setup.py, python/lib/: use sorted glob.glob to improve reproducibility

Paul Brossier committed 9 years ago

Commit 2e402311 parent 38202643 files · +4 −4Browse files

Showing the changes to python (2 of 3 files). Show all

Unified · Split

2 files
  1. python/lib/gen_external.py +1 −1
  2. python/lib/moresetuptools.py +2 −2
python/lib/gen_external.py+1−1
@@ -174,7 +174,7 @@ def print_cpp_output_results(lib, cpp_output): · 173 unmodified lines
174 174
175def generate_external(header=header, output_path=output_path, usedouble=False, overwrite=True):175def generate_external(header=header, output_path=output_path, usedouble=False, overwrite=True):
176 if not os.path.isdir(output_path): os.mkdir(output_path)176 if not os.path.isdir(output_path): os.mkdir(output_path)
177 elif not overwrite: return glob.glob(os.path.join(output_path, '*.c'))177 elif not overwrite: return sorted(glob.glob(os.path.join(output_path, '*.c')))
178 178
179 cpp_output, cpp_objects = get_cpp_objects(header)179 cpp_output, cpp_objects = get_cpp_objects(header)
180 180
python/lib/moresetuptools.py+2−2
@@ -58,8 +58,8 @@ def add_local_aubio_sources(ext, usedouble = False): · 57 unmodified lines
58 # create an empty header, macros will be passed on the command line58 # create an empty header, macros will be passed on the command line
59 fake_config_header = os.path.join('python', 'ext', 'config.h')59 fake_config_header = os.path.join('python', 'ext', 'config.h')
60 distutils.file_util.write_file(fake_config_header, "")60 distutils.file_util.write_file(fake_config_header, "")
61 aubio_sources = glob.glob(os.path.join('src', '**.c'))61 aubio_sources = sorted(glob.glob(os.path.join('src', '**.c')))
62 aubio_sources += glob.glob(os.path.join('src', '*', '**.c'))62 aubio_sources += sorted(glob.glob(os.path.join('src', '*', '**.c')))
63 ext.sources += aubio_sources63 ext.sources += aubio_sources
64 # define macros (waf puts them in build/src/config.h)64 # define macros (waf puts them in build/src/config.h)
65 for define_macro in ['HAVE_STDLIB_H', 'HAVE_STDIO_H',65 for define_macro in ['HAVE_STDLIB_H', 'HAVE_STDIO_H',

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t