diff --git a/python-bjoern.changes b/python-bjoern.changes index 18c1e5c..0a53e34 100644 --- a/python-bjoern.changes +++ b/python-bjoern.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Mar 13 03:20:57 UTC 2018 - bwiedemann@suse.com + +- Add reproducible.patch to make build reproducible (boo#1041090) + ------------------------------------------------------------------- Mon Feb 2 16:27:46 UTC 2015 - boris@steki.net diff --git a/python-bjoern.spec b/python-bjoern.spec index ffcfc5d..77e42cb 100644 --- a/python-bjoern.spec +++ b/python-bjoern.spec @@ -24,6 +24,7 @@ License: BSD-2-Clause Group: Development/Languages/Python Url: https://github.com/jonashaag/bjoern Source: http://pypi.python.org/packages/source/b/bjoern/bjoern-%{version}.tar.gz +Patch0: reproducible.patch BuildRequires: libev-devel BuildRequires: python-devel BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -36,6 +37,7 @@ A screamingly fast Python WSGI server written in C depending on libev. %prep %setup -q -n bjoern-%{version} +%patch0 -p1 %build CFLAGS="%{optflags}" python setup.py build diff --git a/reproducible.patch b/reproducible.patch new file mode 100644 index 0000000..b78f823 --- /dev/null +++ b/reproducible.patch @@ -0,0 +1,28 @@ +merged upstream + +commit 7e4227ea7e789a8e917b52c43adda3318c4062bb +Author: Bernhard M. Wiedemann +Date: Mon Jun 5 16:41:04 2017 +0200 + + sort input files + + when building packages (e.g. for openSUSE Linux) + (random) filesystem order of input files + influences ordering of functions in the output, + thus without the patch, builds (in disposable VMs) would usually differ. + + See https://reproducible-builds.org/ for why this matters. + +Index: bjoern-1.4.2/setup.py +=================================================================== +--- bjoern-1.4.2.orig/setup.py ++++ bjoern-1.4.2/setup.py +@@ -3,7 +3,7 @@ import glob + from distutils.core import setup, Extension + + SOURCE_FILES = [os.path.join('http-parser', 'http_parser.c')] + \ +- glob.glob(os.path.join('bjoern', '*.c')) ++ sorted(glob.glob(os.path.join('bjoern', '*.c'))) + + bjoern_extension = Extension( + '_bjoern',