diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 075b3f2..0000000 --- a/.gitignore +++ /dev/null @@ -1 +0,0 @@ -SOURCES/Python-2.7.18-noexe.tar.xz diff --git a/00001-pydocnogui.patch b/00001-pydocnogui.patch deleted file mode 100644 index 0311f38..0000000 --- a/00001-pydocnogui.patch +++ /dev/null @@ -1,28 +0,0 @@ -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. - local machine to generate documentation web pages. Port number 0 can be - used to get an arbitrary unused port. - --For platforms without a command line, "pydoc -g" starts the HTTP server --and also pops up a little window for controlling it. -- - Run "pydoc -w " to write out the HTML documentation for a module - to a file named ".html". - -@@ -2346,13 +2340,10 @@ def cli(): - Start an HTTP server on the given port on the local machine. Port - number 0 can be used to get an arbitrary unused port. - --%s -g -- Pop up a graphical interface for finding and serving documentation. -- - %s -w ... - Write out the HTML documentation for a module to a file in the current - directory. If contains a '%s', it is treated as a filename; if - it names a directory, documentation is written for all the contents. --""" % (cmd, os.sep, cmd, cmd, cmd, cmd, os.sep) -+""" % (cmd, os.sep, cmd, cmd, cmd, os.sep) - - if __name__ == '__main__': cli() diff --git a/00010-2.7.13-binutils-no-dep.patch b/00010-2.7.13-binutils-no-dep.patch deleted file mode 100644 index d432623..0000000 --- a/00010-2.7.13-binutils-no-dep.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/Lib/ctypes/util.py b/Lib/ctypes/util.py -index ab10ec5..923d1b7 100644 ---- a/Lib/ctypes/util.py -+++ b/Lib/ctypes/util.py -@@ -140,11 +140,15 @@ elif os.name == "posix": - # assuming GNU binutils / ELF - if not f: - return None -- cmd = 'if ! type objdump >/dev/null 2>&1; then exit; fi;' \ -+ cmd = 'if ! type objdump >/dev/null 2>&1; then exit 10; fi;' \ - 'objdump -p -j .dynamic 2>/dev/null "$1"' - proc = subprocess.Popen((cmd, '_get_soname', f), shell=True, - stdout=subprocess.PIPE) - [dump, _] = proc.communicate() -+ if proc.returncode == 10: -+ return os.path.basename(f) # This is good for GLibc, I think, -+ # and a dep on binutils is big (for -+ # live CDs). - res = re.search(br'\sSONAME\s+([^\s]+)', dump) - if not res: - return None diff --git a/00055-systemtap.patch b/00055-systemtap.patch deleted file mode 100644 index 6ccc747..0000000 --- a/00055-systemtap.patch +++ /dev/null @@ -1,198 +0,0 @@ -diff -up Python-2.7rc1/configure.ac.systemtap Python-2.7rc1/configure.ac ---- Python-2.7rc1/configure.ac.systemtap 2010-06-06 10:53:15.514975012 -0400 -+++ Python-2.7rc1/configure.ac 2010-06-06 10:53:15.520974361 -0400 -@@ -2616,6 +2616,38 @@ if test "$with_valgrind" != no; then - ) - fi - -+# Check for dtrace support -+AC_MSG_CHECKING(for --with-dtrace) -+AC_ARG_WITH(dtrace, -+ AC_HELP_STRING(--with(out)-dtrace, disable/enable dtrace support)) -+ -+if test ! -z "$with_dtrace" -+then -+ if dtrace -G -o /dev/null -s $srcdir/Include/pydtrace.d 2>/dev/null -+ then -+ AC_DEFINE(WITH_DTRACE, 1, -+ [Define if you want to compile in Dtrace support]) -+ with_dtrace="Sun" -+ DTRACEOBJS="Python/dtrace.o" -+ DTRADEHDRS="" -+ elif dtrace -h -o /dev/null -s $srcdir/Include/pydtrace.d -+ then -+ AC_DEFINE(WITH_DTRACE, 1, -+ [Define if you want to compile in Dtrace support]) -+ with_dtrace="Apple" -+ DTRACEOBJS="" -+ DTRADEHDRS="pydtrace.h" -+ else -+ with_dtrace="no" -+ fi -+else -+ with_dtrace="no" -+fi -+ -+AC_MSG_RESULT($with_dtrace) -+AC_SUBST(DTRACEOBJS) -+AC_SUBST(DTRACEHDRS) -+ - # Check for --with-wctype-functions - AC_MSG_CHECKING(for --with-wctype-functions) - AC_ARG_WITH(wctype-functions, -diff -up Python-2.7rc1/Include/pydtrace.d.systemtap Python-2.7rc1/Include/pydtrace.d ---- Python-2.7rc1/Include/pydtrace.d.systemtap 2010-06-06 10:53:15.520974361 -0400 -+++ Python-2.7rc1/Include/pydtrace.d 2010-06-06 10:53:15.520974361 -0400 -@@ -0,0 +1,10 @@ -+provider python { -+ probe function__entry(const char *, const char *, int); -+ probe function__return(const char *, const char *, int); -+}; -+ -+#pragma D attributes Evolving/Evolving/Common provider python provider -+#pragma D attributes Private/Private/Common provider python module -+#pragma D attributes Private/Private/Common provider python function -+#pragma D attributes Evolving/Evolving/Common provider python name -+#pragma D attributes Evolving/Evolving/Common provider python args -diff -up Python-2.7rc1/Makefile.pre.in.systemtap Python-2.7rc1/Makefile.pre.in ---- Python-2.7rc1/Makefile.pre.in.systemtap 2010-06-06 10:53:15.488978775 -0400 -+++ Python-2.7rc1/Makefile.pre.in 2010-06-06 11:05:30.411100568 -0400 -@@ -298,6 +298,7 @@ PYTHON_OBJS= \ - Python/formatter_unicode.o \ - Python/formatter_string.o \ - Python/$(DYNLOADFILE) \ -+ @DTRACEOBJS@ \ - $(LIBOBJS) \ - $(MACHDEP_OBJS) \ - $(THREADOBJ) -@@ -599,6 +600,18 @@ Python/formatter_unicode.o: $(srcdir)/Py - Python/formatter_string.o: $(srcdir)/Python/formatter_string.c \ - $(STRINGLIB_HEADERS) - -+# Only needed with --with-dtrace -+buildinclude: -+ mkdir -p Include -+ -+Include/pydtrace.h: buildinclude $(srcdir)/Include/pydtrace.d -+ dtrace -o $@ $(DFLAGS) -C -h -s $(srcdir)/Include/pydtrace.d -+ -+Python/ceval.o: Include/pydtrace.h -+ -+Python/dtrace.o: buildinclude $(srcdir)/Include/pydtrace.d Python/ceval.o -+ dtrace -o $@ $(DFLAGS) -C -G -s $(srcdir)/Include/pydtrace.d Python/ceval.o -+ - ############################################################################ - # Header files - -@@ -1251,7 +1264,7 @@ Python/thread.o: @THREADHEADERS@ - .PHONY: frameworkinstall frameworkinstallframework frameworkinstallstructure - .PHONY: frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools - .PHONY: frameworkaltinstallunixtools recheck clean clobber distclean --.PHONY: smelly funny patchcheck altmaninstall commoninstall -+.PHONY: smelly funny patchcheck altmaninstall commoninstall buildinclude - .PHONY: gdbhooks - - # IF YOU PUT ANYTHING HERE IT WILL GO AWAY -diff -up Python-2.7rc1/pyconfig.h.in.systemtap Python-2.7rc1/pyconfig.h.in ---- Python-2.7rc1/pyconfig.h.in.systemtap 2010-05-08 07:04:18.000000000 -0400 -+++ Python-2.7rc1/pyconfig.h.in 2010-06-06 10:53:15.521974070 -0400 -@@ -1074,6 +1074,9 @@ - /* Define if you want documentation strings in extension modules */ - #undef WITH_DOC_STRINGS - -+/* Define if you want to compile in Dtrace support */ -+#undef WITH_DTRACE -+ - /* Define if you want to use the new-style (Openstep, Rhapsody, MacOS) dynamic - linker (dyld) instead of the old-style (NextStep) dynamic linker (rld). - Dyld is necessary to support frameworks. */ -diff -up Python-2.7rc1/Python/ceval.c.systemtap Python-2.7rc1/Python/ceval.c ---- Python-2.7rc1/Python/ceval.c.systemtap 2010-05-09 10:46:46.000000000 -0400 -+++ Python-2.7rc1/Python/ceval.c 2010-06-06 11:08:40.683100500 -0400 -@@ -19,6 +19,10 @@ - - #include - -+#ifdef WITH_DTRACE -+#include "pydtrace.h" -+#endif -+ - #ifndef WITH_TSC - - #define READ_TIMESTAMP(var) -@@ -671,6 +675,55 @@ PyEval_EvalCode(PyCodeObject *co, PyObje - NULL); - } - -+#ifdef WITH_DTRACE -+static void -+dtrace_entry(PyFrameObject *f) -+{ -+ const char *filename; -+ const char *fname; -+ int lineno; -+ -+ filename = PyString_AsString(f->f_code->co_filename); -+ fname = PyString_AsString(f->f_code->co_name); -+ lineno = PyCode_Addr2Line(f->f_code, f->f_lasti); -+ -+ PYTHON_FUNCTION_ENTRY((char *)filename, (char *)fname, lineno); -+ -+ /* -+ * Currently a USDT tail-call will not receive the correct arguments. -+ * Disable the tail call here. -+ */ -+#if defined(__sparc) -+ asm("nop"); -+#endif -+} -+ -+static void -+dtrace_return(PyFrameObject *f) -+{ -+ const char *filename; -+ const char *fname; -+ int lineno; -+ -+ filename = PyString_AsString(f->f_code->co_filename); -+ fname = PyString_AsString(f->f_code->co_name); -+ lineno = PyCode_Addr2Line(f->f_code, f->f_lasti); -+ PYTHON_FUNCTION_RETURN((char *)filename, (char *)fname, lineno); -+ -+ /* -+ * Currently a USDT tail-call will not receive the correct arguments. -+ * Disable the tail call here. -+ */ -+#if defined(__sparc) -+ asm("nop"); -+#endif -+} -+#else -+#define PYTHON_FUNCTION_ENTRY_ENABLED() 0 -+#define PYTHON_FUNCTION_RETURN_ENABLED() 0 -+#define dtrace_entry(f) -+#define dtrace_return(f) -+#endif - - /* Interpreter main loop */ - -@@ -909,6 +962,9 @@ PyEval_EvalFrameEx(PyFrameObject *f, int - } - } - -+ if (PYTHON_FUNCTION_ENTRY_ENABLED()) -+ dtrace_entry(f); -+ - co = f->f_code; - names = co->co_names; - consts = co->co_consts; -@@ -3000,6 +3056,9 @@ fast_yield: - - /* pop frame */ - exit_eval_frame: -+ if (PYTHON_FUNCTION_RETURN_ENABLED()) -+ dtrace_return(f); -+ - Py_LeaveRecursiveCall(); - tstate->frame = f->f_back; - diff --git a/00102-2.7.13-lib64.patch b/00102-2.7.13-lib64.patch deleted file mode 100644 index 02d3f6c..0000000 --- a/00102-2.7.13-lib64.patch +++ /dev/null @@ -1,193 +0,0 @@ -diff --git a/Lib/distutils/command/install.py b/Lib/distutils/command/install.py -index b9f1c6c..7b23714 100644 ---- a/Lib/distutils/command/install.py -+++ b/Lib/distutils/command/install.py -@@ -42,14 +42,14 @@ else: - INSTALL_SCHEMES = { - 'unix_prefix': { - 'purelib': '$base/lib/python$py_version_short/site-packages', -- 'platlib': '$platbase/lib/python$py_version_short/site-packages', -+ 'platlib': '$platbase/lib64/python$py_version_short/site-packages', - 'headers': '$base/include/python$py_version_short/$dist_name', - 'scripts': '$base/bin', - 'data' : '$base', - }, - 'unix_home': { - 'purelib': '$base/lib/python', -- 'platlib': '$base/lib/python', -+ 'platlib': '$base/lib64/python', - 'headers': '$base/include/python/$dist_name', - 'scripts': '$base/bin', - 'data' : '$base', -diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py -index 031f809..ec5d584 100644 ---- a/Lib/distutils/sysconfig.py -+++ b/Lib/distutils/sysconfig.py -@@ -120,8 +120,12 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None): - prefix = plat_specific and EXEC_PREFIX or PREFIX - - if os.name == "posix": -+ if plat_specific or standard_lib: -+ lib = "lib64" -+ else: -+ lib = "lib" - libpython = os.path.join(prefix, -- "lib", "python" + get_python_version()) -+ lib, "python" + get_python_version()) - if standard_lib: - return libpython - else: -diff --git a/Lib/site.py b/Lib/site.py -index c360802..868b7cb 100644 ---- a/Lib/site.py -+++ b/Lib/site.py -@@ -288,12 +288,16 @@ def getsitepackages(): - if sys.platform in ('os2emx', 'riscos'): - sitepackages.append(os.path.join(prefix, "Lib", "site-packages")) - elif os.sep == '/': -+ sitepackages.append(os.path.join(prefix, "lib64", -+ "python" + sys.version[:3], -+ "site-packages")) - sitepackages.append(os.path.join(prefix, "lib", - "python" + sys.version[:3], - "site-packages")) - sitepackages.append(os.path.join(prefix, "lib", "site-python")) - else: - sitepackages.append(prefix) -+ sitepackages.append(os.path.join(prefix, "lib64", "site-packages")) - sitepackages.append(os.path.join(prefix, "lib", "site-packages")) - return sitepackages - -diff --git a/Lib/test/test_site.py b/Lib/test/test_site.py -index b4384ee..349f688 100644 ---- a/Lib/test/test_site.py -+++ b/Lib/test/test_site.py -@@ -254,17 +254,20 @@ class HelperFunctionsTests(unittest.TestCase): - self.assertEqual(dirs[0], wanted) - elif os.sep == '/': - # OS X, Linux, FreeBSD, etc -- self.assertEqual(len(dirs), 2) -- wanted = os.path.join('xoxo', 'lib', 'python' + sys.version[:3], -+ self.assertEqual(len(dirs), 3) -+ wanted = os.path.join('xoxo', 'lib64', 'python' + sys.version[:3], - 'site-packages') - self.assertEqual(dirs[0], wanted) -- wanted = os.path.join('xoxo', 'lib', 'site-python') -+ wanted = os.path.join('xoxo', 'lib', 'python' + sys.version[:3], -+ 'site-packages') - self.assertEqual(dirs[1], wanted) -+ wanted = os.path.join('xoxo', 'lib', 'site-python') -+ self.assertEqual(dirs[2], wanted) - else: - # other platforms - self.assertEqual(len(dirs), 2) - self.assertEqual(dirs[0], 'xoxo') -- wanted = os.path.join('xoxo', 'lib', 'site-packages') -+ wanted = os.path.join('xoxo', 'lib64', 'site-packages') - self.assertEqual(dirs[1], wanted) - - def test_no_home_directory(self): -diff --git a/Makefile.pre.in b/Makefile.pre.in -index 4f59dd3..877698c 100644 ---- a/Makefile.pre.in -+++ b/Makefile.pre.in -@@ -110,7 +110,7 @@ LIBDIR= @libdir@ - MANDIR= @mandir@ - INCLUDEDIR= @includedir@ - CONFINCLUDEDIR= $(exec_prefix)/include --SCRIPTDIR= $(prefix)/lib -+SCRIPTDIR= $(prefix)/lib64 - - # Detailed destination directories - BINLIBDEST= $(LIBDIR)/python$(VERSION) -diff --git a/Modules/Setup.dist b/Modules/Setup.dist -index 2cf35a9..c4c88cb 100644 ---- a/Modules/Setup.dist -+++ b/Modules/Setup.dist -@@ -231,7 +231,7 @@ crypt cryptmodule.c # -lcrypt # crypt(3); needs -lcrypt on some systems - # Some more UNIX dependent modules -- off by default, since these - # are not supported by all UNIX systems: - --nis nismodule.c -lnsl -ltirpc -I/usr/include/tirpc -I/usr/include/nsl -L/usr/lib/nsl -+nis nismodule.c -lnsl -ltirpc -I/usr/include/tirpc -I/usr/include/nsl -L/usr/lib64/nsl - termios termios.c # Steen Lumholt's termios module - resource resource.c # Jeremy Hylton's rlimit interface - -@@ -416,7 +416,7 @@ gdbm gdbmmodule.c -lgdbm - # Edit the variables DB and DBLIBVERto point to the db top directory - # and the subdirectory of PORT where you built it. - DBINC=/usr/include/libdb --DBLIB=/usr/lib -+DBLIB=/usr/lib64 - _bsddb _bsddb.c -I$(DBINC) -L$(DBLIB) -ldb - - # Historical Berkeley DB 1.85 -@@ -462,7 +462,7 @@ cPickle cPickle.c - # Andrew Kuchling's zlib module. - # This require zlib 1.1.3 (or later). - # See http://www.gzip.org/zlib/ --zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib -lz -+zlib zlibmodule.c -I$(prefix)/include -L$(exec_prefix)/lib64 -lz - - # Interface to the Expat XML parser - # More information on Expat can be found at www.libexpat.org. -diff --git a/Modules/getpath.c b/Modules/getpath.c -index fd33a01..c5c86fd 100644 ---- a/Modules/getpath.c -+++ b/Modules/getpath.c -@@ -108,7 +108,7 @@ static char prefix[MAXPATHLEN+1]; - static char exec_prefix[MAXPATHLEN+1]; - static char progpath[MAXPATHLEN+1]; - static char *module_search_path = NULL; --static char lib_python[] = "lib/python" VERSION; -+static char lib_python[] = "lib64/python" VERSION; - - static void - reduce(char *dir) -@@ -548,7 +548,7 @@ calculate_path(void) - fprintf(stderr, - "Could not find platform dependent libraries \n"); - strncpy(exec_prefix, EXEC_PREFIX, MAXPATHLEN); -- joinpath(exec_prefix, "lib/lib-dynload"); -+ joinpath(exec_prefix, "lib64/lib-dynload"); - } - /* If we found EXEC_PREFIX do *not* reduce it! (Yet.) */ - -diff --git a/setup.py b/setup.py -index 0288a6b..7905f6f 100644 ---- a/setup.py -+++ b/setup.py -@@ -456,7 +456,7 @@ class PyBuildExt(build_ext): - def detect_modules(self): - # Ensure that /usr/local is always used - if not cross_compiling: -- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib') -+ add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib64') - add_dir_to_list(self.compiler.include_dirs, '/usr/local/include') - if cross_compiling: - self.add_gcc_paths() -@@ -782,11 +782,11 @@ class PyBuildExt(build_ext): - elif curses_library: - readline_libs.append(curses_library) - elif self.compiler.find_library_file(lib_dirs + -- ['/usr/lib/termcap'], -+ ['/usr/lib64/termcap'], - 'termcap'): - readline_libs.append('termcap') - exts.append( Extension('readline', ['readline.c'], -- library_dirs=['/usr/lib/termcap'], -+ library_dirs=['/usr/lib64/termcap'], - extra_link_args=readline_extra_link_args, - libraries=readline_libs) ) - else: -@@ -821,8 +821,8 @@ class PyBuildExt(build_ext): - if krb5_h: - ssl_incs += krb5_h - ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs, -- ['/usr/local/ssl/lib', -- '/usr/contrib/ssl/lib/' -+ ['/usr/local/ssl/lib64', -+ '/usr/contrib/ssl/lib64/' - ] ) - - if (ssl_incs is not None and diff --git a/00104-lib64-fix-for-test_install.patch b/00104-lib64-fix-for-test_install.patch deleted file mode 100644 index 7852bf6..0000000 --- a/00104-lib64-fix-for-test_install.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- Python-2.7.2/Lib/distutils/tests/test_install.py.lib64 2011-09-08 17:51:57.851405376 -0400 -+++ Python-2.7.2/Lib/distutils/tests/test_install.py 2011-09-08 18:40:46.754205096 -0400 -@@ -41,8 +41,9 @@ class InstallTestCase(support.TempdirMan - self.assertEqual(got, expected) - - libdir = os.path.join(destination, "lib", "python") -+ platlibdir = os.path.join(destination, "lib64", "python") - check_path(cmd.install_lib, libdir) -- check_path(cmd.install_platlib, libdir) -+ check_path(cmd.install_platlib, platlibdir) - check_path(cmd.install_purelib, libdir) - check_path(cmd.install_headers, - os.path.join(destination, "include", "python", "foopkg")) diff --git a/00111-no-static-lib.patch b/00111-no-static-lib.patch deleted file mode 100644 index 70dfb77..0000000 --- a/00111-no-static-lib.patch +++ /dev/null @@ -1,50 +0,0 @@ -diff -up Python-2.7.6/Makefile.pre.in.no-static-lib Python-2.7.6/Makefile.pre.in ---- Python-2.7.6/Makefile.pre.in.no-static-lib 2014-01-29 13:58:32.933226720 +0100 -+++ Python-2.7.6/Makefile.pre.in 2014-01-29 14:10:25.002247272 +0100 -@@ -437,7 +437,7 @@ coverage: - - - # Build the interpreter --$(BUILDPYTHON): Modules/python.o $(LIBRARY) $(LDLIBRARY) -+$(BUILDPYTHON): Modules/python.o $(LDLIBRARY) - $(LINKCC) $(CFLAGS) $(LDFLAGS) $(LINKFORSHARED) -o $@ \ - Modules/python.o \ - $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST) -@@ -464,18 +464,6 @@ sharedmods: $(BUILDPYTHON) pybuilddir.tx - _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \ - $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build - --# Build static library --# avoid long command lines, same as LIBRARY_OBJS --$(LIBRARY): $(LIBRARY_OBJS) -- -rm -f $@ -- $(AR) $(ARFLAGS) $@ Modules/getbuildinfo.o -- $(AR) $(ARFLAGS) $@ $(PARSER_OBJS) -- $(AR) $(ARFLAGS) $@ $(OBJECT_OBJS) -- $(AR) $(ARFLAGS) $@ $(PYTHON_OBJS) -- $(AR) $(ARFLAGS) $@ $(MODULE_OBJS) $(SIGNAL_OBJS) -- $(AR) $(ARFLAGS) $@ $(MODOBJS) -- $(RANLIB) $@ -- - libpython$(VERSION).so: $(LIBRARY_OBJS) - if test $(INSTSONAME) != $(LDLIBRARY); then \ - $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \ -@@ -1097,18 +1085,6 @@ libainstall: all python-config - else true; \ - fi; \ - done -- @if test -d $(LIBRARY); then :; else \ -- if test "$(PYTHONFRAMEWORKDIR)" = no-framework; then \ -- if test "$(SO)" = .dll; then \ -- $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \ -- else \ -- $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \ -- $(RANLIB) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \ -- fi; \ -- else \ -- echo Skip install of $(LIBRARY) - use make frameworkinstall; \ -- fi; \ -- fi - $(INSTALL_DATA) Modules/config.c $(DESTDIR)$(LIBPL)/config.c - $(INSTALL_DATA) Modules/python.o $(DESTDIR)$(LIBPL)/python.o - $(INSTALL_DATA) $(srcdir)/Modules/config.c.in $(DESTDIR)$(LIBPL)/config.c.in diff --git a/00112-2.7.13-debug-build.patch b/00112-2.7.13-debug-build.patch deleted file mode 100644 index 463f4d8..0000000 --- a/00112-2.7.13-debug-build.patch +++ /dev/null @@ -1,324 +0,0 @@ -From 898f93aa206e577dfe854c59bc62d0cea09cd5ed Mon Sep 17 00:00:00 2001 -From: Tomas Orsava -Date: Tue, 10 Jan 2017 16:19:50 +0100 -Subject: [PATCH] Patch to support building both optimized vs debug stacks DSO - ABIs, - -sharing the same .py and .pyc files, using "_d.so" to signify a debug build of -an extension module. ---- - Lib/distutils/command/build_ext.py | 7 ++++- - Lib/distutils/sysconfig.py | 5 ++-- - Lib/distutils/tests/test_install.py | 3 +- - Makefile.pre.in | 56 ++++++++++++++++++++----------------- - Misc/python-config.in | 2 +- - Modules/makesetup | 2 +- - Python/dynload_shlib.c | 11 ++++++-- - Python/sysmodule.c | 6 ++++ - configure.ac | 14 ++++++++-- - 9 files changed, 69 insertions(+), 37 deletions(-) - -diff --git a/Lib/distutils/command/build_ext.py b/Lib/distutils/command/build_ext.py -index 2c68be3..029d144 100644 ---- a/Lib/distutils/command/build_ext.py -+++ b/Lib/distutils/command/build_ext.py -@@ -677,7 +677,10 @@ class build_ext (Command): - so_ext = get_config_var('SO') - if os.name == 'nt' and self.debug: - return os.path.join(*ext_path) + '_d' + so_ext -- return os.path.join(*ext_path) + so_ext -+ -+ # Similarly, extensions in debug mode are named 'module_d.so', to -+ # avoid adding the _d to the SO config variable: -+ return os.path.join(*ext_path) + (sys.pydebug and "_d" or "") + so_ext - - def get_export_symbols (self, ext): - """Return the list of symbols that a shared extension has to -@@ -762,6 +765,8 @@ class build_ext (Command): - template = "python%d.%d" - pythonlib = (template % - (sys.hexversion >> 24, (sys.hexversion >> 16) & 0xff)) -+ if sys.pydebug: -+ pythonlib += '_d' - return ext.libraries + [pythonlib] - else: - return ext.libraries -diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py -index 3e7f077..ec5d584 100644 ---- a/Lib/distutils/sysconfig.py -+++ b/Lib/distutils/sysconfig.py -@@ -90,7 +90,8 @@ def get_python_inc(plat_specific=0, prefix=None): - # Include is located in the srcdir - inc_dir = os.path.join(srcdir, "Include") - return inc_dir -- return os.path.join(prefix, "include", "python" + get_python_version()) -+ return os.path.join(prefix, "include", -+ "python" + get_python_version() + (sys.pydebug and '-debug' or '')) - elif os.name == "nt": - return os.path.join(prefix, "include") - elif os.name == "os2": -@@ -248,7 +249,7 @@ def get_makefile_filename(): - if python_build: - return os.path.join(project_base, "Makefile") - lib_dir = get_python_lib(plat_specific=1, standard_lib=1) -- return os.path.join(lib_dir, "config", "Makefile") -+ return os.path.join(lib_dir, "config" + (sys.pydebug and "-debug" or ""), "Makefile") - - - def parse_config_h(fp, g=None): -diff --git a/Lib/distutils/tests/test_install.py b/Lib/distutils/tests/test_install.py -index 78fac46..d1d0931 100644 ---- a/Lib/distutils/tests/test_install.py -+++ b/Lib/distutils/tests/test_install.py -@@ -20,8 +20,9 @@ from distutils.tests import support - - - def _make_ext_name(modname): -- if os.name == 'nt' and sys.executable.endswith('_d.exe'): -+ if sys.pydebug: - modname += '_d' -+ - return modname + sysconfig.get_config_var('SO') - - -diff --git a/Makefile.pre.in b/Makefile.pre.in -index 997a2fc..467e782 100644 ---- a/Makefile.pre.in -+++ b/Makefile.pre.in -@@ -116,8 +116,8 @@ SCRIPTDIR= $(prefix)/lib64 - # Detailed destination directories - BINLIBDEST= $(LIBDIR)/python$(VERSION) - LIBDEST= $(SCRIPTDIR)/python$(VERSION) --INCLUDEPY= $(INCLUDEDIR)/python$(VERSION) --CONFINCLUDEPY= $(CONFINCLUDEDIR)/python$(VERSION) -+INCLUDEPY= $(INCLUDEDIR)/python$(VERSION)$(DEBUG_SUFFIX) -+CONFINCLUDEPY= $(CONFINCLUDEDIR)/python$(VERSION)$(DEBUG_SUFFIX) - LIBP= $(LIBDIR)/python$(VERSION) - - # Symbols used for using shared libraries -@@ -131,6 +131,12 @@ DESTSHARED= $(BINLIBDEST)/lib-dynload - EXE= @EXEEXT@ - BUILDEXE= @BUILDEXEEXT@ - -+# DEBUG_EXT is used by ELF files (names and SONAMEs); it will be "_d" for a debug build -+# DEBUG_SUFFIX is used by filesystem paths; it will be "-debug" for a debug build -+# Both will be empty in an optimized build -+DEBUG_EXT= @DEBUG_EXT@ -+DEBUG_SUFFIX= @DEBUG_SUFFIX@ -+ - # Short name and location for Mac OS X Python framework - UNIVERSALSDK=@UNIVERSALSDK@ - PYTHONFRAMEWORK= @PYTHONFRAMEWORK@ -@@ -197,8 +203,8 @@ LIBOBJDIR= Python/ - LIBOBJS= @LIBOBJS@ - UNICODE_OBJS= @UNICODE_OBJS@ - --PYTHON= python$(EXE) --BUILDPYTHON= python$(BUILDEXE) -+PYTHON= python$(DEBUG_SUFFIX)$(EXE) -+BUILDPYTHON= python$(DEBUG_SUFFIX)$(BUILDEXE) - - PYTHON_FOR_REGEN=@PYTHON_FOR_REGEN@ - PYTHON_FOR_BUILD=@PYTHON_FOR_BUILD@ -@@ -547,7 +553,7 @@ sharedmods: $(BUILDPYTHON) pybuilddir.txt Modules/_math.o - _TCLTK_INCLUDES='$(TCLTK_INCLUDES)' _TCLTK_LIBS='$(TCLTK_LIBS)' \ - $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build - --libpython$(VERSION).so: $(LIBRARY_OBJS) -+libpython$(VERSION)$(DEBUG_EXT).so: $(LIBRARY_OBJS) - if test $(INSTSONAME) != $(LDLIBRARY); then \ - $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \ - $(LN) -f $(INSTSONAME) $@; \ -@@ -954,18 +960,18 @@ bininstall: altbininstall - then rm -f $(DESTDIR)$(BINDIR)/$(PYTHON); \ - else true; \ - fi -- (cd $(DESTDIR)$(BINDIR); $(LN) -s python2$(EXE) $(PYTHON)) -- -rm -f $(DESTDIR)$(BINDIR)/python2$(EXE) -- (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)$(EXE) python2$(EXE)) -- -rm -f $(DESTDIR)$(BINDIR)/python2-config -- (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)-config python2-config) -- -rm -f $(DESTDIR)$(BINDIR)/python-config -- (cd $(DESTDIR)$(BINDIR); $(LN) -s python2-config python-config) -+ (cd $(DESTDIR)$(BINDIR); $(LN) -s python2$(DEBUG_SUFFIX)$(EXE) $(PYTHON)) -+ -rm -f $(DESTDIR)$(BINDIR)/python2$(DEBUG_SUFFIX)$(EXE) -+ (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)$(DEBUG_SUFFIX)$(EXE) python2$(DEBUG_SUFFIX)$(EXE)) -+ -rm -f $(DESTDIR)$(BINDIR)/python2$(DEBUG_SUFFIX)-config -+ (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)$(DEBUG_SUFFIX)-config python2$(DEBUG_SUFFIX)-config) -+ -rm -f $(DESTDIR)$(BINDIR)/python$(DEBUG_SUFFIX)-config -+ (cd $(DESTDIR)$(BINDIR); $(LN) -s python2$(DEBUG_SUFFIX)-config python$(DEBUG_SUFFIX)-config) - -test -d $(DESTDIR)$(LIBPC) || $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$(LIBPC) -- -rm -f $(DESTDIR)$(LIBPC)/python2.pc -- (cd $(DESTDIR)$(LIBPC); $(LN) -s python-$(VERSION).pc python2.pc) -- -rm -f $(DESTDIR)$(LIBPC)/python.pc -- (cd $(DESTDIR)$(LIBPC); $(LN) -s python2.pc python.pc) -+ -rm -f $(DESTDIR)$(LIBPC)/python2$(DEBUG_SUFFIX).pc -+ (cd $(DESTDIR)$(LIBPC); $(LN) -s python-$(VERSION)$(DEBUG_SUFFIX).pc python2$(DEBUG_SUFFIX).pc) -+ -rm -f $(DESTDIR)$(LIBPC)/python$(DEBUG_SUFFIX).pc -+ (cd $(DESTDIR)$(LIBPC); $(LN) -s python2$(DEBUG_SUFFIX).pc python$(DEBUG_SUFFIX).pc) - - # Install the interpreter with $(VERSION) affixed - # This goes into $(exec_prefix) -@@ -978,7 +984,7 @@ altbininstall: $(BUILDPYTHON) - else true; \ - fi; \ - done -- $(INSTALL_PROGRAM) $(BUILDPYTHON) $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE) -+ $(INSTALL_PROGRAM) $(BUILDPYTHON) $(DESTDIR)$(BINDIR)/python$(VERSION)$(DEBUG_SUFFIX)$(EXE) - if test -f $(LDLIBRARY); then \ - if test -n "$(DLLLIBRARY)" ; then \ - $(INSTALL_SHARED) $(DLLLIBRARY) $(DESTDIR)$(BINDIR); \ -@@ -1148,10 +1154,11 @@ $(srcdir)/Lib/$(PLATDIR): - fi; \ - cd $(srcdir)/Lib/$(PLATDIR); $(RUNSHARED) ./regen - --python-config: $(srcdir)/Misc/python-config.in -+python$(DEBUG_SUFFIX)-config: $(srcdir)/Misc/python-config.in - # Substitution happens here, as the completely-expanded BINDIR - # is not available in configure -- sed -e "s,@EXENAME@,$(BINDIR)/python$(VERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config -+ sed -e "s,@EXENAME@,$(BINDIR)/python$(VERSION)$(DEBUG_SUFFIX)$(EXE)," < $(srcdir)/Misc/python-config.in >python$(DEBUG_SUFFIX)-config -+ - - # Install the include files - INCLDIRSTOMAKE=$(INCLUDEDIR) $(CONFINCLUDEDIR) $(INCLUDEPY) $(CONFINCLUDEPY) -@@ -1172,13 +1179,13 @@ inclinstall: - $(INSTALL_DATA) pyconfig.h $(DESTDIR)$(CONFINCLUDEPY)/pyconfig.h - - # Install the library and miscellaneous stuff needed for extending/embedding --# This goes into $(exec_prefix) --LIBPL= $(LIBP)/config -+# This goes into $(exec_prefix)$(DEBUG_SUFFIX) -+LIBPL= $(LIBP)/config$(DEBUG_SUFFIX) - - # pkgconfig directory - LIBPC= $(LIBDIR)/pkgconfig - --libainstall: @DEF_MAKE_RULE@ python-config -+libainstall: @DEF_MAKE_RULE@ python$(DEBUG_SUFFIX)-config - @for i in $(LIBDIR) $(LIBP) $(LIBPL) $(LIBPC); \ - do \ - if test ! -d $(DESTDIR)$$i; then \ -@@ -1194,11 +1201,10 @@ libainstall: all python-config - $(INSTALL_DATA) Modules/Setup $(DESTDIR)$(LIBPL)/Setup - $(INSTALL_DATA) Modules/Setup.local $(DESTDIR)$(LIBPL)/Setup.local - $(INSTALL_DATA) Modules/Setup.config $(DESTDIR)$(LIBPL)/Setup.config -- $(INSTALL_DATA) Misc/python.pc $(DESTDIR)$(LIBPC)/python-$(VERSION).pc -+ $(INSTALL_DATA) Misc/python.pc $(DESTDIR)$(LIBPC)/python-$(VERSION)$(DEBUG_SUFFIX).pc - $(INSTALL_SCRIPT) $(srcdir)/Modules/makesetup $(DESTDIR)$(LIBPL)/makesetup - $(INSTALL_SCRIPT) $(srcdir)/install-sh $(DESTDIR)$(LIBPL)/install-sh -- $(INSTALL_SCRIPT) python-config $(DESTDIR)$(BINDIR)/python$(VERSION)-config -- rm python-config -+ $(INSTALL_SCRIPT) python$(DEBUG_SUFFIX)-config $(DESTDIR)$(BINDIR)/python$(VERSION)$(DEBUG_SUFFIX)-config - @if [ -s Modules/python.exp -a \ - "`echo $(MACHDEP) | sed 's/^\(...\).*/\1/'`" = "aix" ]; then \ - echo; echo "Installing support files for building shared extension modules on AIX:"; \ -diff --git a/Misc/python-config.in b/Misc/python-config.in -index a09e07c..c1691ef 100644 ---- a/Misc/python-config.in -+++ b/Misc/python-config.in -@@ -44,7 +44,7 @@ for opt in opt_flags: - print ' '.join(flags) - - elif opt in ('--libs', '--ldflags'): -- libs = ['-lpython' + pyver] -+ libs = ['-lpython' + pyver + (sys.pydebug and "_d" or "")] - libs += getvar('LIBS').split() - libs += getvar('SYSLIBS').split() - # add the prefix/lib/pythonX.Y/config dir, but only if there is no -diff --git a/Modules/makesetup b/Modules/makesetup -index 1bffcbf..f0bc743 100755 ---- a/Modules/makesetup -+++ b/Modules/makesetup -@@ -233,7 +233,7 @@ sed -e 's/[ ]*#.*//' -e '/^[ ]*$/d' | - *$mod.o*) base=$mod;; - *) base=${mod}module;; - esac -- file="$srcdir/$base\$(SO)" -+ file="$srcdir/$base\$(DEBUG_EXT)\$(SO)" - case $doconfig in - no) SHAREDMODS="$SHAREDMODS $file";; - esac -diff --git a/Python/dynload_shlib.c b/Python/dynload_shlib.c -index 17ebab1..02a94aa 100644 ---- a/Python/dynload_shlib.c -+++ b/Python/dynload_shlib.c -@@ -46,11 +46,16 @@ const struct filedescr _PyImport_DynLoadFiletab[] = { - {"module.exe", "rb", C_EXTENSION}, - {"MODULE.EXE", "rb", C_EXTENSION}, - #else -+#ifdef Py_DEBUG -+ {"_d.so", "rb", C_EXTENSION}, -+ {"module_d.so", "rb", C_EXTENSION}, -+#else - {".so", "rb", C_EXTENSION}, - {"module.so", "rb", C_EXTENSION}, --#endif --#endif --#endif -+#endif /* Py_DEBUG */ -+#endif /* __VMS */ -+#endif /* defined(PYOS_OS2) && defined(PYCC_GCC) */ -+#endif /* __CYGWIN__ */ - {0, 0} - }; - -diff --git a/Python/sysmodule.c b/Python/sysmodule.c -index aeff38a..183e3cc 100644 ---- a/Python/sysmodule.c -+++ b/Python/sysmodule.c -@@ -1524,6 +1524,12 @@ _PySys_Init(void) - PyString_FromString("legacy")); - #endif - -+#ifdef Py_DEBUG -+ PyDict_SetItemString(sysdict, "pydebug", Py_True); -+#else -+ PyDict_SetItemString(sysdict, "pydebug", Py_False); -+#endif -+ - #undef SET_SYS_FROM_STRING - if (PyErr_Occurred()) - return NULL; -diff --git a/configure.ac b/configure.ac -index 0a902c7..5caedb7 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -764,7 +764,7 @@ AC_SUBST(LIBRARY) - AC_MSG_CHECKING(LIBRARY) - if test -z "$LIBRARY" - then -- LIBRARY='libpython$(VERSION).a' -+ LIBRARY='libpython$(VERSION)$(DEBUG_EXT).a' - fi - AC_MSG_RESULT($LIBRARY) - -@@ -910,8 +910,8 @@ if test $enable_shared = "yes"; then - INSTSONAME="$LDLIBRARY".$SOVERSION - ;; - Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|OpenBSD*) -- LDLIBRARY='libpython$(VERSION).so' -- BLDLIBRARY='-L. -lpython$(VERSION)' -+ LDLIBRARY='libpython$(VERSION)$(DEBUG_EXT).so' -+ BLDLIBRARY='-L. -lpython$(VERSION)$(DEBUG_EXT)' - RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}} - case $ac_sys_system in - FreeBSD*) -@@ -1040,6 +1040,14 @@ else AC_MSG_RESULT(no); Py_DEBUG='false' - fi], - [AC_MSG_RESULT(no)]) - -+if test "$Py_DEBUG" = 'true' -+then -+ DEBUG_EXT=_d -+ DEBUG_SUFFIX=-debug -+fi -+AC_SUBST(DEBUG_EXT) -+AC_SUBST(DEBUG_SUFFIX) -+ - # XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be - # merged with this chunk of code? - --- -2.11.0 - diff --git a/00113-more-configuration-flags.patch b/00113-more-configuration-flags.patch deleted file mode 100644 index 2d447b2..0000000 --- a/00113-more-configuration-flags.patch +++ /dev/null @@ -1,50 +0,0 @@ -diff -up Python-2.6.5/configure.ac.more-configuration-flags Python-2.6.5/configure.ac ---- Python-2.6.5/configure.ac.more-configuration-flags 2010-05-24 18:51:25.410111792 -0400 -+++ Python-2.6.5/configure.ac 2010-05-24 18:59:23.954986388 -0400 -@@ -2515,6 +2515,30 @@ else AC_MSG_RESULT(no) - fi], - [AC_MSG_RESULT(no)]) - -+AC_MSG_CHECKING(for --with-count-allocs) -+AC_ARG_WITH(count-allocs, -+[ --with(out)count-allocs enable/disable per-type instance accounting], [ -+if test "$withval" != no -+then -+ AC_DEFINE(COUNT_ALLOCS, 1, -+ [Define to keep records of the number of instances of each type]) -+ AC_MSG_RESULT(yes) -+else AC_MSG_RESULT(no) -+fi], -+[AC_MSG_RESULT(no)]) -+ -+AC_MSG_CHECKING(for --with-call-profile) -+AC_ARG_WITH(call-profile, -+[ --with(out)-call-profile enable/disable statistics on function call invocation], [ -+if test "$withval" != no -+then -+ AC_DEFINE(CALL_PROFILE, 1, -+ [Define to keep records on function call invocation]) -+ AC_MSG_RESULT(yes) -+else AC_MSG_RESULT(no) -+fi], -+[AC_MSG_RESULT(no)]) -+ - # Check for Python-specific malloc support - AC_MSG_CHECKING(for --with-pymalloc) - AC_ARG_WITH(pymalloc, -diff -up Python-2.6.5/pyconfig.h.in.more-configuration-flags Python-2.6.5/pyconfig.h.in ---- Python-2.6.5/pyconfig.h.in.more-configuration-flags 2010-05-24 18:51:45.677988086 -0400 -+++ Python-2.6.5/pyconfig.h.in 2010-05-24 19:00:44.163987730 -0400 -@@ -1019,6 +1019,12 @@ - /* Define to profile with the Pentium timestamp counter */ - #undef WITH_TSC - -+/* Define to keep records of the number of instances of each type */ -+#undef COUNT_ALLOCS -+ -+/* Define to keep records on function call invocation */ -+#undef CALL_PROFILE -+ - /* Define if you want pymalloc to be disabled when running under valgrind */ - #undef WITH_VALGRIND - diff --git a/00114-statvfs-f_flag-constants.patch b/00114-statvfs-f_flag-constants.patch deleted file mode 100644 index 83e7b59..0000000 --- a/00114-statvfs-f_flag-constants.patch +++ /dev/null @@ -1,47 +0,0 @@ -diff -up Python-2.7rc1/Modules/posixmodule.c.statvfs-f-flag-constants Python-2.7rc1/Modules/posixmodule.c ---- Python-2.7rc1/Modules/posixmodule.c.statvfs-f-flag-constants 2010-05-15 17:45:30.000000000 -0400 -+++ Python-2.7rc1/Modules/posixmodule.c 2010-06-07 22:54:16.162068624 -0400 -@@ -9174,6 +9174,43 @@ all_ins(PyObject *d) - #endif - #endif - -+ /* These came from statvfs.h */ -+#ifdef ST_RDONLY -+ if (ins(d, "ST_RDONLY", (long)ST_RDONLY)) return -1; -+#endif /* ST_RDONLY */ -+#ifdef ST_NOSUID -+ if (ins(d, "ST_NOSUID", (long)ST_NOSUID)) return -1; -+#endif /* ST_NOSUID */ -+ -+ /* GNU extensions */ -+#ifdef ST_NODEV -+ if (ins(d, "ST_NODEV", (long)ST_NODEV)) return -1; -+#endif /* ST_NODEV */ -+#ifdef ST_NOEXEC -+ if (ins(d, "ST_NOEXEC", (long)ST_NOEXEC)) return -1; -+#endif /* ST_NOEXEC */ -+#ifdef ST_SYNCHRONOUS -+ if (ins(d, "ST_SYNCHRONOUS", (long)ST_SYNCHRONOUS)) return -1; -+#endif /* ST_SYNCHRONOUS */ -+#ifdef ST_MANDLOCK -+ if (ins(d, "ST_MANDLOCK", (long)ST_MANDLOCK)) return -1; -+#endif /* ST_MANDLOCK */ -+#ifdef ST_WRITE -+ if (ins(d, "ST_WRITE", (long)ST_WRITE)) return -1; -+#endif /* ST_WRITE */ -+#ifdef ST_APPEND -+ if (ins(d, "ST_APPEND", (long)ST_APPEND)) return -1; -+#endif /* ST_APPEND */ -+#ifdef ST_NOATIME -+ if (ins(d, "ST_NOATIME", (long)ST_NOATIME)) return -1; -+#endif /* ST_NOATIME */ -+#ifdef ST_NODIRATIME -+ if (ins(d, "ST_NODIRATIME", (long)ST_NODIRATIME)) return -1; -+#endif /* ST_NODIRATIME */ -+#ifdef ST_RELATIME -+ if (ins(d, "ST_RELATIME", (long)ST_RELATIME)) return -1; -+#endif /* ST_RELATIME */ -+ - #if defined(PYOS_OS2) - if (insertvalues(d)) return -1; - #endif diff --git a/00121-add-Modules-to-build-path.patch b/00121-add-Modules-to-build-path.patch deleted file mode 100644 index 6e3294d..0000000 --- a/00121-add-Modules-to-build-path.patch +++ /dev/null @@ -1,13 +0,0 @@ ---- Python-2.7.5/Lib/site.py.orig 2013-05-16 12:47:55.000000000 +0200 -+++ Python-2.7.5/Lib/site.py 2013-05-16 12:56:20.089058109 +0200 -@@ -529,6 +529,10 @@ def main(): - - abs__file__() - known_paths = removeduppaths() -+ from sysconfig import is_python_build -+ if is_python_build(): -+ from _sysconfigdata import build_time_vars -+ sys.path.append(os.path.join(build_time_vars['abs_builddir'], 'Modules')) - if ENABLE_USER_SITE is None: - ENABLE_USER_SITE = check_enableusersite() - known_paths = addusersitepackages(known_paths) diff --git a/00131-disable-tests-in-test_io.patch b/00131-disable-tests-in-test_io.patch deleted file mode 100644 index d81a2d0..0000000 --- a/00131-disable-tests-in-test_io.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up Python-2.7.2/Lib/test/test_io.py.disable-tests-in-test_io Python-2.7.2/Lib/test/test_io.py ---- Python-2.7.2/Lib/test/test_io.py.disable-tests-in-test_io 2011-09-01 14:18:45.963304089 -0400 -+++ Python-2.7.2/Lib/test/test_io.py 2011-09-01 15:08:53.796098413 -0400 -@@ -2669,6 +2669,7 @@ class SignalsTest(unittest.TestCase): - self.check_interrupted_read_retry(lambda x: x, - mode="r") - -+ @unittest.skip('rhbz#732998') - @unittest.skipUnless(threading, 'Threading required for this test.') - def check_interrupted_write_retry(self, item, **fdopen_kwargs): - """Check that a buffered write, when it gets interrupted (either diff --git a/00132-add-rpmbuild-hooks-to-unittest.patch b/00132-add-rpmbuild-hooks-to-unittest.patch deleted file mode 100644 index e63395f..0000000 --- a/00132-add-rpmbuild-hooks-to-unittest.patch +++ /dev/null @@ -1,68 +0,0 @@ -diff -up Python-2.7.2/Lib/unittest/case.py.add-rpmbuild-hooks-to-unittest Python-2.7.2/Lib/unittest/case.py ---- Python-2.7.2/Lib/unittest/case.py.add-rpmbuild-hooks-to-unittest 2011-09-08 14:45:47.677169191 -0400 -+++ Python-2.7.2/Lib/unittest/case.py 2011-09-08 16:01:36.287858159 -0400 -@@ -1,6 +1,7 @@ - """Test case implementation""" - - import collections -+import os - import sys - import functools - import difflib -@@ -94,6 +95,43 @@ def expectedFailure(func): - return wrapper - - -+# Non-standard/downstream-only hooks for handling issues with specific test -+# cases: -+ -+def _skipInRpmBuild(reason): -+ """ -+ Non-standard/downstream-only decorator for marking a specific unit test -+ to be skipped when run within the %check of an rpmbuild. -+ -+ Specifically, this takes effect when WITHIN_PYTHON_RPM_BUILD is set within -+ the environment, and has no effect otherwise. -+ """ -+ if 'WITHIN_PYTHON_RPM_BUILD' in os.environ: -+ return skip(reason) -+ else: -+ return _id -+ -+def _expectedFailureInRpmBuild(func): -+ """ -+ Non-standard/downstream-only decorator for marking a specific unit test -+ as expected to fail within the %check of an rpmbuild. -+ -+ Specifically, this takes effect when WITHIN_PYTHON_RPM_BUILD is set within -+ the environment, and has no effect otherwise. -+ """ -+ @functools.wraps(func) -+ def wrapper(*args, **kwargs): -+ if 'WITHIN_PYTHON_RPM_BUILD' in os.environ: -+ try: -+ func(*args, **kwargs) -+ except Exception: -+ raise _ExpectedFailure(sys.exc_info()) -+ raise _UnexpectedSuccess -+ else: -+ # Call directly: -+ func(*args, **kwargs) -+ return wrapper -+ - class _AssertRaisesContext(object): - """A context manager used to implement TestCase.assertRaises* methods.""" - -diff -up Python-2.7.2/Lib/unittest/__init__.py.add-rpmbuild-hooks-to-unittest Python-2.7.2/Lib/unittest/__init__.py ---- Python-2.7.2/Lib/unittest/__init__.py.add-rpmbuild-hooks-to-unittest 2011-09-08 14:59:39.534112310 -0400 -+++ Python-2.7.2/Lib/unittest/__init__.py 2011-09-08 15:07:09.191081562 -0400 -@@ -57,7 +57,8 @@ __unittest = True - - from .result import TestResult - from .case import (TestCase, FunctionTestCase, SkipTest, skip, skipIf, -- skipUnless, expectedFailure) -+ skipUnless, expectedFailure, -+ _skipInRpmBuild, _expectedFailureInRpmBuild) - from .suite import BaseTestSuite, TestSuite - from .loader import (TestLoader, defaultTestLoader, makeSuite, getTestCaseNames, - findTestCases) diff --git a/00133-skip-test_dl.patch b/00133-skip-test_dl.patch deleted file mode 100644 index 04ad05b..0000000 --- a/00133-skip-test_dl.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff -up Python-2.7.2/Lib/test/test_dl.py.skip-test_dl Python-2.7.2/Lib/test/test_dl.py ---- Python-2.7.2/Lib/test/test_dl.py.skip-test_dl 2011-09-08 15:18:40.529034289 -0400 -+++ Python-2.7.2/Lib/test/test_dl.py 2011-09-08 16:29:45.184742670 -0400 -@@ -13,6 +13,9 @@ sharedlibs = [ - ('/usr/lib/libc.dylib', 'getpid'), - ] - -+# (also, "dl" is deprecated in favor of ctypes) -+@unittest._skipInRpmBuild('fails on 64-bit builds: ' -+ 'module dl requires sizeof(int) == sizeof(long) == sizeof(char*)') - def test_main(): - for s, func in sharedlibs: - try: diff --git a/00136-skip-tests-of-seeking-stdin-in-rpmbuild.patch b/00136-skip-tests-of-seeking-stdin-in-rpmbuild.patch deleted file mode 100644 index 4d7626f..0000000 --- a/00136-skip-tests-of-seeking-stdin-in-rpmbuild.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up Python-2.7.6/Lib/test/test_file2k.py.stdin-test Python-2.7.6/Lib/test/test_file2k.py ---- Python-2.7.6/Lib/test/test_file2k.py.stdin-test 2013-11-10 08:36:40.000000000 +0100 -+++ Python-2.7.6/Lib/test/test_file2k.py 2014-01-29 14:28:01.029488055 +0100 -@@ -223,6 +223,7 @@ class OtherFileTests(unittest.TestCase): - else: - f.close() - -+ @unittest._skipInRpmBuild('seems not to raise the exception when run in Koji') - def testStdinSeek(self): - if sys.platform == 'osf1V5': - # This causes the interpreter to exit on OSF1 v5.1. diff --git a/00137-skip-distutils-tests-that-fail-in-rpmbuild.patch b/00137-skip-distutils-tests-that-fail-in-rpmbuild.patch deleted file mode 100644 index 7122a29..0000000 --- a/00137-skip-distutils-tests-that-fail-in-rpmbuild.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up Python-2.7.3/Lib/distutils/tests/test_bdist_rpm.py.mark-tests-that-fail-in-rpmbuild Python-2.7.3/Lib/distutils/tests/test_bdist_rpm.py ---- Python-2.7.3/Lib/distutils/tests/test_bdist_rpm.py.mark-tests-that-fail-in-rpmbuild 2012-04-09 19:07:29.000000000 -0400 -+++ Python-2.7.3/Lib/distutils/tests/test_bdist_rpm.py 2012-04-13 00:20:08.223819263 -0400 -@@ -24,6 +24,7 @@ setup(name='foo', version='0.1', py_modu - - """ - -+@unittest._skipInRpmBuild("don't try to nest one rpm build inside another rpm build") - class BuildRpmTestCase(support.TempdirManager, - support.EnvironGuard, - support.LoggingSilencer, -diff -up Python-2.7.3/Lib/distutils/tests/test_build_ext.py.mark-tests-that-fail-in-rpmbuild Python-2.7.3/Lib/distutils/tests/test_build_ext.py diff --git a/00138-fix-distutils-tests-in-debug-build.patch b/00138-fix-distutils-tests-in-debug-build.patch deleted file mode 100644 index 1fd1091..0000000 --- a/00138-fix-distutils-tests-in-debug-build.patch +++ /dev/null @@ -1,68 +0,0 @@ -diff -up Python-2.7.2/Lib/distutils/tests/test_build_ext.py.mark-tests-that-fail-in-rpmbuild Python-2.7.2/Lib/distutils/tests/test_build_ext.py ---- Python-2.7.2/Lib/distutils/tests/test_build_ext.py.mark-tests-that-fail-in-rpmbuild 2011-09-08 16:07:25.033834312 -0400 -+++ Python-2.7.2/Lib/distutils/tests/test_build_ext.py 2011-09-08 17:43:15.656441082 -0400 -@@ -330,6 +332,7 @@ class BuildExtTestCase(support.TempdirMa - self.assertEqual(lastdir, 'bar') - - def test_ext_fullpath(self): -+ debug_ext = sysconfig.get_config_var("DEBUG_EXT") - ext = sysconfig.get_config_vars()['SO'] - dist = Distribution() - cmd = build_ext(dist) -@@ -337,14 +340,14 @@ class BuildExtTestCase(support.TempdirMa - cmd.distribution.package_dir = {'': 'src'} - cmd.distribution.packages = ['lxml', 'lxml.html'] - curdir = os.getcwd() -- wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + ext) -+ wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + debug_ext + ext) - path = cmd.get_ext_fullpath('lxml.etree') - self.assertEqual(wanted, path) - - # building lxml.etree not inplace - cmd.inplace = 0 - cmd.build_lib = os.path.join(curdir, 'tmpdir') -- wanted = os.path.join(curdir, 'tmpdir', 'lxml', 'etree' + ext) -+ wanted = os.path.join(curdir, 'tmpdir', 'lxml', 'etree' + debug_ext + ext) - path = cmd.get_ext_fullpath('lxml.etree') - self.assertEqual(wanted, path) - -@@ -354,13 +357,13 @@ class BuildExtTestCase(support.TempdirMa - cmd.distribution.packages = ['twisted', 'twisted.runner.portmap'] - path = cmd.get_ext_fullpath('twisted.runner.portmap') - wanted = os.path.join(curdir, 'tmpdir', 'twisted', 'runner', -- 'portmap' + ext) -+ 'portmap' + debug_ext + ext) - self.assertEqual(wanted, path) - - # building twisted.runner.portmap inplace - cmd.inplace = 1 - path = cmd.get_ext_fullpath('twisted.runner.portmap') -- wanted = os.path.join(curdir, 'twisted', 'runner', 'portmap' + ext) -+ wanted = os.path.join(curdir, 'twisted', 'runner', 'portmap' + debug_ext + ext) - self.assertEqual(wanted, path) - - def test_build_ext_inplace(self): -@@ -373,8 +376,9 @@ class BuildExtTestCase(support.TempdirMa - cmd.distribution.package_dir = {'': 'src'} - cmd.distribution.packages = ['lxml', 'lxml.html'] - curdir = os.getcwd() -+ debug_ext = sysconfig.get_config_var("DEBUG_EXT") - ext = sysconfig.get_config_var("SO") -- wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + ext) -+ wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + debug_ext + ext) - path = cmd.get_ext_fullpath('lxml.etree') - self.assertEqual(wanted, path) - -@@ -412,10 +416,11 @@ class BuildExtTestCase(support.TempdirMa - dist = Distribution({'name': 'UpdateManager'}) - cmd = build_ext(dist) - cmd.ensure_finalized() -+ debug_ext = sysconfig.get_config_var("DEBUG_EXT") - ext = sysconfig.get_config_var("SO") - ext_name = os.path.join('UpdateManager', 'fdsend') - ext_path = cmd.get_ext_fullpath(ext_name) -- wanted = os.path.join(cmd.build_lib, 'UpdateManager', 'fdsend' + ext) -+ wanted = os.path.join(cmd.build_lib, 'UpdateManager', 'fdsend' + debug_ext + ext) - self.assertEqual(ext_path, wanted) - - @unittest.skipUnless(sys.platform == 'win32', 'these tests require Windows') diff --git a/00139-skip-test_float-known-failure-on-arm.patch b/00139-skip-test_float-known-failure-on-arm.patch deleted file mode 100644 index 9d0bfad..0000000 --- a/00139-skip-test_float-known-failure-on-arm.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up Python-2.7.2/Lib/test/test_float.py.skip-test_float-known-failure-on-arm Python-2.7.2/Lib/test/test_float.py ---- Python-2.7.2/Lib/test/test_float.py.skip-test_float-known-failure-on-arm 2011-09-08 19:34:09.000986128 -0400 -+++ Python-2.7.2/Lib/test/test_float.py 2011-09-08 19:34:57.969982779 -0400 -@@ -1072,6 +1072,7 @@ class HexFloatTestCase(unittest.TestCase - self.identical(got, expected) - - -+ @unittest.skip('Known failure on ARM: http://bugs.python.org/issue8265') - def test_from_hex(self): - MIN = self.MIN; - MAX = self.MAX; diff --git a/00140-skip-test_ctypes-known-failure-on-sparc.patch b/00140-skip-test_ctypes-known-failure-on-sparc.patch deleted file mode 100644 index 95aa41e..0000000 --- a/00140-skip-test_ctypes-known-failure-on-sparc.patch +++ /dev/null @@ -1,11 +0,0 @@ -diff -up Python-2.7.2/Lib/ctypes/test/test_callbacks.py.skip-test_ctypes-known-failure-on-sparc Python-2.7.2/Lib/ctypes/test/test_callbacks.py ---- Python-2.7.2/Lib/ctypes/test/test_callbacks.py.skip-test_ctypes-known-failure-on-sparc 2011-09-08 19:42:35.541951490 -0400 -+++ Python-2.7.2/Lib/ctypes/test/test_callbacks.py 2011-09-08 19:43:40.676947036 -0400 -@@ -67,6 +67,7 @@ class Callbacks(unittest.TestCase): - self.check_type(c_longlong, 42) - self.check_type(c_longlong, -42) - -+ @unittest.skip('Known failure on Sparc: http://bugs.python.org/issue8314') - def test_ulonglong(self): - # test some 64-bit values, with and without msb set. - self.check_type(c_ulonglong, 10955412242170339782) diff --git a/00142-skip-failing-pty-tests-in-rpmbuild.patch b/00142-skip-failing-pty-tests-in-rpmbuild.patch deleted file mode 100644 index 2f51165..0000000 --- a/00142-skip-failing-pty-tests-in-rpmbuild.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff -up Python-2.7.6/Lib/test/test_openpty.py.tty-fail Python-2.7.6/Lib/test/test_openpty.py ---- Python-2.7.6/Lib/test/test_openpty.py.tty-fail 2014-01-29 14:31:43.761343267 +0100 -+++ Python-2.7.6/Lib/test/test_openpty.py 2014-01-29 14:32:19.284090165 +0100 -@@ -8,6 +8,7 @@ if not hasattr(os, "openpty"): - - - class OpenptyTest(unittest.TestCase): -+ @unittest._skipInRpmBuild('sometimes fails in Koji, possibly due to a mock issue (rhbz#714627)') - def test(self): - master, slave = os.openpty() - self.addCleanup(os.close, master) -diff -up Python-2.7.6/Lib/test/test_pty.py.tty-fail Python-2.7.6/Lib/test/test_pty.py ---- Python-2.7.6/Lib/test/test_pty.py.tty-fail 2013-11-10 08:36:40.000000000 +0100 -+++ Python-2.7.6/Lib/test/test_pty.py 2014-01-29 14:31:43.761343267 +0100 -@@ -111,6 +111,7 @@ class PtyTest(unittest.TestCase): - os.close(master_fd) - - -+ @unittest._skipInRpmBuild('sometimes fails in Koji, possibly due to a mock issue (rhbz#714627)') - def test_fork(self): - debug("calling pty.fork()") - pid, master_fd = pty.fork() diff --git a/README.md b/README.md new file mode 100644 index 0000000..24b9ea2 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# Package Not Available +This package is not available on CentOS Stream 10. +It may be available on another branch. \ No newline at end of file diff --git a/dead.package b/dead.package new file mode 100644 index 0000000..2a43e8f --- /dev/null +++ b/dead.package @@ -0,0 +1 @@ +python2 package is retired on branch c10s for CS-2551 \ No newline at end of file