[python] 2.7.3-17: remove "_default_patch_fuzz" directive
dmalcolm
dmalcolm at fedoraproject.org
Tue Feb 19 20:20:35 UTC 2013
commit 42d74be7420b3f424e74b1eed5fb4a48dfa33716
Author: David Malcolm <dmalcolm at redhat.com>
Date: Tue Feb 19 15:19:54 2013 -0500
2.7.3-17: remove "_default_patch_fuzz" directive
* Tue Feb 19 2013 David Malcolm <dmalcolm at redhat.com> - 2.7.3-17
- remove "_default_patch_fuzz" directive to avoid patches being silently
misapplied (refresh patch 1, patch 101, patch 102, patch 111, patch 121,
patch 158; rename patch 1, patch 101, patch 121; apply patch 54 before the
lib64 patches to avoid fuzz problems caused by the conditional application
of the lib64 patches)
....2.1-pydocnogui.patch => 00001-pydocnogui.patch | 15 ++++++-----
00101-lib64-regex.patch | 19 ++++++++++++++
00111-no-static-lib.patch | 16 ++++++------
00121-revert-r79310.patch | 13 +++++++++
00158-fix-hashlib-leak.patch | 20 +++++++-------
python-2.3.4-lib64-regex.patch | 18 -------------
python-2.7.3-lib64.patch | 22 ++++++++--------
python-2.7rc2-r79310.patch | 27 --------------------
python.spec | 22 ++++++++++------
9 files changed, 83 insertions(+), 89 deletions(-)
---
diff --git a/Python-2.2.1-pydocnogui.patch b/00001-pydocnogui.patch
similarity index 75%
rename from Python-2.2.1-pydocnogui.patch
rename to 00001-pydocnogui.patch
index da22ac3..3b34842 100644
--- a/Python-2.2.1-pydocnogui.patch
+++ b/00001-pydocnogui.patch
@@ -1,6 +1,7 @@
---- Python-2.2.1/Lib/pydoc.py.nogui 2002-07-08 18:32:47.000000000 -0400
-+++ Python-2.2.1/Lib/pydoc.py 2002-07-08 18:33:37.000000000 -0400
-@@ -18,9 +18,6 @@
+diff -up Python-2.7.3/Lib/pydoc.py.no_gui Python-2.7.3/Lib/pydoc.py
+--- Python-2.7.3/Lib/pydoc.py.no_gui 2012-04-09 19:07:31.000000000 -0400
++++ Python-2.7.3/Lib/pydoc.py 2013-02-19 13:48:44.480054515 -0500
+@@ -19,9 +19,6 @@ of all available modules.
Run "pydoc -p <port>" to start an HTTP server on a given port on the
local machine to generate documentation web pages.
@@ -9,8 +10,8 @@
-
Run "pydoc -w <name>" to write out the HTML documentation for a module
to a file named "<name>.html".
- """
-@@ -2043,9 +2040,6 @@
+
+@@ -2290,9 +2287,6 @@ def cli():
writing = 0
for opt, val in opts:
@@ -20,7 +21,7 @@
if opt == '-k':
apropos(val)
return
-@@ -2099,13 +2093,10 @@
+@@ -2346,13 +2340,10 @@ def cli():
%s -p <port>
Start an HTTP server on the given port on the local machine.
@@ -34,4 +35,4 @@
-""" % (cmd, os.sep, cmd, cmd, cmd, cmd, os.sep)
+""" % (cmd, os.sep, cmd, cmd, cmd, os.sep)
- if __name__ == '__main__': cli()
+ if __name__ == '__main__': cli()
diff --git a/00101-lib64-regex.patch b/00101-lib64-regex.patch
new file mode 100644
index 0000000..e399390
--- /dev/null
+++ b/00101-lib64-regex.patch
@@ -0,0 +1,19 @@
+diff -up Python-2.7.3/Lib/test/test_re.py.lib64-regex Python-2.7.3/Lib/test/test_re.py
+--- Python-2.7.3/Lib/test/test_re.py.lib64-regex 2012-04-09 19:07:32.000000000 -0400
++++ Python-2.7.3/Lib/test/test_re.py 2013-02-19 13:53:57.624033102 -0500
+@@ -757,6 +757,15 @@ class ReTests(unittest.TestCase):
+ self.assertRaises(TypeError, re.finditer, "a", {})
+ self.assertRaises(OverflowError, _sre.compile, "abc", 0, [long_overflow])
+
++ def test_bug_931848(self):
++ try:
++ unicode
++ except NameError:
++ pass
++ pattern = eval('u"[\u002E\u3002\uFF0E\uFF61]"')
++ self.assertEqual(re.compile(pattern).split("a.b.c"),
++ ['a','b','c'])
++
+ def run_re_tests():
+ from test.re_tests import tests, SUCCEED, FAIL, SYNTAX_ERROR
+ if verbose:
diff --git a/00111-no-static-lib.patch b/00111-no-static-lib.patch
index 61375b3..c331454 100644
--- a/00111-no-static-lib.patch
+++ b/00111-no-static-lib.patch
@@ -1,7 +1,7 @@
-diff -up Python-2.7rc1/Makefile.pre.in.no-static-lib Python-2.7rc1/Makefile.pre.in
---- Python-2.7rc1/Makefile.pre.in.no-static-lib 2010-06-06 14:47:52.929975429 -0400
-+++ Python-2.7rc1/Makefile.pre.in 2010-06-06 14:48:34.163350302 -0400
-@@ -393,7 +393,7 @@ coverage:
+diff -up Python-2.7.3/Makefile.pre.in.no-static-lib Python-2.7.3/Makefile.pre.in
+--- Python-2.7.3/Makefile.pre.in.no-static-lib 2013-02-19 14:03:40.801993224 -0500
++++ Python-2.7.3/Makefile.pre.in 2013-02-19 14:04:44.070988898 -0500
+@@ -397,7 +397,7 @@ coverage:
# Build the interpreter
@@ -10,8 +10,8 @@ diff -up Python-2.7rc1/Makefile.pre.in.no-static-lib Python-2.7rc1/Makefile.pre.
$(LINKCC) $(CFLAGS) $(LDFLAGS) $(LINKFORSHARED) -o $@ \
Modules/python.o \
$(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
-@@ -409,18 +409,6 @@ sharedmods: $(BUILDPYTHON)
- *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' LDFLAGS='$(LDFLAGS)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
+@@ -413,18 +413,6 @@ sharedmods: $(BUILDPYTHON)
+ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
esac
-# Build static library
@@ -28,8 +28,8 @@ diff -up Python-2.7rc1/Makefile.pre.in.no-static-lib Python-2.7rc1/Makefile.pre.
-
libpython$(VERSION).so: $(LIBRARY_OBJS)
if test $(INSTSONAME) != $(LDLIBRARY); then \
- $(LDSHARED) $(LDFLAGS) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
-@@ -1002,18 +990,6 @@ libainstall: all python-config
+ $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
+@@ -1021,18 +1009,6 @@ libainstall: all python-config
else true; \
fi; \
done
diff --git a/00121-revert-r79310.patch b/00121-revert-r79310.patch
new file mode 100644
index 0000000..02b0d47
--- /dev/null
+++ b/00121-revert-r79310.patch
@@ -0,0 +1,13 @@
+diff -up Python-2.7.3/Lib/site.py.00121 Python-2.7.3/Lib/site.py
+--- Python-2.7.3/Lib/site.py.00121 2013-02-19 14:07:19.156978291 -0500
++++ Python-2.7.3/Lib/site.py 2013-02-19 14:07:19.233978288 -0500
+@@ -123,7 +123,7 @@ def addbuilddir():
+ s = "build/lib.%s-%.3s" % (get_platform(), sys.version)
+ if hasattr(sys, 'gettotalrefcount'):
+ s += '-pydebug'
+- s = os.path.join(os.path.dirname(sys.path.pop()), s)
++ s = os.path.join(os.path.dirname(sys.path[-1]), s)
+ sys.path.append(s)
+
+
+diff -up Python-2.7.3/Misc/NEWS.00121 Python-2.7.3/Misc/NEWS
diff --git a/00158-fix-hashlib-leak.patch b/00158-fix-hashlib-leak.patch
index e8fcf1c..12e7866 100644
--- a/00158-fix-hashlib-leak.patch
+++ b/00158-fix-hashlib-leak.patch
@@ -1,7 +1,7 @@
-diff --git a/Lib/test/test_hashlib.py b/Lib/test/test_hashlib.py
---- a/Lib/test/test_hashlib.py
-+++ b/Lib/test/test_hashlib.py
-@@ -108,12 +108,8 @@ class HashLibTestCase(unittest.TestCase)
+diff -up Python-2.7.3/Lib/test/test_hashlib.py.fix-hashlib-leak Python-2.7.3/Lib/test/test_hashlib.py
+--- Python-2.7.3/Lib/test/test_hashlib.py.fix-hashlib-leak 2013-02-19 14:13:44.000000000 -0500
++++ Python-2.7.3/Lib/test/test_hashlib.py 2013-02-19 14:14:31.319948742 -0500
+@@ -106,12 +106,8 @@ class HashLibTestCase(unittest.TestCase)
_algo.islower()]))
def test_unknown_hash(self):
@@ -14,12 +14,12 @@ diff --git a/Lib/test/test_hashlib.py b/Lib/test/test_hashlib.py
+ self.assertRaises(ValueError, hashlib.new, 'spam spam spam spam spam')
+ self.assertRaises(TypeError, hashlib.new, 1)
- def test_get_builtin_constructor(self):
- get_builtin_constructor = hashlib.__dict__[
-diff --git a/Modules/_hashopenssl.c b/Modules/_hashopenssl.c
---- a/Modules/_hashopenssl.c
-+++ b/Modules/_hashopenssl.c
-@@ -477,6 +477,7 @@ EVP_new(PyObject *self, PyObject *args,
+ def test_hexdigest(self):
+ for name in self.supported_hash_names:
+diff -up Python-2.7.3/Modules/_hashopenssl.c.fix-hashlib-leak Python-2.7.3/Modules/_hashopenssl.c
+--- Python-2.7.3/Modules/_hashopenssl.c.fix-hashlib-leak 2013-02-19 14:13:44.646951933 -0500
++++ Python-2.7.3/Modules/_hashopenssl.c 2013-02-19 14:13:44.715951929 -0500
+@@ -549,6 +549,7 @@ EVP_new(PyObject *self, PyObject *args,
}
if (!PyArg_Parse(name_obj, "s", &name)) {
diff --git a/python-2.7.3-lib64.patch b/python-2.7.3-lib64.patch
index 470b48b..7b02a01 100644
--- a/python-2.7.3-lib64.patch
+++ b/python-2.7.3-lib64.patch
@@ -1,6 +1,6 @@
diff -up Python-2.7.3/Lib/distutils/command/install.py.lib64 Python-2.7.3/Lib/distutils/command/install.py
--- Python-2.7.3/Lib/distutils/command/install.py.lib64 2012-04-09 19:07:29.000000000 -0400
-+++ Python-2.7.3/Lib/distutils/command/install.py 2012-04-11 17:56:41.848587174 -0400
++++ Python-2.7.3/Lib/distutils/command/install.py 2013-02-19 13:58:20.446015129 -0500
@@ -42,14 +42,14 @@ else:
INSTALL_SCHEMES = {
'unix_prefix': {
@@ -20,7 +20,7 @@ diff -up Python-2.7.3/Lib/distutils/command/install.py.lib64 Python-2.7.3/Lib/di
'data' : '$base',
diff -up Python-2.7.3/Lib/distutils/sysconfig.py.lib64 Python-2.7.3/Lib/distutils/sysconfig.py
--- Python-2.7.3/Lib/distutils/sysconfig.py.lib64 2012-04-09 19:07:29.000000000 -0400
-+++ Python-2.7.3/Lib/distutils/sysconfig.py 2012-04-11 17:56:41.849587162 -0400
++++ Python-2.7.3/Lib/distutils/sysconfig.py 2013-02-19 13:58:20.446015129 -0500
@@ -114,8 +114,12 @@ def get_python_lib(plat_specific=0, stan
prefix = plat_specific and EXEC_PREFIX or PREFIX
@@ -37,7 +37,7 @@ diff -up Python-2.7.3/Lib/distutils/sysconfig.py.lib64 Python-2.7.3/Lib/distutil
else:
diff -up Python-2.7.3/Lib/site.py.lib64 Python-2.7.3/Lib/site.py
--- Python-2.7.3/Lib/site.py.lib64 2012-04-09 19:07:31.000000000 -0400
-+++ Python-2.7.3/Lib/site.py 2012-04-11 17:56:41.850587149 -0400
++++ Python-2.7.3/Lib/site.py 2013-02-19 13:58:20.447015128 -0500
@@ -300,12 +300,16 @@ def getsitepackages():
if sys.platform in ('os2emx', 'riscos'):
sitepackages.append(os.path.join(prefix, "Lib", "site-packages"))
@@ -57,7 +57,7 @@ diff -up Python-2.7.3/Lib/site.py.lib64 Python-2.7.3/Lib/site.py
# for framework builds *only* we add the standard Apple
diff -up Python-2.7.3/Lib/test/test_site.py.lib64 Python-2.7.3/Lib/test/test_site.py
--- Python-2.7.3/Lib/test/test_site.py.lib64 2012-04-09 19:07:32.000000000 -0400
-+++ Python-2.7.3/Lib/test/test_site.py 2012-04-11 17:58:52.981947780 -0400
++++ Python-2.7.3/Lib/test/test_site.py 2013-02-19 13:58:20.447015128 -0500
@@ -241,17 +241,20 @@ class HelperFunctionsTests(unittest.Test
self.assertEqual(dirs[2], wanted)
elif os.sep == '/':
@@ -84,8 +84,8 @@ diff -up Python-2.7.3/Lib/test/test_site.py.lib64 Python-2.7.3/Lib/test/test_sit
class PthFile(object):
diff -up Python-2.7.3/Makefile.pre.in.lib64 Python-2.7.3/Makefile.pre.in
---- Python-2.7.3/Makefile.pre.in.lib64 2012-04-11 17:56:41.829587411 -0400
-+++ Python-2.7.3/Makefile.pre.in 2012-04-11 17:56:41.852587123 -0400
+--- Python-2.7.3/Makefile.pre.in.lib64 2013-02-19 13:58:20.435015131 -0500
++++ Python-2.7.3/Makefile.pre.in 2013-02-19 13:58:20.447015128 -0500
@@ -97,7 +97,7 @@ LIBDIR= @libdir@
MANDIR= @mandir@
INCLUDEDIR= @includedir@
@@ -97,7 +97,7 @@ diff -up Python-2.7.3/Makefile.pre.in.lib64 Python-2.7.3/Makefile.pre.in
BINLIBDEST= $(LIBDIR)/python$(VERSION)
diff -up Python-2.7.3/Modules/getpath.c.lib64 Python-2.7.3/Modules/getpath.c
--- Python-2.7.3/Modules/getpath.c.lib64 2012-04-09 19:07:34.000000000 -0400
-+++ Python-2.7.3/Modules/getpath.c 2012-04-11 17:56:41.853587110 -0400
++++ Python-2.7.3/Modules/getpath.c 2013-02-19 13:58:20.448015128 -0500
@@ -117,8 +117,8 @@
#endif
@@ -137,11 +137,11 @@ diff -up Python-2.7.3/Modules/getpath.c.lib64 Python-2.7.3/Modules/getpath.c
/* If we found EXEC_PREFIX do *not* reduce it! (Yet.) */
diff -up Python-2.7.3/Modules/Setup.dist.lib64 Python-2.7.3/Modules/Setup.dist
---- Python-2.7.3/Modules/Setup.dist.lib64 2012-04-11 17:56:41.820587523 -0400
-+++ Python-2.7.3/Modules/Setup.dist 2012-04-11 17:56:41.854587097 -0400
+--- Python-2.7.3/Modules/Setup.dist.lib64 2013-02-19 13:58:20.442015131 -0500
++++ Python-2.7.3/Modules/Setup.dist 2013-02-19 14:02:25.255998391 -0500
@@ -413,7 +413,7 @@ gdbm gdbmmodule.c -lgdbm
# and the subdirectory of PORT where you built it.
- DBLIBVER=4.7
+ DBLIBVER=4.8
DBINC=/usr/include/db4
-DBLIB=/usr/lib
+DBLIB=/usr/lib64
@@ -159,7 +159,7 @@ diff -up Python-2.7.3/Modules/Setup.dist.lib64 Python-2.7.3/Modules/Setup.dist
#
diff -up Python-2.7.3/setup.py.lib64 Python-2.7.3/setup.py
--- Python-2.7.3/setup.py.lib64 2012-04-09 19:07:36.000000000 -0400
-+++ Python-2.7.3/setup.py 2012-04-11 17:56:41.856587073 -0400
++++ Python-2.7.3/setup.py 2013-02-19 13:58:20.449015129 -0500
@@ -369,7 +369,7 @@ class PyBuildExt(build_ext):
def detect_modules(self):
diff --git a/python.spec b/python.spec
index 576c8a0..c712da3 100644
--- a/python.spec
+++ b/python.spec
@@ -6,8 +6,6 @@
#global __python_ver 27
%global unicode ucs4
-%global _default_patch_fuzz 2
-
%if "%{__python_ver}" != "EMPTY"
%global main_python 0
%global python python%{__python_ver}
@@ -108,7 +106,7 @@ Summary: An interpreted, interactive, object-oriented programming language
Name: %{python}
# Remember to also rebase python-docs when changing this:
Version: 2.7.3
-Release: 16%{?dist}
+Release: 17%{?dist}
License: Python
Group: Development/Languages
Requires: %{python}-libs%{?_isa} = %{version}-%{release}
@@ -277,7 +275,7 @@ Patch0: python-2.7.1-config.patch
# in 2.2.1-12 as a response to the -g option needing TkInter installed
# (Red Hat Linux 8)
# Not upstream
-Patch1: Python-2.2.1-pydocnogui.patch
+Patch1: 00001-pydocnogui.patch
# Add $(CFLAGS) to the linker arguments when linking the "python" binary
# since some architectures (sparc64) need this (rhbz:199373).
@@ -359,7 +357,7 @@ Patch55: 00055-systemtap.patch
# contained additional changes that applied fixes to the internals of the regex
# module, but these appear to have all been applied as part of
# http://bugs.python.org/issue931848
-Patch101: python-2.3.4-lib64-regex.patch
+Patch101: 00101-lib64-regex.patch
# Only used when "%{_lib}" == "lib64"
# Fixup various paths throughout the build and in distutils from "lib" to "lib64",
@@ -481,7 +479,7 @@ Patch114: 00114-statvfs-f_flag-constants.patch
# ImportError: No module named _struct
#
# For now, revert this patch:
-Patch121: python-2.7rc2-r79310.patch
+Patch121: 00121-revert-r79310.patch
# 00125 #
# COUNT_ALLOCS is useful for debugging, but the upstream behaviour of always
@@ -973,6 +971,8 @@ done
# Try not disabling egg-infos, bz#414711
#patch50 -p1 -b .egginfo
+%patch54 -p1 -b .setup-db48
+
%patch101 -p1 -b .lib64-regex
%if "%{_lib}" == "lib64"
%patch102 -p1 -b .lib64
@@ -987,7 +987,6 @@ done
%patch16 -p1 -b .rpath
%patch17 -p1 -b .distutils-rpath
-%patch54 -p1 -b .setup-db48
%if 0%{?with_systemtap}
%patch55 -p1 -b .systemtap
%endif
@@ -1002,7 +1001,7 @@ done
# patch115: upstream as of Python 2.7.3
-%patch121 -p0 -R
+%patch121 -p1
%patch125 -p1 -b .less-verbose-COUNT_ALLOCS
%patch126 -p0 -b .fix-dbm_contains-on-64bit-bigendian
%patch127 -p1 -b .fix-test_structmember-on-64bit-bigendian
@@ -1884,6 +1883,13 @@ rm -fr %{buildroot}
# ======================================================
%changelog
+* Tue Feb 19 2013 David Malcolm <dmalcolm at redhat.com> - 2.7.3-17
+- remove "_default_patch_fuzz" directive to avoid patches being silently
+misapplied (refresh patch 1, patch 101, patch 102, patch 111, patch 121,
+patch 158; rename patch 1, patch 101, patch 121; apply patch 54 before the
+lib64 patches to avoid fuzz problems caused by the conditional application
+of the lib64 patches)
+
* Mon Feb 18 2013 Peter Robinson <pbrobinson at fedoraproject.org> 2.7.3-16
- disable make check on ARM for the moment until 912025 is fixed
More information about the scm-commits
mailing list