python3: bump version.

This commit is contained in:
Jerome Duval
2017-07-25 22:27:21 +02:00
parent eb7078e7e7
commit b6225dd525
2 changed files with 35 additions and 48 deletions

View File

@@ -1,4 +1,4 @@
From 0172d4c19e066892e3009ae5fe41e7aa2a9bcff7 Mon Sep 17 00:00:00 2001
From 74a0b292a4ae813bd7d145a28a265be0fbdeed71 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Thu, 10 Apr 2014 16:03:33 +0000
Subject: initial Haiku patch
@@ -86,12 +86,12 @@ index 0258d3d..aaec6e6 100644
def finalize_other(self):
"""Finalizes options for non-posix platforms"""
diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
index 8bf1a70..edb302d 100644
index 2bcd1dd..8d8ff39 100644
--- a/Lib/distutils/sysconfig.py
+++ b/Lib/distutils/sysconfig.py
@@ -102,7 +102,8 @@ def get_python_inc(plat_specific=0, prefix=None):
@@ -99,7 +99,8 @@ def get_python_inc(plat_specific=0, prefix=None):
incdir = os.path.join(get_config_var('srcdir'), 'Include')
return os.path.normpath(incdir)
return os.path.normpath(incdir)
python_dir = 'python' + get_python_version() + build_flags
- return os.path.join(prefix, "include", python_dir)
+ inc_dir = "include" if sys.platform != "haiku1" else "develop/headers"
@@ -99,7 +99,7 @@ index 8bf1a70..edb302d 100644
elif os.name == "nt":
return os.path.join(prefix, "include")
else:
@@ -132,12 +133,20 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
@@ -129,12 +130,20 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
prefix = plat_specific and EXEC_PREFIX or PREFIX
if os.name == "posix":
@@ -156,10 +156,10 @@ index 0fc9200..17596a1 100644
"python%d.%d" % sys.version_info[:2],
"site-packages"))
diff --git a/Lib/test/test_fileio.py b/Lib/test/test_fileio.py
index 3da210a..e669ce9 100644
index 57a0265..ea316a7 100644
--- a/Lib/test/test_fileio.py
+++ b/Lib/test/test_fileio.py
@@ -378,6 +378,7 @@ class OtherFileTests:
@@ -384,6 +384,7 @@ class OtherFileTests:
self.assertEqual(f.writable(), True)
if sys.platform != "darwin" and \
'bsd' not in sys.platform and \
@@ -168,10 +168,10 @@ index 3da210a..e669ce9 100644
# Somehow /dev/tty appears seekable on some BSDs
self.assertEqual(f.seekable(), False)
diff --git a/Makefile.pre.in b/Makefile.pre.in
index 8f27d73..06c1b24 100644
index 82e8307..0b9a49b 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -130,7 +130,7 @@ BINDIR= @bindir@
@@ -132,7 +132,7 @@ BINDIR= @bindir@
LIBDIR= @libdir@
MANDIR= @mandir@
INCLUDEDIR= @includedir@
@@ -180,19 +180,6 @@ index 8f27d73..06c1b24 100644
SCRIPTDIR= $(prefix)/lib
ABIFLAGS= @ABIFLAGS@
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 8f8ba25..ff68780 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -12729,7 +12729,7 @@ all_ins(PyObject *m)
if (PyModule_AddIntMacro(m, SCHED_RR)) return -1;
#endif
#ifdef SCHED_SPORADIC
- if (PyModule_AddIntMacro(m, SCHED_SPORADIC) return -1;
+ if (PyModule_AddIntMacro(m, SCHED_SPORADIC)) return -1;
#endif
#ifdef SCHED_BATCH
if (PyModule_AddIntMacro(m, SCHED_BATCH)) return -1;
diff --git a/Modules/resource.c b/Modules/resource.c
index 113ad5c..b9de0ab 100644
--- a/Modules/resource.c
@@ -293,10 +280,10 @@ index 113ad5c..b9de0ab 100644
#endif
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c
index f4edc06..d3b47c7 100644
index 42aec59..99940dc 100644
--- a/Modules/socketmodule.c
+++ b/Modules/socketmodule.c
@@ -6877,7 +6877,9 @@ PyInit__socket(void)
@@ -6847,7 +6847,9 @@ PyInit__socket(void)
/* SOCK_RAW is marked as optional in the POSIX specification */
PyModule_AddIntMacro(m, SOCK_RAW);
#endif
@@ -307,7 +294,7 @@ index f4edc06..d3b47c7 100644
PyModule_AddIntMacro(m, SOCK_RDM);
#endif
diff --git a/Modules/socketmodule.h b/Modules/socketmodule.h
index 3cce927..6241a7d 100644
index 03f982b..623b98a 100644
--- a/Modules/socketmodule.h
+++ b/Modules/socketmodule.h
@@ -54,6 +54,10 @@ typedef int socklen_t;
@@ -336,7 +323,7 @@ index 556a715..5044d19 100644
SETI(setIndex++, p->sp_max);
SETI(setIndex++, p->sp_warn);
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index ef5a34c..94c4332 100644
index 597e26e..8530f46 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -21,7 +21,7 @@
@@ -374,10 +361,10 @@ index 4363c0c..40994b0 100755
def main():
global filedict
diff --git a/configure.ac b/configure.ac
index 9eacf52..99059f9 100644
index 9620067..409bb47 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1166,6 +1166,16 @@ if test $enable_shared = "yes"; then
@@ -1157,6 +1157,16 @@ if test $enable_shared = "yes"; then
PY3LIBRARY=libpython3.so
fi
;;
@@ -394,7 +381,7 @@ index 9eacf52..99059f9 100644
hp*|HP*)
case `uname -m` in
ia64)
@@ -1242,6 +1252,7 @@ AC_PROG_MKDIR_P
@@ -1233,6 +1243,7 @@ AC_PROG_MKDIR_P
AC_SUBST(LN)
if test -z "$LN" ; then
case $ac_sys_system in
@@ -402,7 +389,7 @@ index 9eacf52..99059f9 100644
CYGWIN*) LN="ln -s";;
*) LN=ln;;
esac
@@ -2478,7 +2489,7 @@ then
@@ -2510,7 +2521,7 @@ then
BLDSHARED="$LDSHARED"
fi
;;
@@ -411,7 +398,7 @@ index 9eacf52..99059f9 100644
LDSHARED='$(CC) -shared'
LDCXXSHARED='$(CXX) -shared';;
BSD/OS*/4*)
@@ -2548,7 +2559,7 @@ then
@@ -2580,7 +2591,7 @@ then
else CCSHARED="+z";
fi;;
Linux-android*) ;;
@@ -420,7 +407,7 @@ index 9eacf52..99059f9 100644
BSD/OS*/4*) CCSHARED="-fpic";;
FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
OpenUNIX*|UnixWare*)
@@ -2580,7 +2591,7 @@ then
@@ -2612,7 +2623,7 @@ then
# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Linux-android*) LINKFORSHARED="-pie -Xlinker -export-dynamic";;
@@ -429,7 +416,7 @@ index 9eacf52..99059f9 100644
# -u libsys_s pulls in all symbols in libsys
Darwin/*)
LINKFORSHARED="$extra_undefs -framework CoreFoundation"
@@ -2762,6 +2773,12 @@ LDFLAGS="-fsanitize=address $LDFLAGS"
@@ -2793,6 +2804,12 @@ LDFLAGS="-fsanitize=address $LDFLAGS"
AC_CHECK_LIB(nsl, t_open, [LIBS="-lnsl $LIBS"]) # SVR4
AC_CHECK_LIB(socket, socket, [LIBS="-lsocket $LIBS"], [], $LIBS) # SVR4 sockets
@@ -442,7 +429,7 @@ index 9eacf52..99059f9 100644
AC_MSG_CHECKING(for --with-libs)
AC_ARG_WITH(libs,
AS_HELP_STRING([--with-libs='lib1 ...'], [link against additional libs]),
@@ -4165,6 +4182,7 @@ fi],
@@ -4196,6 +4213,7 @@ fi],
AC_SUBST(LIBM)
case $ac_sys_system in
Darwin) ;;
@@ -451,7 +438,7 @@ index 9eacf52..99059f9 100644
esac
AC_MSG_CHECKING(for --with-libm=STRING)
diff --git a/setup.py b/setup.py
index f04bf22..718c03a 100644
index fe47797..33b5c1d 100644
--- a/setup.py
+++ b/setup.py
@@ -480,8 +480,8 @@ class PyBuildExt(build_ext):
@@ -526,7 +513,7 @@ index f04bf22..718c03a 100644
libraries = ['ssl', 'crypto']) )
else:
print("warning: openssl 0x%08x is too old for _hashlib" %
@@ -1330,7 +1343,7 @@ class PyBuildExt(build_ext):
@@ -1333,7 +1346,7 @@ class PyBuildExt(build_ext):
exts.append( Extension('resource', ['resource.c']) )
# Sun yellow pages. Some systems have the functions in libc.
@@ -536,20 +523,20 @@ index f04bf22..718c03a 100644
if (self.compiler.find_library_file(lib_dirs, 'nsl')):
libs = ['nsl']
--
2.12.2
2.13.3
From 98f3a8c3e3d810181523691d2f340aba0a35f538 Mon Sep 17 00:00:00 2001
From 63030dfb8099b294af9b670dde71108c6a81f939 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Sun, 16 Apr 2017 10:05:42 +0200
Subject: fix for negative errnos
diff --git a/Lib/subprocess.py b/Lib/subprocess.py
index 822ddb4..5334f2d 100644
index b790cbd..25f8555 100644
--- a/Lib/subprocess.py
+++ b/Lib/subprocess.py
@@ -1312,6 +1312,8 @@ class Popen(object):
@@ -1319,6 +1319,8 @@ class Popen(object):
err_msg = err_msg.decode(errors="surrogatepass")
if issubclass(child_exception_type, OSError) and hex_errno:
errno_num = int(hex_errno, 16)
@@ -559,10 +546,10 @@ index 822ddb4..5334f2d 100644
if child_exec_never_called:
err_msg = ""
diff --git a/Modules/_posixsubprocess.c b/Modules/_posixsubprocess.c
index 5007a39..625c507 100644
index d1434d5..658cda9 100644
--- a/Modules/_posixsubprocess.c
+++ b/Modules/_posixsubprocess.c
@@ -521,6 +521,10 @@ error:
@@ -523,6 +523,10 @@ error:
char *cur;
_Py_write_noraise(errpipe_write, "OSError:", 8);
cur = hex_errno + sizeof(hex_errno);
@@ -574,10 +561,10 @@ index 5007a39..625c507 100644
*--cur = Py_hexdigits[saved_errno % 16];
saved_errno /= 16;
--
2.12.2
2.13.3
From 253ba23338ad0d16d6b0df8811d26fe8cd9f7bc0 Mon Sep 17 00:00:00 2001
From 6f591223c9c16b2e5b85643693b391634c5f5732 Mon Sep 17 00:00:00 2001
From: Philippe Houdoin <philippe.houdoin@gmail.com>
Date: Wed, 24 May 2017 11:09:43 +0000
Subject: Implement CTypes's find_library for Haiku
@@ -658,5 +645,5 @@ index 339ae8a..d537963 100644
print(cdll.LoadLibrary("libm.so"))
print(cdll.LoadLibrary("libcrypt.so"))
--
2.12.2
2.13.3

View File

@@ -10,10 +10,10 @@ OSI-approved open source license.
"
HOMEPAGE="http://www.python.org"
LICENSE="Python"
COPYRIGHT="1990-2016, Python Software Foundation"
REVISION="4"
COPYRIGHT="1990-2017, Python Software Foundation"
REVISION="1"
SOURCE_URI="https://www.python.org/ftp/python/$portVersion/Python-$portVersion.tar.xz"
CHECKSUM_SHA256="a01810ddfcec216bcdb357a84bfaafdfaa0ca42bbdaa4cb7ff74f5a9961e4041"
CHECKSUM_SHA256="9229773be41ed144370f47f0f626a1579931f5a390f1e8e3853174d52edd64a9"
SOURCE_DIR="Python-$portVersion"
PATCHES="python3-$portVersion.patchset"