so that /usr/lib/systemd/tests/unit-tests/test-libsystemd-sym
builds in a reproducible way
in spite of non-deterministic filesystem readdir order
See https://reproducible-builds.org/ for why this is good.
This patch was done while working on reproducible builds for openSUSE.
}, symbols_from_source[] = {''')
for dirpath, _, filenames in sorted(os.walk(sys.argv[2])):
- for filename in filenames:
+ for filename in sorted(filenames):
if not filename.endswith(".c") and not filename.endswith(".h"):
continue
with open(os.path.join(dirpath, filename), "r") as f: