diff --git a/python-libsass.changes b/python-libsass.changes index 42224fe..a607ae0 100644 --- a/python-libsass.changes +++ b/python-libsass.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Sat Jul 14 12:24:38 UTC 2018 - bwiedemann@suse.com + +- Add reproducible.patch to sort .o files in linking + in order to make build reproducible (boo#1041090) + ------------------------------------------------------------------- Mon May 15 15:11:42 UTC 2017 - cbosdonnat@suse.com diff --git a/python-libsass.spec b/python-libsass.spec index d78d6a3..b2a7711 100644 --- a/python-libsass.spec +++ b/python-libsass.spec @@ -27,6 +27,8 @@ License: MIT Group: Development/Languages/Python Url: https://github.com/dahlia/libsass-python Source: %{_name}-%{version}.tar.gz +# PATCH-FIX-UPSTREAM 0.13.3 https://github.com/sass/libsass-python/pull/212 boo#1041090 +Patch0: reproducible.patch BuildRequires: %{python_module Cython} BuildRequires: %{python_module devel} @@ -50,6 +52,7 @@ with no Ruby stack at all! %prep %setup -n %{_name}-%{version} +%patch0 -p1 %build %python_build diff --git a/reproducible.patch b/reproducible.patch new file mode 100644 index 0000000..e3abc65 --- /dev/null +++ b/reproducible.patch @@ -0,0 +1,27 @@ +From 054e4e023addd996e832c6164cd4816a66f6234d Mon Sep 17 00:00:00 2001 +From: "Bernhard M. Wiedemann" +Date: Fri, 21 Jul 2017 05:14:46 +0200 +Subject: [PATCH] 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. +--- + setup.py | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/setup.py b/setup.py +index 3d7543a..bac0923 100644 +--- a/setup.py ++++ b/setup.py +@@ -141,6 +141,7 @@ def restore_cencode(): + else: + link_flags = ['-fPIC', '-lstdc++'] + ++sources.sort() + sass_extension = Extension( + '_sass', + sources,