From 9c8c1dc3cba7ed4f1b745f3ab21f953631ef5d90 Mon Sep 17 00:00:00 2001 From: Thomas Spura Date: Sun, 15 Nov 2015 16:29:22 +0100 Subject: [PATCH] Try to disable zip_safe bug #1271776 --- python-setuptools.spec | 7 ++++++- setuptools-18.5-disable-zip-safe.patch | 12 ++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 setuptools-18.5-disable-zip-safe.patch diff --git a/python-setuptools.spec b/python-setuptools.spec index 7b0c25c..3a73dd8 100644 --- a/python-setuptools.spec +++ b/python-setuptools.spec @@ -27,7 +27,7 @@ Name: python-setuptools Version: 18.5 -Release: 2%{?dist} +Release: 3%{?dist} Summary: Easily build and distribute Python packages Group: Applications/System @@ -38,6 +38,7 @@ Source1: psfl.txt Source2: zpl.txt # add-setter-for-test_args.patch Patch1: add-setter-for-test_args.patch +Patch2: setuptools-18.5-disable-zip-safe.patch BuildArch: noarch BuildRequires: python2-devel @@ -101,6 +102,7 @@ execute the software that requires pkg_resources.py. %prep %setup -q -n %{srcname}-%{version} %patch1 -p1 +%patch2 # We can't remove .egg-info (but it doesn't matter, since it'll be rebuilt): # The problem is that to properly execute setuptools' setup.py, @@ -210,6 +212,9 @@ popd %endif # with_python3 %changelog +* Sun Nov 15 2015 Thomas Spura - 18.5-3 +- Try to disable zip_safe bug #1271776 + * Fri Nov 06 2015 Robert Kuska - 18.5-2 - Add patch so it is possible to set test_args variable diff --git a/setuptools-18.5-disable-zip-safe.patch b/setuptools-18.5-disable-zip-safe.patch new file mode 100644 index 0000000..d56ed21 --- /dev/null +++ b/setuptools-18.5-disable-zip-safe.patch @@ -0,0 +1,12 @@ +--- ./setuptools/command/bdist_egg.py.orig 2015-11-15 16:25:11.514387679 +0100 ++++ ./setuptools/command/bdist_egg.py 2015-11-15 16:25:16.096408293 +0100 +@@ -237,6 +237,9 @@ + os.unlink(path) + + def zip_safe(self): ++ log.warn("Setting zip_safe to False by default on Fedora!" ++ "See: https://bugzilla.redhat.com/show_bug.cgi?id=1271776") ++ return False + safe = getattr(self.distribution, 'zip_safe', None) + if safe is not None: + return safe