python: bump versions.

* remove old 2.7 recipe and patch.
This commit is contained in:
Jerome Duval
2015-12-09 23:16:18 +00:00
parent 319d43948c
commit 22e4fad806
5 changed files with 175 additions and 616 deletions

View File

@@ -1,577 +0,0 @@
diff -ruN Python-2.7.1-orig/Lib/plat-haiku1/IN.py Python-2.7.1/Lib/plat-haiku1/IN.py
--- Python-2.7.1-orig/Lib/plat-haiku1/IN.py 1969-12-31 19:00:00.000000000 -0500
+++ Python-2.7.1/Lib/plat-haiku1/IN.py 2010-11-28 06:45:27.716701696 -0500
@@ -0,0 +1,327 @@
+# Generated by h2py from /boot/develop/headers/be/net/netinet/in.h
+
+# Included from socket.h
+
+# Included from BeBuild.h
+B_BEOS_VERSION_4 = 0x0400
+B_BEOS_VERSION_4_5 = 0x0450
+B_BEOS_VERSION_5 = 0x0500
+B_BEOS_VERSION = B_BEOS_VERSION_5
+B_BEOS_VERSION_MAUI = B_BEOS_VERSION_5
+_PR2_COMPATIBLE_ = 1
+_PR3_COMPATIBLE_ = 1
+_R4_COMPATIBLE_ = 1
+_R4_5_COMPATIBLE_ = 1
+_PR2_COMPATIBLE_ = 0
+_PR3_COMPATIBLE_ = 0
+_R4_COMPATIBLE_ = 1
+_R4_5_COMPATIBLE_ = 1
+def _UNUSED(x): return x
+
+
+# Included from sys/types.h
+
+# Included from time.h
+
+# Included from be_setup.h
+def __std(ref): return ref
+
+__be_os = 2
+__dest_os = __be_os
+__MSL__ = 0x4011
+__GLIBC__ = -2
+__GLIBC_MINOR__ = 1
+
+# Included from null.h
+NULL = (0)
+NULL = 0L
+
+# Included from size_t.h
+
+# Included from stddef.h
+
+# Included from wchar_t.h
+CLOCKS_PER_SEC = 1000
+CLK_TCK = CLOCKS_PER_SEC
+MAX_TIMESTR = 70
+
+# Included from sys/time.h
+
+# Included from ByteOrder.h
+
+# Included from endian.h
+__LITTLE_ENDIAN = 1234
+LITTLE_ENDIAN = __LITTLE_ENDIAN
+__BYTE_ORDER = __LITTLE_ENDIAN
+BYTE_ORDER = __BYTE_ORDER
+__BIG_ENDIAN = 0
+BIG_ENDIAN = 0
+__BIG_ENDIAN = 4321
+BIG_ENDIAN = __BIG_ENDIAN
+__BYTE_ORDER = __BIG_ENDIAN
+BYTE_ORDER = __BYTE_ORDER
+__LITTLE_ENDIAN = 0
+LITTLE_ENDIAN = 0
+__PDP_ENDIAN = 3412
+PDP_ENDIAN = __PDP_ENDIAN
+
+# Included from SupportDefs.h
+
+# Included from Errors.h
+
+# Included from limits.h
+
+# Included from float.h
+FLT_ROUNDS = 1
+FLT_RADIX = 2
+FLT_MANT_DIG = 24
+FLT_DIG = 6
+FLT_MIN_EXP = (-125)
+FLT_MIN_10_EXP = (-37)
+FLT_MAX_EXP = 128
+FLT_MAX_10_EXP = 38
+DBL_MANT_DIG = 53
+DBL_DIG = 15
+DBL_MIN_EXP = (-1021)
+DBL_MIN_10_EXP = (-308)
+DBL_MAX_EXP = 1024
+DBL_MAX_10_EXP = 308
+LDBL_MANT_DIG = DBL_MANT_DIG
+LDBL_DIG = DBL_DIG
+LDBL_MIN_EXP = DBL_MIN_EXP
+LDBL_MIN_10_EXP = DBL_MIN_10_EXP
+LDBL_MAX_EXP = DBL_MAX_EXP
+LDBL_MAX_10_EXP = DBL_MAX_10_EXP
+CHAR_BIT = (8)
+SCHAR_MIN = (-127-1)
+SCHAR_MAX = (127)
+CHAR_MIN = SCHAR_MIN
+CHAR_MAX = SCHAR_MAX
+MB_LEN_MAX = (1)
+SHRT_MIN = (-32767-1)
+SHRT_MAX = (32767)
+LONG_MIN = (-2147483647L-1)
+LONG_MAX = (2147483647L)
+INT_MIN = LONG_MIN
+INT_MAX = LONG_MAX
+ARG_MAX = (32768)
+ATEXIT_MAX = (32)
+CHILD_MAX = (1024)
+IOV_MAX = (256)
+FILESIZEBITS = (64)
+LINK_MAX = (1)
+LOGIN_NAME_MAX = (32)
+MAX_CANON = (255)
+MAX_INPUT = (255)
+NAME_MAX = (256)
+NGROUPS_MAX = (32)
+OPEN_MAX = (128)
+PATH_MAX = (1024)
+PIPE_MAX = (512)
+SSIZE_MAX = (2147483647L)
+TTY_NAME_MAX = (256)
+TZNAME_MAX = (32)
+SYMLINKS_MAX = (16)
+_POSIX_ARG_MAX = (32768)
+_POSIX_CHILD_MAX = (1024)
+_POSIX_LINK_MAX = (1)
+_POSIX_LOGIN_NAME_MAX = (9)
+_POSIX_MAX_CANON = (255)
+_POSIX_MAX_INPUT = (255)
+_POSIX_NAME_MAX = (255)
+_POSIX_NGROUPS_MAX = (0)
+_POSIX_OPEN_MAX = (128)
+_POSIX_PATH_MAX = (1024)
+_POSIX_PIPE_BUF = (512)
+_POSIX_SSIZE_MAX = (2147483647L)
+_POSIX_STREAM_MAX = (8)
+_POSIX_TTY_NAME_MAX = (256)
+_POSIX_TZNAME_MAX = (3)
+B_GENERAL_ERROR_BASE = LONG_MIN
+B_OS_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x1000
+B_APP_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x2000
+B_INTERFACE_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x3000
+B_MEDIA_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x4000
+B_TRANSLATION_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x4800
+B_MIDI_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x5000
+B_STORAGE_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x6000
+B_POSIX_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x7000
+B_MAIL_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x8000
+B_PRINT_ERROR_BASE = B_GENERAL_ERROR_BASE + 0x9000
+B_DEVICE_ERROR_BASE = B_GENERAL_ERROR_BASE + 0xa000
+B_ERRORS_END = (B_GENERAL_ERROR_BASE + 0xffff)
+E2BIG = (B_POSIX_ERROR_BASE + 1)
+ECHILD = (B_POSIX_ERROR_BASE + 2)
+EDEADLK = (B_POSIX_ERROR_BASE + 3)
+EFBIG = (B_POSIX_ERROR_BASE + 4)
+EMLINK = (B_POSIX_ERROR_BASE + 5)
+ENFILE = (B_POSIX_ERROR_BASE + 6)
+ENODEV = (B_POSIX_ERROR_BASE + 7)
+ENOLCK = (B_POSIX_ERROR_BASE + 8)
+ENOSYS = (B_POSIX_ERROR_BASE + 9)
+ENOTTY = (B_POSIX_ERROR_BASE + 10)
+ENXIO = (B_POSIX_ERROR_BASE + 11)
+ESPIPE = (B_POSIX_ERROR_BASE + 12)
+ESRCH = (B_POSIX_ERROR_BASE + 13)
+EFPOS = (B_POSIX_ERROR_BASE + 14)
+ESIGPARM = (B_POSIX_ERROR_BASE + 15)
+EDOM = (B_POSIX_ERROR_BASE + 16)
+ERANGE = (B_POSIX_ERROR_BASE + 17)
+EPROTOTYPE = (B_POSIX_ERROR_BASE + 18)
+EPROTONOSUPPORT = (B_POSIX_ERROR_BASE + 19)
+EPFNOSUPPORT = (B_POSIX_ERROR_BASE + 20)
+EAFNOSUPPORT = (B_POSIX_ERROR_BASE + 21)
+EADDRINUSE = (B_POSIX_ERROR_BASE + 22)
+EADDRNOTAVAIL = (B_POSIX_ERROR_BASE + 23)
+ENETDOWN = (B_POSIX_ERROR_BASE + 24)
+ENETUNREACH = (B_POSIX_ERROR_BASE + 25)
+ENETRESET = (B_POSIX_ERROR_BASE + 26)
+ECONNABORTED = (B_POSIX_ERROR_BASE + 27)
+ECONNRESET = (B_POSIX_ERROR_BASE + 28)
+EISCONN = (B_POSIX_ERROR_BASE + 29)
+ENOTCONN = (B_POSIX_ERROR_BASE + 30)
+ESHUTDOWN = (B_POSIX_ERROR_BASE + 31)
+ECONNREFUSED = (B_POSIX_ERROR_BASE + 32)
+EHOSTUNREACH = (B_POSIX_ERROR_BASE + 33)
+ENOPROTOOPT = (B_POSIX_ERROR_BASE + 34)
+ENOBUFS = (B_POSIX_ERROR_BASE + 35)
+EINPROGRESS = (B_POSIX_ERROR_BASE + 36)
+EALREADY = (B_POSIX_ERROR_BASE + 37)
+EILSEQ = (B_POSIX_ERROR_BASE + 38)
+ENOMSG = (B_POSIX_ERROR_BASE + 39)
+ESTALE = (B_POSIX_ERROR_BASE + 40)
+EOVERFLOW = (B_POSIX_ERROR_BASE + 41)
+EMSGSIZE = (B_POSIX_ERROR_BASE + 42)
+EOPNOTSUPP = (B_POSIX_ERROR_BASE + 43)
+ENOTSOCK = (B_POSIX_ERROR_BASE + 44)
+false = 0
+true = 1
+NULL = (0)
+FALSE = 0
+TRUE = 1
+
+# Included from TypeConstants.h
+B_HOST_IS_LENDIAN = 1
+B_HOST_IS_BENDIAN = 0
+def B_HOST_TO_LENDIAN_DOUBLE(arg): return (double)(arg)
+
+def B_HOST_TO_LENDIAN_FLOAT(arg): return (float)(arg)
+
+def B_HOST_TO_LENDIAN_INT64(arg): return (uint64)(arg)
+
+def B_HOST_TO_LENDIAN_INT32(arg): return (uint32)(arg)
+
+def B_HOST_TO_LENDIAN_INT16(arg): return (uint16)(arg)
+
+def B_HOST_TO_BENDIAN_DOUBLE(arg): return __swap_double(arg)
+
+def B_HOST_TO_BENDIAN_FLOAT(arg): return __swap_float(arg)
+
+def B_HOST_TO_BENDIAN_INT64(arg): return __swap_int64(arg)
+
+def B_HOST_TO_BENDIAN_INT32(arg): return __swap_int32(arg)
+
+def B_HOST_TO_BENDIAN_INT16(arg): return __swap_int16(arg)
+
+def B_LENDIAN_TO_HOST_DOUBLE(arg): return (double)(arg)
+
+def B_LENDIAN_TO_HOST_FLOAT(arg): return (float)(arg)
+
+def B_LENDIAN_TO_HOST_INT64(arg): return (uint64)(arg)
+
+def B_LENDIAN_TO_HOST_INT32(arg): return (uint32)(arg)
+
+def B_LENDIAN_TO_HOST_INT16(arg): return (uint16)(arg)
+
+def B_BENDIAN_TO_HOST_DOUBLE(arg): return __swap_double(arg)
+
+def B_BENDIAN_TO_HOST_FLOAT(arg): return __swap_float(arg)
+
+def B_BENDIAN_TO_HOST_INT64(arg): return __swap_int64(arg)
+
+def B_BENDIAN_TO_HOST_INT32(arg): return __swap_int32(arg)
+
+def B_BENDIAN_TO_HOST_INT16(arg): return __swap_int16(arg)
+
+B_HOST_IS_LENDIAN = 0
+B_HOST_IS_BENDIAN = 1
+def B_HOST_TO_LENDIAN_DOUBLE(arg): return __swap_double(arg)
+
+def B_HOST_TO_LENDIAN_FLOAT(arg): return __swap_float(arg)
+
+def B_HOST_TO_LENDIAN_INT64(arg): return __swap_int64(arg)
+
+def B_HOST_TO_LENDIAN_INT32(arg): return __swap_int32(arg)
+
+def B_HOST_TO_LENDIAN_INT16(arg): return __swap_int16(arg)
+
+def B_HOST_TO_BENDIAN_DOUBLE(arg): return (double)(arg)
+
+def B_HOST_TO_BENDIAN_FLOAT(arg): return (float)(arg)
+
+def B_HOST_TO_BENDIAN_INT64(arg): return (uint64)(arg)
+
+def B_HOST_TO_BENDIAN_INT32(arg): return (uint32)(arg)
+
+def B_HOST_TO_BENDIAN_INT16(arg): return (uint16)(arg)
+
+def B_LENDIAN_TO_HOST_DOUBLE(arg): return __swap_double(arg)
+
+def B_LENDIAN_TO_HOST_FLOAT(arg): return __swap_float(arg)
+
+def B_LENDIAN_TO_HOST_INT64(arg): return __swap_int64(arg)
+
+def B_LENDIAN_TO_HOST_INT32(arg): return __swap_int32(arg)
+
+def B_LENDIAN_TO_HOST_INT16(arg): return __swap_int16(arg)
+
+def B_BENDIAN_TO_HOST_DOUBLE(arg): return (double)(arg)
+
+def B_BENDIAN_TO_HOST_FLOAT(arg): return (float)(arg)
+
+def B_BENDIAN_TO_HOST_INT64(arg): return (uint64)(arg)
+
+def B_BENDIAN_TO_HOST_INT32(arg): return (uint32)(arg)
+
+def B_BENDIAN_TO_HOST_INT16(arg): return (uint16)(arg)
+
+def B_SWAP_DOUBLE(arg): return __swap_double(arg)
+
+def B_SWAP_FLOAT(arg): return __swap_float(arg)
+
+def B_SWAP_INT64(arg): return __swap_int64(arg)
+
+def B_SWAP_INT32(arg): return __swap_int32(arg)
+
+def B_SWAP_INT16(arg): return __swap_int16(arg)
+
+def htonl(x): return B_HOST_TO_BENDIAN_INT32(x)
+
+def ntohl(x): return B_BENDIAN_TO_HOST_INT32(x)
+
+def htons(x): return B_HOST_TO_BENDIAN_INT16(x)
+
+def ntohs(x): return B_BENDIAN_TO_HOST_INT16(x)
+
+AF_INET = 1
+INADDR_ANY = 0x00000000
+INADDR_BROADCAST = 0xffffffff
+INADDR_LOOPBACK = 0x7f000001
+SOL_SOCKET = 1
+SO_DEBUG = 1
+SO_REUSEADDR = 2
+SO_NONBLOCK = 3
+SO_REUSEPORT = 4
+MSG_OOB = 0x1
+SOCK_DGRAM = 1
+SOCK_STREAM = 2
+IPPROTO_UDP = 1
+IPPROTO_TCP = 2
+IPPROTO_ICMP = 3
+B_UDP_MAX_SIZE = (65536 - 1024)
+FD_SETSIZE = 256
+FDSETSIZE = FD_SETSIZE
+NFDBITS = 32
+def _FDMSKNO(fd): return ((fd) / NFDBITS)
+
+def _FDBITNO(fd): return ((fd) % NFDBITS)
diff -ruN Python-2.7.1-orig/Lib/plat-haiku1/regen Python-2.7.1/Lib/plat-haiku1/regen
--- Python-2.7.1-orig/Lib/plat-haiku1/regen 1969-12-31 19:00:00.000000000 -0500
+++ Python-2.7.1/Lib/plat-haiku1/regen 2010-11-28 06:45:28.041418752 -0500
@@ -0,0 +1,7 @@
+#! /bin/sh
+
+H2PY=../../Tools/scripts/h2py.py
+HEADERS=/boot/develop/headers
+
+set -v
+python $H2PY -i '(u_long)' $HEADERS/posix/netinet/in.h
diff -ruN Python-2.7.1-orig/Modules/resource.c Python-2.7.1/Modules/resource.c
--- Python-2.7.1-orig/Modules/resource.c 2010-05-09 10:46:46.053739520 -0400
+++ Python-2.7.1/Modules/resource.c 2010-11-28 06:45:28.044564480 -0500
@@ -86,6 +86,7 @@
PyFloat_FromDouble(doubletime(ru.ru_utime)));
PyStructSequence_SET_ITEM(result, 1,
PyFloat_FromDouble(doubletime(ru.ru_stime)));
+#ifndef __HAIKU__
PyStructSequence_SET_ITEM(result, 2, PyInt_FromLong(ru.ru_maxrss));
PyStructSequence_SET_ITEM(result, 3, PyInt_FromLong(ru.ru_ixrss));
PyStructSequence_SET_ITEM(result, 4, PyInt_FromLong(ru.ru_idrss));
@@ -100,6 +101,7 @@
PyStructSequence_SET_ITEM(result, 13, PyInt_FromLong(ru.ru_nsignals));
PyStructSequence_SET_ITEM(result, 14, PyInt_FromLong(ru.ru_nvcsw));
PyStructSequence_SET_ITEM(result, 15, PyInt_FromLong(ru.ru_nivcsw));
+#endif
if (PyErr_Occurred()) {
Py_DECREF(result);
diff -ruN Python-2.7.1-orig/Modules/socketmodule.c Python-2.7.1/Modules/socketmodule.c
--- Python-2.7.1-orig/Modules/socketmodule.c 2010-10-27 16:35:26.048234496 -0400
+++ Python-2.7.1/Modules/socketmodule.c 2010-11-28 06:45:28.049545216 -0500
@@ -4756,7 +4756,9 @@
#ifndef __BEOS__
/* We have incomplete socket support. */
PyModule_AddIntConstant(m, "SOCK_RAW", SOCK_RAW);
+#ifndef __HAIKU__
PyModule_AddIntConstant(m, "SOCK_SEQPACKET", SOCK_SEQPACKET);
+#endif
#if defined(SOCK_RDM)
PyModule_AddIntConstant(m, "SOCK_RDM", SOCK_RDM);
#endif
diff -ruN Python-2.7.1-orig/Modules/socketmodule.h Python-2.7.1/Modules/socketmodule.h
--- Python-2.7.1-orig/Modules/socketmodule.h 2010-05-09 10:46:46.042729472 -0400
+++ Python-2.7.1/Modules/socketmodule.h 2010-11-28 06:45:28.051118080 -0500
@@ -47,6 +47,10 @@
# undef AF_NETLINK
#endif
+#if defined(__HAIKU__)
+#undef HAVE_BLUETOOTH_BLUETOOTH_H
+#endif
+
#ifdef HAVE_BLUETOOTH_BLUETOOTH_H
#include <bluetooth/bluetooth.h>
#include <bluetooth/rfcomm.h>
diff -ruN Python-2.7.1-orig/Modules/spwdmodule.c Python-2.7.1/Modules/spwdmodule.c
--- Python-2.7.1-orig/Modules/spwdmodule.c 2010-05-09 10:46:46.061341696 -0400
+++ Python-2.7.1/Modules/spwdmodule.c 2010-11-28 06:45:28.053739520 -0500
@@ -79,7 +79,9 @@
SETS(setIndex++, p->sp_namp);
SETS(setIndex++, p->sp_pwdp);
+#ifndef __HAIKU__
SETI(setIndex++, p->sp_lstchg);
+#endif
SETI(setIndex++, p->sp_min);
SETI(setIndex++, p->sp_max);
SETI(setIndex++, p->sp_warn);
diff -ruN Python-2.7.1-orig/Modules/timemodule.c Python-2.7.1/Modules/timemodule.c
--- Python-2.7.1-orig/Modules/timemodule.c 2010-06-05 10:54:26.060030976 -0400
+++ Python-2.7.1/Modules/timemodule.c 2010-11-28 06:45:28.057147392 -0500
@@ -994,11 +994,11 @@
return -1;
}
Py_END_ALLOW_THREADS
-#elif defined(__BEOS__)
+#elif defined(__BEOS__) || defined(__HAIKU__)
/* This sleep *CAN BE* interrupted. */
{
if( secs <= 0.0 ) {
- return;
+ return 0;
}
Py_BEGIN_ALLOW_THREADS
diff -ruN Python-2.7.1-orig/Parser/asdl_c.py Python-2.7.1/Parser/asdl_c.py
--- Python-2.7.1-orig/Parser/asdl_c.py 2010-06-09 15:45:04.051118080 -0400
+++ Python-2.7.1/Parser/asdl_c.py 2010-11-28 06:45:28.060030976 -0500
@@ -1,4 +1,4 @@
-#! /usr/bin/env python
+#! /bin/env python
"""Generate C code from an ASDL description."""
# TO DO
diff -ruN Python-2.7.1-orig/Python/bltinmodule.c Python-2.7.1/Python/bltinmodule.c
--- Python-2.7.1-orig/Python/bltinmodule.c 2010-05-09 10:46:46.022020096 -0400
+++ Python-2.7.1/Python/bltinmodule.c 2010-11-29 05:45:30.041680896 -0500
@@ -19,7 +19,7 @@
*/
#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
const char *Py_FileSystemDefaultEncoding = "mbcs";
-#elif defined(__APPLE__)
+#elif defined(__APPLE__) || defined(__HAIKU__)
const char *Py_FileSystemDefaultEncoding = "utf-8";
#else
const char *Py_FileSystemDefaultEncoding = NULL; /* use default */
diff -ruN Python-2.7.1-orig/Tools/scripts/h2py.py Python-2.7.1/Tools/scripts/h2py.py
--- Python-2.7.1-orig/Tools/scripts/h2py.py 2010-11-26 03:10:41.041156608 -0500
+++ Python-2.7.1/Tools/scripts/h2py.py 2010-11-28 06:45:28.062128128 -0500
@@ -1,4 +1,4 @@
-#! /usr/bin/env python
+#! /bin/env python
# Read #define's and translate to Python code.
# Handle #include statements.
@@ -50,7 +50,7 @@
searchdirs=os.environ['INCLUDE'].split(';')
except KeyError:
try:
- if sys.platform.find("beos") == 0:
+ if sys.platform.find("beos") == 0 or sys.platform.find("haiku1") == 0:
searchdirs=os.environ['BEINCLUDES'].split(';')
elif sys.platform.startswith("atheos"):
searchdirs=os.environ['C_INCLUDE_PATH'].split(':')
diff -ruN Python-2.7.1-orig/configure.in Python-2.7.1/configure.in
--- Python-2.7.1-orig/configure.in 2010-10-31 21:47:19.049020928 -0400
+++ Python-2.7.1/configure.in 2010-11-28 06:45:28.067108864 -0500
@@ -12,7 +12,7 @@
[],
[m4_fatal([Autoconf version $1 is required for Python], 63)])
])
-version_required(2.65)
+#version_required(2.65)
AC_REVISION($Revision: 86076 $)
AC_INIT(python, PYTHON_VERSION, http://bugs.python.org/)
@@ -785,7 +785,7 @@
RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
INSTSONAME="$LDLIBRARY".$SOVERSION
;;
- Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
+ Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*|Haiku*)
LDLIBRARY='libpython$(VERSION).so'
BLDLIBRARY='-L. -lpython$(VERSION)'
RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
@@ -874,7 +874,7 @@
AC_SUBST(LN)
if test -z "$LN" ; then
case $ac_sys_system in
- BeOS*) LN="ln -s";;
+ BeOS*|Haiku*) LN="ln -s";;
CYGWIN*) LN="ln -s";;
atheos*) LN="ln -s";;
*) LN=ln;;
@@ -1844,7 +1844,7 @@
fi
fi
;;
- Linux*|GNU*|QNX*)
+ Linux*|GNU*|QNX*|Haiku*)
LDSHARED='$(CC) -shared'
LDCXXSHARED='$(CXX) -shared';;
BSD/OS*/4*)
@@ -1916,7 +1916,7 @@
then CCSHARED="-fPIC";
else CCSHARED="+z";
fi;;
- Linux*|GNU*) CCSHARED="-fPIC";;
+ Linux*|GNU*|Haiku*) CCSHARED="-fPIC";;
BSD/OS*/4*) CCSHARED="-fpic";;
FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
OpenUNIX*|UnixWare*)
@@ -1948,7 +1948,7 @@
LINKFORSHARED="-Wl,-E -Wl,+s";;
# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
- Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
+ Linux*|GNU*|Haiku*) LINKFORSHARED="-Xlinker -export-dynamic";;
# -u libsys_s pulls in all symbols in libsys
Darwin/*)
# -u _PyMac_Error is needed to pull in the mac toolbox glue,
@@ -2063,14 +2063,16 @@
esac
# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
-# BeOS' sockets are stashed in libnet.
AC_CHECK_LIB(nsl, t_open, [LIBS="-lnsl $LIBS"]) # SVR4
AC_CHECK_LIB(socket, socket, [LIBS="-lsocket $LIBS"], [], $LIBS) # SVR4 sockets
+# BeOS' sockets are stashed in libnet.
+# Haiku's sockets are stashed in libnetwork.
case "$ac_sys_system" in
-BeOS*)
-AC_CHECK_LIB(net, socket, [LIBS="-lnet $LIBS"], [], $LIBS) # BeOS
-;;
+ BeOS*)
+ AC_CHECK_LIB(net, socket, [LIBS="-lnet $LIBS"], [], $LIBS);;
+ Haiku*)
+ AC_CHECK_LIB(network, socket, [LIBS="-lnetwork $LIBS"], [], $LIBS);;
esac
AC_MSG_CHECKING(for --with-libs)
@@ -3371,7 +3373,7 @@
AC_SUBST(LIBM)
case $ac_sys_system in
Darwin) ;;
-BeOS) ;;
+BeOS|Haiku) ;;
*) LIBM=-lm
esac
AC_MSG_CHECKING(for --with-libm=STRING)
diff -ruN Python-2.7.1-orig/setup.py Python-2.7.1/setup.py
--- Python-2.7.1-orig/setup.py 2010-10-31 12:40:21.052166656 -0400
+++ Python-2.7.1/setup.py 2010-11-28 06:45:28.070516736 -0500
@@ -423,6 +423,11 @@
lib_dirs += os.getenv('LIBRARY_PATH', '').split(os.pathsep)
inc_dirs += ['/system/include', '/atheos/autolnk/include']
inc_dirs += os.getenv('C_INCLUDE_PATH', '').split(os.pathsep)
+
+ # Haiku-specific include and library locations
+ if platform == 'haiku1':
+ inc_dirs += ['/boot/develop/headers/posix', '/boot/develop/headers/3rdparty', '/boot/common/include']
+ lib_dirs += ['/boot/system/lib', '/boot/develop/lib/x86', '/boot/common/lib']
# OSF/1 and Unixware have some stuff in /usr/ccs/lib (like -ldb)
if platform in ['osf1', 'unixware7', 'openunix8']:
@@ -447,7 +452,7 @@
# Check for MacOS X, which doesn't need libm.a at all
math_libs = ['m']
- if platform in ['darwin', 'beos']:
+ if platform in ['darwin', 'beos', 'haiku1']:
math_libs = []
# XXX Omitted modules: gl, pure, dl, SGI-specific modules
@@ -1206,7 +1211,7 @@
missing.append('resource')
# Sun yellow pages. Some systems have the functions in libc.
- if (platform not in ['cygwin', 'atheos', 'qnx6'] and
+ if (platform not in ['cygwin', 'atheos', 'qnx6', 'haiku1'] and
find_file('rpcsvc/yp_prot.h', inc_dirs, []) is not None):
if (self.compiler.find_library_file(lib_dirs, 'nsl')):
libs = ['nsl']

View File

@@ -1,4 +1,4 @@
From f7d6b2b6f44a8f9337c9103d298222747d547ebf Mon Sep 17 00:00:00 2001
From c0a96d9df40b6b648dede4fd54ce52c6bef67e1e Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Wed, 12 Mar 2014 21:17:06 +0000
Subject: initial Haiku patch
@@ -79,7 +79,7 @@ index b9f1c6c..7be61d3 100644
# finalize_unix ()
diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
index 4aa9334..d06e5e8 100644
index de7da1d..8180c8e 100644
--- a/Lib/distutils/sysconfig.py
+++ b/Lib/distutils/sysconfig.py
@@ -90,7 +90,8 @@ def get_python_inc(plat_specific=0, prefix=None):
@@ -465,10 +465,10 @@ index 0000000..d9da80c
+set -v
+python $H2PY -i '(u_long)' $HEADERS/posix/netinet/in.h
diff --git a/Lib/test/test_fileio.py b/Lib/test/test_fileio.py
index b45d79b..d1f77f7 100644
index e21e47f..7baf562 100644
--- a/Lib/test/test_fileio.py
+++ b/Lib/test/test_fileio.py
@@ -299,6 +299,7 @@ class OtherFileTests(unittest.TestCase):
@@ -308,6 +308,7 @@ class OtherFileTests(unittest.TestCase):
self.assertEqual(f.writable(), True)
if sys.platform != "darwin" and \
'bsd' not in sys.platform and \
@@ -497,10 +497,10 @@ index 53a6c3e..6c5f52f 100644
if (PyErr_Occurred()) {
Py_DECREF(result);
diff --git a/Modules/socketmodule.c b/Modules/socketmodule.c
index 880f311..54b66f7 100644
index 5def531..5e3e5cc 100644
--- a/Modules/socketmodule.c
+++ b/Modules/socketmodule.c
@@ -4868,7 +4868,9 @@ init_socket(void)
@@ -4871,7 +4871,9 @@ init_socket(void)
#ifndef __BEOS__
/* We have incomplete socket support. */
PyModule_AddIntConstant(m, "SOCK_RAW", SOCK_RAW);
@@ -511,7 +511,7 @@ index 880f311..54b66f7 100644
PyModule_AddIntConstant(m, "SOCK_RDM", SOCK_RDM);
#endif
diff --git a/Modules/socketmodule.h b/Modules/socketmodule.h
index 8515499..4e33e4f 100644
index d98e00e..2bfb3dc 100644
--- a/Modules/socketmodule.h
+++ b/Modules/socketmodule.h
@@ -47,6 +47,10 @@ typedef int socklen_t;
@@ -571,7 +571,7 @@ index f052574..6a77f0d 100644
#else
const char *Py_FileSystemDefaultEncoding = NULL; /* use default */
diff --git a/Tools/scripts/h2py.py b/Tools/scripts/h2py.py
index c64501e..7df3ad7 100755
index 40b1bce..4185370 100755
--- a/Tools/scripts/h2py.py
+++ b/Tools/scripts/h2py.py
@@ -50,7 +50,7 @@ except KeyError:
@@ -584,10 +584,10 @@ index c64501e..7df3ad7 100755
elif sys.platform.startswith("atheos"):
searchdirs=os.environ['C_INCLUDE_PATH'].split(':')
diff --git a/configure.ac b/configure.ac
index 54f8c0f..1ea438a 100644
index 78fe3c7..09f4249 100644
--- a/configure.ac
+++ b/configure.ac
@@ -883,7 +883,7 @@ if test $enable_shared = "yes"; then
@@ -889,7 +889,7 @@ if test $enable_shared = "yes"; then
RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
INSTSONAME="$LDLIBRARY".$SOVERSION
;;
@@ -596,7 +596,7 @@ index 54f8c0f..1ea438a 100644
LDLIBRARY='libpython$(VERSION).so'
BLDLIBRARY='-L. -lpython$(VERSION)'
RUNSHARED=LD_LIBRARY_PATH=`pwd`${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}
@@ -891,6 +891,9 @@ if test $enable_shared = "yes"; then
@@ -897,6 +897,9 @@ if test $enable_shared = "yes"; then
FreeBSD*)
SOVERSION=`echo $SOVERSION|cut -d "." -f 1`
;;
@@ -606,7 +606,7 @@ index 54f8c0f..1ea438a 100644
esac
INSTSONAME="$LDLIBRARY".$SOVERSION
;;
@@ -1006,7 +1009,7 @@ AC_PROG_MKDIR_P
@@ -1012,7 +1015,7 @@ AC_PROG_MKDIR_P
AC_SUBST(LN)
if test -z "$LN" ; then
case $ac_sys_system in
@@ -615,7 +615,7 @@ index 54f8c0f..1ea438a 100644
CYGWIN*) LN="ln -s";;
atheos*) LN="ln -s";;
*) LN=ln;;
@@ -2030,7 +2033,7 @@ then
@@ -2036,7 +2039,7 @@ then
BLDSHARED="$LDSHARED"
fi
;;
@@ -624,7 +624,7 @@ index 54f8c0f..1ea438a 100644
LDSHARED='$(CC) -shared'
LDCXXSHARED='$(CXX) -shared';;
BSD/OS*/4*)
@@ -2102,7 +2105,7 @@ then
@@ -2108,7 +2111,7 @@ then
then CCSHARED="-fPIC";
else CCSHARED="+z";
fi;;
@@ -633,7 +633,7 @@ index 54f8c0f..1ea438a 100644
BSD/OS*/4*) CCSHARED="-fpic";;
FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
OpenUNIX*|UnixWare*)
@@ -2134,7 +2137,7 @@ then
@@ -2140,7 +2143,7 @@ then
LINKFORSHARED="-Wl,-E -Wl,+s";;
# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
@@ -642,7 +642,7 @@ index 54f8c0f..1ea438a 100644
# -u libsys_s pulls in all symbols in libsys
Darwin/*)
# -u _PyMac_Error is needed to pull in the mac toolbox glue,
@@ -2249,14 +2252,16 @@ case "$ac_sys_system" in
@@ -2258,14 +2261,16 @@ case "$ac_sys_system" in
esac
# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
@@ -663,7 +663,7 @@ index 54f8c0f..1ea438a 100644
esac
AC_MSG_CHECKING(for --with-libs)
@@ -3592,7 +3597,7 @@ fi],
@@ -3602,7 +3607,7 @@ fi],
AC_SUBST(LIBM)
case $ac_sys_system in
Darwin) ;;
@@ -673,10 +673,10 @@ index 54f8c0f..1ea438a 100644
esac
AC_MSG_CHECKING(for --with-libm=STRING)
diff --git a/setup.py b/setup.py
index a46bf35..9fe247f 100644
index 6a6ad23..6bc6782 100644
--- a/setup.py
+++ b/setup.py
@@ -523,6 +523,12 @@ class PyBuildExt(build_ext):
@@ -525,6 +525,12 @@ class PyBuildExt(build_ext):
lib_dirs += os.getenv('LIBRARY_PATH', '').split(os.pathsep)
inc_dirs += ['/system/include', '/atheos/autolnk/include']
inc_dirs += os.getenv('C_INCLUDE_PATH', '').split(os.pathsep)
@@ -689,7 +689,7 @@ index a46bf35..9fe247f 100644
# OSF/1 and Unixware have some stuff in /usr/ccs/lib (like -ldb)
if host_platform in ['osf1', 'unixware7', 'openunix8']:
@@ -551,7 +557,7 @@ class PyBuildExt(build_ext):
@@ -553,7 +559,7 @@ class PyBuildExt(build_ext):
# Check for MacOS X, which doesn't need libm.a at all
math_libs = ['m']
@@ -698,7 +698,7 @@ index a46bf35..9fe247f 100644
math_libs = []
# XXX Omitted modules: gl, pure, dl, SGI-specific modules
@@ -790,15 +796,22 @@ class PyBuildExt(build_ext):
@@ -792,15 +798,22 @@ class PyBuildExt(build_ext):
'/usr/local/ssl/include',
'/usr/contrib/ssl/include/'
]
@@ -724,7 +724,7 @@ index a46bf35..9fe247f 100644
['/usr/local/ssl/lib',
'/usr/contrib/ssl/lib/'
] )
@@ -806,8 +819,8 @@ class PyBuildExt(build_ext):
@@ -808,8 +821,8 @@ class PyBuildExt(build_ext):
if (ssl_incs is not None and
ssl_libs is not None):
exts.append( Extension('_ssl', ['_ssl.c'],
@@ -735,7 +735,7 @@ index a46bf35..9fe247f 100644
libraries = ['ssl', 'crypto'],
depends = ['socketmodule.h']), )
else:
@@ -845,8 +858,8 @@ class PyBuildExt(build_ext):
@@ -847,8 +860,8 @@ class PyBuildExt(build_ext):
# The _hashlib module wraps optimized implementations
# of hash functions from the OpenSSL library.
exts.append( Extension('_hashlib', ['_hashopenssl.c'],
@@ -746,7 +746,7 @@ index a46bf35..9fe247f 100644
libraries = ['ssl', 'crypto']) )
else:
print ("warning: openssl 0x%08x is too old for _hashlib" %
@@ -1325,7 +1338,7 @@ class PyBuildExt(build_ext):
@@ -1327,7 +1340,7 @@ class PyBuildExt(build_ext):
missing.append('resource')
# Sun yellow pages. Some systems have the functions in libc.
@@ -759,14 +759,14 @@ index a46bf35..9fe247f 100644
1.8.3.4
From 571ed69e1ab40fd11c4a1fdcb6198ff787c5129b Mon Sep 17 00:00:00 2001
From 8348c402f7f409e3024c78381c1d4e1f842ae448 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Sat, 5 Apr 2014 21:16:40 +0000
Subject: fix pyconfig.h path
diff --git a/Makefile.pre.in b/Makefile.pre.in
index bcd83bf..f93c10a 100644
index b3b2b36..77340fd 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -105,7 +105,7 @@ BINDIR= @bindir@
@@ -782,7 +782,7 @@ index bcd83bf..f93c10a 100644
1.8.3.4
From d49a8ee2494391b3a1c50bc652f0838ac036e046 Mon Sep 17 00:00:00 2001
From 2f77b7b4f848d6b85cffa3f31c5f1c0026b64e64 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Wed, 18 Jun 2014 12:19:13 +0000
Subject: Import missed change from the 2.6.9 patches
@@ -793,7 +793,7 @@ expected with
this version of Python.
diff --git a/Lib/site.py b/Lib/site.py
index d2e18f1..34d5aee 100644
index 4a09f3c..4b6e01e 100644
--- a/Lib/site.py
+++ b/Lib/site.py
@@ -287,6 +287,13 @@ def getsitepackages():
@@ -814,17 +814,17 @@ index d2e18f1..34d5aee 100644
1.8.3.4
From a0b72ccfc2f385c3ec9148523d981c7d971e2636 Mon Sep 17 00:00:00 2001
From ef5bdbe6e87e4b5ad6b541c65051f8f13e392676 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Sun, 21 Sep 2014 18:59:44 +0200
Subject: gcc2 fix.
diff --git a/Modules/_ctypes/libffi/include/ffi_common.h b/Modules/_ctypes/libffi/include/ffi_common.h
index 650ca69..02a1913 100644
index 37f5a9e..37b0b25 100644
--- a/Modules/_ctypes/libffi/include/ffi_common.h
+++ b/Modules/_ctypes/libffi/include/ffi_common.h
@@ -115,7 +115,7 @@ typedef signed int SINT64 __attribute__((__mode__(__DI__)));
@@ -119,7 +119,7 @@ typedef signed int SINT64 __attribute__((__mode__(__DI__)));
typedef float FLOAT32;
@@ -837,17 +837,17 @@ index 650ca69..02a1913 100644
1.8.3.4
From d50a28e47cbd54263d065f47b2650333d917c2b9 Mon Sep 17 00:00:00 2001
From 529eb791f594d7559a63b6088efea078fa012e7f Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Fri, 28 Nov 2014 16:26:28 +0000
Subject: tarfile: let link fail and catch exception.
diff --git a/Lib/tarfile.py b/Lib/tarfile.py
index 57ea877..bc3f82c 100644
index 082f361..4451189 100644
--- a/Lib/tarfile.py
+++ b/Lib/tarfile.py
@@ -2242,7 +2242,7 @@ class TarFile(object):
@@ -2263,7 +2263,7 @@ class TarFile(object):
(platform limitation), we try to make a copy of the referenced file
instead of a link.
"""
@@ -856,7 +856,7 @@ index 57ea877..bc3f82c 100644
# For systems that support symbolic and hard links.
if tarinfo.issym():
if os.path.lexists(targetpath):
@@ -2256,7 +2256,7 @@ class TarFile(object):
@@ -2277,7 +2277,7 @@ class TarFile(object):
os.link(tarinfo._link_target, targetpath)
else:
self._extract_member(self._find_link_target(tarinfo), targetpath)
@@ -868,3 +868,141 @@ index 57ea877..bc3f82c 100644
--
1.8.3.4
From 2f5996ce4a51079584b6d7b4d1dfba9e8e8fb018 Mon Sep 17 00:00:00 2001
From: Timothy Gu <timothygu99@gmail.com>
Date: Sun, 11 Jan 2015 18:18:22 -0800
Subject: Fix resource module after the initial haiku patch
diff --git a/Modules/resource.c b/Modules/resource.c
index 6c5f52f..73758bb 100644
--- a/Modules/resource.c
+++ b/Modules/resource.c
@@ -101,6 +101,21 @@ resource_getrusage(PyObject *self, PyObject *args)
PyStructSequence_SET_ITEM(result, 13, PyInt_FromLong(ru.ru_nsignals));
PyStructSequence_SET_ITEM(result, 14, PyInt_FromLong(ru.ru_nvcsw));
PyStructSequence_SET_ITEM(result, 15, PyInt_FromLong(ru.ru_nivcsw));
+#else
+ PyStructSequence_SET_ITEM(result, 2, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 3, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 4, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 5, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 6, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 7, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 8, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 9, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 10, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 11, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 12, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 13, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 14, PyInt_FromLong(0));
+ PyStructSequence_SET_ITEM(result, 15, PyInt_FromLong(0));
#endif
if (PyErr_Occurred()) {
--
1.8.3.4
From 57c574a0ce25088f026dffbb9abc06f7b7610a98 Mon Sep 17 00:00:00 2001
From: Timothy Gu <timothygu99@gmail.com>
Date: Sun, 11 Jan 2015 18:40:43 -0800
Subject: resource: Fix [gs]et_rlimit() modes detection
Haiku defines many of them, but they are actually empty stubs that will always
return EINVAL. No better way of doing this.
diff --git a/Modules/resource.c b/Modules/resource.c
index 73758bb..0c396f6 100644
--- a/Modules/resource.c
+++ b/Modules/resource.c
@@ -284,19 +284,19 @@ initresource(void)
(PyObject*) &StructRUsageType);
/* insert constants */
-#ifdef RLIMIT_CPU
+#if !defined(__HAIKU__) && defined(RLIMIT_CPU)
PyModule_AddIntConstant(m, "RLIMIT_CPU", RLIMIT_CPU);
#endif
-#ifdef RLIMIT_FSIZE
+#if !defined(__HAIKU__) && defined(RLIMIT_FSIZE)
PyModule_AddIntConstant(m, "RLIMIT_FSIZE", RLIMIT_FSIZE);
#endif
-#ifdef RLIMIT_DATA
+#if !defined(__HAIKU__) && defined(RLIMIT_DATA)
PyModule_AddIntConstant(m, "RLIMIT_DATA", RLIMIT_DATA);
#endif
-#ifdef RLIMIT_STACK
+#if !defined(__HAIKU__) && defined(RLIMIT_STACK)
PyModule_AddIntConstant(m, "RLIMIT_STACK", RLIMIT_STACK);
#endif
@@ -308,31 +308,31 @@ initresource(void)
PyModule_AddIntConstant(m, "RLIMIT_NOFILE", RLIMIT_NOFILE);
#endif
-#ifdef RLIMIT_OFILE
+#if !defined(__HAIKU__) && defined(RLIMIT_OFILE)
PyModule_AddIntConstant(m, "RLIMIT_OFILE", RLIMIT_OFILE);
#endif
-#ifdef RLIMIT_VMEM
+#if !defined(__HAIKU__) && defined(RLIMIT_VMEM)
PyModule_AddIntConstant(m, "RLIMIT_VMEM", RLIMIT_VMEM);
#endif
-#ifdef RLIMIT_AS
+#if !defined(__HAIKU__) && defined(RLIMIT_AS)
PyModule_AddIntConstant(m, "RLIMIT_AS", RLIMIT_AS);
#endif
-#ifdef RLIMIT_RSS
+#if !defined(__HAIKU__) && defined(RLIMIT_RSS)
PyModule_AddIntConstant(m, "RLIMIT_RSS", RLIMIT_RSS);
#endif
-#ifdef RLIMIT_NPROC
+#if !defined(__HAIKU__) && defined(RLIMIT_NPROC)
PyModule_AddIntConstant(m, "RLIMIT_NPROC", RLIMIT_NPROC);
#endif
-#ifdef RLIMIT_MEMLOCK
+#if !defined(__HAIKU__) && defined(RLIMIT_MEMLOCK)
PyModule_AddIntConstant(m, "RLIMIT_MEMLOCK", RLIMIT_MEMLOCK);
#endif
-#ifdef RLIMIT_SBSIZE
+#if !defined(__HAIKU__) && defined(RLIMIT_SBSIZE)
PyModule_AddIntConstant(m, "RLIMIT_SBSIZE", RLIMIT_SBSIZE);
#endif
--
1.8.3.4
From d9e84b7fdfc5a049e471f63ea49763785b574ee7 Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Tue, 26 May 2015 19:39:55 +0000
Subject: Haiku hasn't makedev(), _PyInt_FromDev isn't defined.
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index 4e86d32..ffe0db1 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -1483,6 +1483,8 @@ _pystat_fromstructstat(STRUCT_STAT *st)
#endif
#ifdef MS_WINDOWS
PyStructSequence_SET_ITEM(v, 2, PyLong_FromUnsignedLong(st->st_dev));
+#elif defined(__HAIKU__)
+ PyStructSequence_SET_ITEM(v, 2, PyInt_FromLong(st->st_dev));
#else
PyStructSequence_SET_ITEM(v, 2, _PyInt_FromDev(st->st_dev));
#endif
--
1.8.3.4

View File

@@ -12,7 +12,7 @@ HOMEPAGE="http://www.python.org"
LICENSE="Python"
COPYRIGHT="1990-2012, Python Software Foundation"
SOURCE_URI="https://www.python.org/ftp/python/$portVersion/Python-$portVersion.tar.xz"
CHECKSUM_SHA256="edde10a0cb7d14e2735e682882d5b287028d1485c456758154c19573db68075a"
CHECKSUM_SHA256="962b4c45af50124ea61f11a30deb4342fc0bc21126790fa1d7f6c79809413f46"
REVISION="1"
ARCHITECTURES="x86_gcc2 x86 x86_64"
@@ -58,12 +58,10 @@ BUILD_PREREQUIRES="
cmd:autoconf
cmd:find
cmd:gcc
cmd:grep
cmd:ld
cmd:libtoolize
cmd:make
cmd:pkg_config
cmd:sed
"
SOURCE_DIR="Python-$portVersion"

View File

@@ -12,7 +12,7 @@ HOMEPAGE="http://www.python.org"
LICENSE="Python"
COPYRIGHT="1990-2015, Python Software Foundation"
SOURCE_URI="https://www.python.org/ftp/python/$portVersion/Python-$portVersion.tar.xz"
CHECKSUM_SHA256="d6d7aa1634a5eeeca6ed4fca266982a04f84bd8f3945a9179e20b24ad2e2be91"
CHECKSUM_SHA256="c6d57c0c366d9060ab6c0cdf889ebf3d92711d466cc0119c441dbf2746f725c9"
REVISION="1"
ARCHITECTURES="x86_gcc2 x86 x86_64"