Update Python to 2.6.6. Tested by many.

sthen@ ok
This commit is contained in:
fgsch 2010-09-16 22:36:08 +00:00
parent 06cc1c44bb
commit 42c9e879be
9 changed files with 94 additions and 85 deletions

View File

@ -1,20 +1,18 @@
# $OpenBSD: Makefile,v 1.17 2010/07/23 13:56:26 sthen Exp $
# $OpenBSD: Makefile,v 1.18 2010/09/16 22:36:08 fgsch Exp $
VERSION= 2.6
PATCHLEVEL= .5
SHARED_LIBS= python2.6 1.0
# PSUBDIR= python/${VERSION}
VERSION = 2.6
PATCHLEVEL = .6
SHARED_LIBS = python2.6 1.0
BROKEN-mips64 = Floating point exception while generating pyc objects
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "amd64" || \
${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH:Mmips64*}
PATCH_LIST= patch-* sup64-*
PATCH_LIST = patch-* sup64-*
.endif
AUTOCONF_VERSION= 2.61
CONFIGURE_ARGS+= --with-cxx_main
AUTOCONF_VERSION = 2.61
CONFIGURE_ARGS += --with-cxx_main
post-extract:
rm -r ${WRKDIST}/Modules/expat

View File

@ -1,5 +1,5 @@
MD5 (Python-2.6.5.tgz) = zQS1uTg7bB/M2qmRr3Ys9A==
RMD160 (Python-2.6.5.tgz) = H8cyzIpdCm6QfntysuWQhYy01Kw=
SHA1 (Python-2.6.5.tgz) = VeMBXMYeohEePsm8sipift8UagA=
SHA256 (Python-2.6.5.tgz) = szHa/c4zYYNP7ng3ldT2iufPfTeekTfC2OhTHOphXt4=
SIZE (Python-2.6.5.tgz) = 13209175
MD5 (Python-2.6.6.tgz) = svIJ3ycKMzFeYsH/rBk38A==
RMD160 (Python-2.6.6.tgz) = 6Qp/+LUUUdsB+khu5r7daT6jn+8=
SHA1 (Python-2.6.6.tgz) = B3G7ppMFq+20uHWldVDO5QBBKs8=
SHA256 (Python-2.6.6.tgz) = Ny9m20bXcyFORhnfF5SiZEkVj2JhONTSFBpkwvAX+uE=
SIZE (Python-2.6.6.tgz) = 13318547

View File

@ -1,26 +1,33 @@
$OpenBSD: patch-Lib_test_test_signal_py,v 1.2 2010/07/23 13:56:26 sthen Exp $
$OpenBSD: patch-Lib_test_test_signal_py,v 1.3 2010/09/16 22:36:08 fgsch Exp $
workarounds for breakage caused by libpthread
--- Lib/test/test_signal.py.orig Mon Nov 9 19:59:08 2009
+++ Lib/test/test_signal.py Thu Jun 17 13:04:43 2010
@@ -291,6 +291,9 @@ class SiginterruptTest(unittest.TestCase):
self.assertEquals(i, True)
def test_siginterrupt_off(self):
+ # XXX broken by libpthread's internal hooking of signals
+ return
+
i=self.readpipe_interrupted(lambda: signal.siginterrupt(self.signum, 0))
self.assertEquals(i, False)
@@ -377,6 +380,9 @@ class ItimerTest(unittest.TestCase):
self.assertEquals(self.hndl_called, True)
--- Lib/test/test_signal.py.orig Thu Jun 3 17:04:47 2010
+++ Lib/test/test_signal.py Mon Aug 30 13:50:39 2010
@@ -364,6 +364,12 @@ class SiginterruptTest(unittest.TestCase):
a false value for the second argument, when that signal arrives, it
does not interrupt a syscall that's in progress.
"""
+ if sys.platform.startswith('openbsd'):
+ if test_support.verbose:
+ sys.stderr.write('skipping -- siginterrupt not reliable (does '
+ 'not mix well with threading) on %s\n' %
+ sys.platform)
+ return
signal.siginterrupt(self.signum, 0)
i = self.readpipe_interrupted()
self.assertFalse(i)
@@ -463,10 +469,11 @@ class ItimerTest(unittest.TestCase):
def test_itimer_prof(self):
+ # XXX broken by libpthread's internal use of SIGPROF
+ return
+
# Issue 3864, unknown if this affects earlier versions of freebsd also
- if sys.platform=='freebsd6':
+ if sys.platform=='freebsd6' or sys.platform.startswith('openbsd'):
if test_support.verbose:
sys.stderr.write('skipping -- itimer not reliable (does not '
- 'mix well with threading) on freebsd6\n')
+ 'mix well with threading) on %s\n' %
+ sys.platform)
return
self.itimer = signal.ITIMER_PROF
signal.signal(signal.SIGPROF, self.sig_prof)
signal.setitimer(self.itimer, 0.2, 0.2)

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-Lib_test_test_sys_py,v 1.2 2009/05/03 22:26:27 djm Exp $
--- Lib/test/test_sys.py.orig Mon Apr 6 07:21:05 2009
+++ Lib/test/test_sys.py Sun Apr 19 10:28:52 2009
@@ -353,10 +353,11 @@ class SysModuleTest(unittest.TestCase):
$OpenBSD: patch-Lib_test_test_sys_py,v 1.3 2010/09/16 22:36:08 fgsch Exp $
--- Lib/test/test_sys.py.orig Mon Aug 2 19:40:55 2010
+++ Lib/test/test_sys.py Mon Aug 30 13:46:31 2010
@@ -374,10 +374,11 @@ class SysModuleTest(unittest.TestCase):
self.assert_(vi[3] in ("alpha", "beta", "candidate", "final"))
self.assert_(isinstance(vi[4], int))

View File

@ -1,12 +1,12 @@
$OpenBSD: patch-Modules_mathmodule_c,v 1.2 2009/05/03 22:26:27 djm Exp $
--- Modules/mathmodule.c.orig Mon Dec 22 04:01:26 2008
+++ Modules/mathmodule.c Sun Apr 19 10:28:53 2009
$OpenBSD: patch-Modules_mathmodule_c,v 1.3 2010/09/16 22:36:08 fgsch Exp $
--- Modules/mathmodule.c.orig Fri Jun 25 21:21:43 2010
+++ Modules/mathmodule.c Mon Aug 30 13:52:05 2010
@@ -235,7 +235,7 @@ math_1(PyObject *arg, double (*func) (double), int can
else
errno = 0;
}
- else if (Py_IS_INFINITY(r)) {
+ else if (errno != EDOM && Py_IS_INFINITY(r)) {
if (Py_IS_FINITE(x))
errno = can_overflow ? ERANGE : EDOM;
else
else
errno = 0;
}
- else if (Py_IS_INFINITY(r)) {
+ else if (errno != EDOM && Py_IS_INFINITY(r)) {
if (Py_IS_FINITE(x))
errno = can_overflow ? ERANGE : EDOM;
else

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-configure_in,v 1.4 2010/07/23 13:56:26 sthen Exp $
--- configure.in.orig Tue Mar 9 21:47:28 2010
+++ configure.in Thu Jun 17 13:04:44 2010
@@ -1815,27 +1815,13 @@ then
$OpenBSD: patch-configure_in,v 1.5 2010/09/16 22:36:08 fgsch Exp $
--- configure.in.orig Tue May 25 03:27:03 2010
+++ configure.in Mon Aug 30 13:55:47 2010
@@ -1831,27 +1831,13 @@ then
;;
Linux*|GNU*|QNX*) LDSHARED='$(CC) -shared';;
BSD/OS*/4*) LDSHARED="gcc -shared";;
@ -9,7 +9,7 @@ $OpenBSD: patch-configure_in,v 1.4 2010/07/23 13:56:26 sthen Exp $
+ FreeBSD*|OpenBSD*)
if [[ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]]
then
LDSHARED="$CC -shared ${LDFLAGS}"
LDSHARED='$(CC) -shared ${LDFLAGS}'
else
LDSHARED="ld -Bshareable ${LDFLAGS}"
fi;;
@ -30,7 +30,7 @@ $OpenBSD: patch-configure_in,v 1.4 2010/07/23 13:56:26 sthen Exp $
NetBSD*|DragonFly*) LDSHARED="cc -shared ${LDFLAGS}";;
OpenUNIX*|UnixWare*)
if test "$GCC" = "yes"
@@ -1987,9 +1973,10 @@ AC_CHECK_LIB(dld, shl_load) # Dynamic linking for HP-U
@@ -2003,9 +1989,10 @@ AC_CHECK_LIB(dld, shl_load) # Dynamic linking for HP-U
# only check for sem_init if thread support is requested
if test "$with_threads" = "yes" -o -z "$with_threads"; then

View File

@ -1,7 +1,7 @@
$OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
--- setup.py.orig Mon Mar 8 07:08:25 2010
+++ setup.py Thu Jun 17 13:04:45 2010
@@ -19,6 +19,11 @@ from distutils.command.install_lib import install_lib
$OpenBSD: patch-setup_py,v 1.6 2010/09/16 22:36:08 fgsch Exp $
--- setup.py.orig Sat Jul 17 13:31:09 2010
+++ setup.py Mon Aug 30 13:54:43 2010
@@ -20,6 +20,11 @@ from distutils.spawn import find_executable
# This global variable is used to hold the list of modules to be disabled.
disabled_module_list = []
@ -13,7 +13,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
def add_dir_to_list(dirlist, dir):
"""Add the directory 'dir' to the list 'dirlist' (at the front) if
1) 'dir' is not already in 'dirlist'
@@ -310,8 +315,8 @@ class PyBuildExt(build_ext):
@@ -356,8 +361,8 @@ class PyBuildExt(build_ext):
def detect_modules(self):
# Ensure that /usr/local is always used
@ -24,7 +24,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
# Add paths specified in the environment variables LDFLAGS and
# CPPFLAGS for header and library files.
@@ -617,8 +622,6 @@ class PyBuildExt(build_ext):
@@ -691,8 +696,6 @@ class PyBuildExt(build_ext):
depends = ['socketmodule.h']) )
# Detect SSL support for the socket module (via _ssl)
search_for_ssl_incs_in = [
@ -33,7 +33,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
]
ssl_incs = find_file('openssl/ssl.h', inc_dirs,
search_for_ssl_incs_in
@@ -629,9 +632,7 @@ class PyBuildExt(build_ext):
@@ -703,9 +706,7 @@ class PyBuildExt(build_ext):
if krb5_h:
ssl_incs += krb5_h
ssl_libs = find_library_file(self.compiler, 'ssl',lib_dirs,
@ -44,7 +44,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
if (ssl_incs is not None and
ssl_libs is not None):
@@ -725,7 +726,7 @@ class PyBuildExt(build_ext):
@@ -799,7 +800,7 @@ class PyBuildExt(build_ext):
# BerkeleyDB 4.6.x is not stable on many architectures.
arch = platform_machine()
if arch not in ('i386', 'i486', 'i586', 'i686',
@ -53,7 +53,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
return False
return True
@@ -788,6 +789,7 @@ class PyBuildExt(build_ext):
@@ -862,6 +863,7 @@ class PyBuildExt(build_ext):
std_variants.append(os.path.join(dn, "db3.%d"%x))
db_inc_paths = std_variants + db_inc_paths
@ -61,15 +61,15 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
db_inc_paths = [p for p in db_inc_paths if os.path.exists(p)]
db_ver_inc_map = {}
@@ -844,6 +846,7 @@ class PyBuildExt(build_ext):
@@ -925,6 +927,7 @@ class PyBuildExt(build_ext):
db_incdir.replace("include", 'lib64'),
db_incdir.replace("include", 'lib'),
]
+ db_dirs_to_check = [usrlocal('lib/db4')]
db_dirs_to_check = filter(os.path.isdir, db_dirs_to_check)
# Look for a version specific db-X.Y before an ambiguoius dbX
@@ -852,6 +855,7 @@ class PyBuildExt(build_ext):
if sys.platform != 'darwin':
db_dirs_to_check = filter(os.path.isdir, db_dirs_to_check)
@@ -947,6 +950,7 @@ class PyBuildExt(build_ext):
# symlink to more general names?
for dblib in (('db-%d.%d' % db_ver),
('db%d%d' % db_ver),
@ -77,7 +77,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
('db%d' % db_ver[0])):
dblib_file = self.compiler.find_library_file(
db_dirs_to_check + lib_dirs, dblib )
@@ -899,6 +903,7 @@ class PyBuildExt(build_ext):
@@ -994,6 +998,7 @@ class PyBuildExt(build_ext):
'/usr/local/include/sqlite',
'/usr/local/include/sqlite3',
]
@ -85,7 +85,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
MIN_SQLITE_VERSION_NUMBER = (3, 0, 8)
MIN_SQLITE_VERSION = ".".join([str(x)
for x in MIN_SQLITE_VERSION_NUMBER])
@@ -937,6 +942,7 @@ class PyBuildExt(build_ext):
@@ -1039,6 +1044,7 @@ class PyBuildExt(build_ext):
os.path.join(sqlite_incdir, '..', '..', 'lib64'),
os.path.join(sqlite_incdir, '..', '..', 'lib'),
]
@ -93,16 +93,16 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
sqlite_libfile = self.compiler.find_library_file(
sqlite_dirs_to_check + lib_dirs, 'sqlite3')
if sqlite_libfile:
@@ -993,7 +999,7 @@ class PyBuildExt(build_ext):
# the more recent berkeleydb's db.h file first in the include path
# when attempting to compile and it will fail.
f = "/usr/include/db.h"
@@ -1101,7 +1107,7 @@ class PyBuildExt(build_ext):
sysroot = macosx_sdk_root()
f = os.path.join(sysroot, f[1:])
- if os.path.exists(f) and not db_incs:
+ if os.path.exists(f):
data = open(f).read()
m = re.search(r"#s*define\s+HASHVERSION\s+2\s*", data)
if m is not None:
@@ -1209,10 +1215,8 @@ class PyBuildExt(build_ext):
@@ -1313,10 +1319,8 @@ class PyBuildExt(build_ext):
define_macros = define_macros,
include_dirs = [expatinc],
sources = ['pyexpat.c',
@ -114,7 +114,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
))
# Fredrik Lundh's cElementTree module. Note that this also
@@ -1304,6 +1308,14 @@ class PyBuildExt(build_ext):
@@ -1408,6 +1412,14 @@ class PyBuildExt(build_ext):
)
libraries = []
@ -129,7 +129,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
else: # Linux and other unices
macros = dict(
HAVE_SEM_OPEN=1,
@@ -1348,6 +1360,9 @@ class PyBuildExt(build_ext):
@@ -1452,6 +1464,9 @@ class PyBuildExt(build_ext):
if platform in ('linux2', 'freebsd4', 'freebsd5', 'freebsd6',
'freebsd7', 'freebsd8'):
exts.append( Extension('ossaudiodev', ['ossaudiodev.c']) )
@ -139,7 +139,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
else:
missing.append('ossaudiodev')
@@ -1513,7 +1528,7 @@ class PyBuildExt(build_ext):
@@ -1625,7 +1640,7 @@ class PyBuildExt(build_ext):
# For 8.4a2, the X11 headers are not included. Rather than include a
# complicated search, this is a hard-coded path. It could bail out
# if X11 libs are not found...
@ -148,7 +148,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
frameworks = ['-framework', 'Tcl', '-framework', 'Tk']
# All existing framework builds of Tcl/Tk don't support 64-bit
@@ -1558,8 +1573,7 @@ class PyBuildExt(build_ext):
@@ -1675,8 +1690,7 @@ class PyBuildExt(build_ext):
# The versions with dots are used on Unix, and the versions without
# dots on Windows, for detection by cygwin.
tcllib = tklib = tcl_includes = tk_includes = None
@ -158,7 +158,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
tklib = self.compiler.find_library_file(lib_dirs, 'tk' + version)
tcllib = self.compiler.find_library_file(lib_dirs, 'tcl' + version)
if tklib and tcllib:
@@ -1600,17 +1614,9 @@ class PyBuildExt(build_ext):
@@ -1717,17 +1731,9 @@ class PyBuildExt(build_ext):
if platform == 'sunos5':
include_dirs.append('/usr/openwin/include')
added_lib_dirs.append('/usr/openwin/lib')
@ -179,7 +179,7 @@ $OpenBSD: patch-setup_py,v 1.5 2010/07/23 13:56:26 sthen Exp $
# If Cygwin, then verify that X is installed before proceeding
if platform == 'cygwin':
@@ -1911,7 +1917,7 @@ def main():
@@ -2028,7 +2034,7 @@ def main():
# Scripts to install
scripts = ['Tools/scripts/pydoc', 'Tools/scripts/idle',
'Tools/scripts/2to3',

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST-main,v 1.6 2010/07/23 13:56:26 sthen Exp $
@comment $OpenBSD: PLIST-main,v 1.7 2010/09/16 22:36:08 fgsch Exp $
@option no-default-conflict
@conflict python->=2.6,<2.7
@conflict python-bz2->=2.6,<2.7
@ -1277,7 +1277,7 @@ lib/python2.6/keyword.py
lib/python2.6/keyword.pyc
lib/python2.6/keyword.pyo
lib/python2.6/lib-dynload/
lib/python2.6/lib-dynload/Python-2.6.5-py2.6.egg-info
lib/python2.6/lib-dynload/Python-2.6.6-py2.6.egg-info
lib/python2.6/lib-dynload/_bisect.so
lib/python2.6/lib-dynload/_bytesio.so
lib/python2.6/lib-dynload/_codecs_cn.so
@ -1342,9 +1342,9 @@ lib/python2.6/lib-dynload/zlib.so
lib/python2.6/lib-old/
lib/python2.6/lib2to3/
lib/python2.6/lib2to3/Grammar.txt
lib/python2.6/lib2to3/Grammar2.6.5.final.0.pickle
lib/python2.6/lib2to3/Grammar2.6.6.final.0.pickle
lib/python2.6/lib2to3/PatternGrammar.txt
lib/python2.6/lib2to3/PatternGrammar2.6.5.final.0.pickle
lib/python2.6/lib2to3/PatternGrammar2.6.6.final.0.pickle
lib/python2.6/lib2to3/__init__.py
lib/python2.6/lib2to3/__init__.pyc
lib/python2.6/lib2to3/__init__.pyo
@ -1382,6 +1382,9 @@ lib/python2.6/lib2to3/fixes/fix_exec.pyo
lib/python2.6/lib2to3/fixes/fix_execfile.py
lib/python2.6/lib2to3/fixes/fix_execfile.pyc
lib/python2.6/lib2to3/fixes/fix_execfile.pyo
lib/python2.6/lib2to3/fixes/fix_exitfunc.py
lib/python2.6/lib2to3/fixes/fix_exitfunc.pyc
lib/python2.6/lib2to3/fixes/fix_exitfunc.pyo
lib/python2.6/lib2to3/fixes/fix_filter.py
lib/python2.6/lib2to3/fixes/fix_filter.pyc
lib/python2.6/lib2to3/fixes/fix_filter.pyo

View File

@ -1,4 +1,4 @@
@comment $OpenBSD: PLIST-tests,v 1.6 2010/07/23 13:56:26 sthen Exp $
@comment $OpenBSD: PLIST-tests,v 1.7 2010/09/16 22:36:08 fgsch Exp $
@option no-default-conflict
@conflict python-tests->=2.6,<2.7
lib/python2.6/test/
@ -261,6 +261,7 @@ lib/python2.6/test/seq_tests.py
lib/python2.6/test/seq_tests.pyc
lib/python2.6/test/seq_tests.pyo
lib/python2.6/test/sgml_input.html
lib/python2.6/test/sha256.pem
lib/python2.6/test/sortperf.py
lib/python2.6/test/sortperf.pyc
lib/python2.6/test/sortperf.pyo