Disable Python hash seed randomization in brp-python-bytecompile

This change should help with byte-compilation reproducibility: https://bugzilla.redhat.com/show_bug.cgi?id=1686078
This commit is contained in:
Lumir Balhar 2020-07-23 08:09:55 +02:00
parent 5baaf4a99c
commit 5a7ab8f927
2 changed files with 8 additions and 1 deletions

View File

@ -114,6 +114,10 @@ fi
# For example, below /usr/lib/python2.6/, we're targeting /usr/bin/python2.6 # For example, below /usr/lib/python2.6/, we're targeting /usr/bin/python2.6
# and below /usr/lib/python3.1/, we're targeting /usr/bin/python3.1 # and below /usr/lib/python3.1/, we're targeting /usr/bin/python3.1
# Disable Python hash seed randomization
# This should help with byte-compilation reproducibility: https://bugzilla.redhat.com/show_bug.cgi?id=1686078
export PYTHONHASHSEED=0
shopt -s nullglob shopt -s nullglob
for python_libdir in `find "$RPM_BUILD_ROOT" -type d|grep -E "/usr/lib(64)?/python[0-9]\.[0-9]+$"`; for python_libdir in `find "$RPM_BUILD_ROOT" -type d|grep -E "/usr/lib(64)?/python[0-9]\.[0-9]+$"`;
do do

View File

@ -6,7 +6,7 @@
Summary: Red Hat specific rpm configuration files Summary: Red Hat specific rpm configuration files
Name: redhat-rpm-config Name: redhat-rpm-config
Version: 163 Version: 164
Release: 1%{?dist} Release: 1%{?dist}
# No version specified. # No version specified.
License: GPL+ License: GPL+
@ -211,6 +211,9 @@ install -p -m 644 -t %{buildroot}%{_rpmluadir}/fedora/srpm forge.lua
%{_rpmconfigdir}/macros.d/macros.kmp %{_rpmconfigdir}/macros.d/macros.kmp
%changelog %changelog
* Thu Jul 23 2020 Lumír Balhar <lbalhar@redhat.com> - 164-1
- Disable Python hash seed randomization in brp-python-bytecompile
* Tue Jul 21 2020 Jeff Law <law@redhat.com> - 163-1 * Tue Jul 21 2020 Jeff Law <law@redhat.com> - 163-1
- Enable LTO by default - Enable LTO by default