summaryrefslogtreecommitdiff
path: root/lang/python32/files
diff options
context:
space:
mode:
Diffstat (limited to 'lang/python32/files')
-rw-r--r--lang/python32/files/patch-Lib-test-test_socket.py11
-rw-r--r--lang/python32/files/patch-Modules-fcntlmodule.c88
-rw-r--r--lang/python32/files/patch-setup.py71
3 files changed, 79 insertions, 91 deletions
diff --git a/lang/python32/files/patch-Lib-test-test_socket.py b/lang/python32/files/patch-Lib-test-test_socket.py
deleted file mode 100644
index 4895d7bc5fc8..000000000000
--- a/lang/python32/files/patch-Lib-test-test_socket.py
+++ /dev/null
@@ -1,11 +0,0 @@
---- Lib/test/test_socket.py.orig 2009-10-04 10:54:52.000000000 -0400
-+++ Lib/test/test_socket.py 2010-06-24 13:57:37.000000000 -0400
-@@ -337,7 +337,7 @@
- # I've ordered this by protocols that have both a tcp and udp
- # protocol, at least for modern Linuxes.
- if sys.platform in ('linux2', 'freebsd4', 'freebsd5', 'freebsd6',
-- 'freebsd7', 'freebsd8', 'darwin'):
-+ 'freebsd7', 'freebsd8', 'freebsd9', 'darwin'):
- # avoid the 'echo' service on this platform, as there is an
- # assumption breaking non-standard port/protocol entry
- services = ('daytime', 'qotd', 'domain')
diff --git a/lang/python32/files/patch-Modules-fcntlmodule.c b/lang/python32/files/patch-Modules-fcntlmodule.c
index 3803ad427fbe..6f9f3ab01d0a 100644
--- a/lang/python32/files/patch-Modules-fcntlmodule.c
+++ b/lang/python32/files/patch-Modules-fcntlmodule.c
@@ -1,53 +1,53 @@
---- Modules/fcntlmodule.c.orig 2009-05-24 11:46:13.000000000 -0400
-+++ Modules/fcntlmodule.c 2010-06-24 22:30:32.000000000 -0400
+--- Modules/fcntlmodule.c.orig 2010-12-14 09:44:03.000000000 +0800
++++ Modules/fcntlmodule.c 2010-12-14 09:47:17.000000000 +0800
@@ -97,20 +97,15 @@
{
#define IOCTL_BUFSZ 1024
- int fd;
-- /* In PyArg_ParseTuple below, we use the unsigned non-checked 'I'
-+ /* In PyArg_ParseTuple below, we use the unsigned non-checked 'k'
- format for the 'code' parameter because Python turns 0x8000000
- into either a large positive number (PyLong or PyInt on 64-bit
- platforms) or a negative number on others (32-bit PyInt)
- whereas the system expects it to be a 32bit bit field value
- regardless of it being passed as an int or unsigned long on
-- various platforms. See the termios.TIOCSWINSZ constant across
-- platforms for an example of thise.
+ int fd;
+- /* In PyArg_ParseTuple below, we use the unsigned non-checked 'I'
++ /* In PyArg_ParseTuple below, we use the unsigned non-checked 'k'
+ format for the 'code' parameter because Python turns 0x8000000
+ into either a large positive number (PyLong or PyInt on 64-bit
+ platforms) or a negative number on others (32-bit PyInt)
+ whereas the system expects it to be a 32bit bit field value
+ regardless of it being passed as an int or unsigned long on
+- various platforms. See the termios.TIOCSWINSZ constant across
+- platforms for an example of thise.
-
-- If any of the 64bit platforms ever decide to use more than 32bits
-- in their unsigned long ioctl codes this will break and need
-- special casing based on the platform being built on.
-+ various platforms.
- */
-- unsigned int code;
-+ unsigned long code;
- int arg;
- int ret;
- Py_buffer pstr;
+- If any of the 64bit platforms ever decide to use more than 32bits
+- in their unsigned long ioctl codes this will break and need
+- special casing based on the platform being built on.
++ various platforms.
+ */
+- unsigned int code;
++ unsigned long code;
+ int arg;
+ int ret;
+ Py_buffer pstr;
@@ -119,7 +114,7 @@
- int mutate_arg = 1;
- char buf[IOCTL_BUFSZ+1]; /* argument plus NUL byte */
+ int mutate_arg = 1;
+ char buf[IOCTL_BUFSZ+1]; /* argument plus NUL byte */
-- if (PyArg_ParseTuple(args, "O&Iw*|i:ioctl",
-+ if (PyArg_ParseTuple(args, "O&kw*|i:ioctl",
- conv_descriptor, &fd, &code,
- &pstr, &mutate_arg)) {
- char *arg;
+- if (PyArg_ParseTuple(args, "O&Iw*|i:ioctl",
++ if (PyArg_ParseTuple(args, "O&kw*|i:ioctl",
+ conv_descriptor, &fd, &code,
+ &pstr, &mutate_arg)) {
+ char *arg;
@@ -174,7 +169,7 @@
- }
+ }
- PyErr_Clear();
-- if (PyArg_ParseTuple(args, "O&Is*:ioctl",
-+ if (PyArg_ParseTuple(args, "O&ks*:ioctl",
- conv_descriptor, &fd, &code, &pstr)) {
- str = pstr.buf;
- len = pstr.len;
+ PyErr_Clear();
+- if (PyArg_ParseTuple(args, "O&Is*:ioctl",
++ if (PyArg_ParseTuple(args, "O&ks*:ioctl",
+ conv_descriptor, &fd, &code, &pstr)) {
+ str = pstr.buf;
+ len = pstr.len;
@@ -201,7 +196,7 @@
- PyErr_Clear();
- arg = 0;
- if (!PyArg_ParseTuple(args,
-- "O&I|i;ioctl requires a file or file descriptor,"
-+ "O&k|i;ioctl requires a file or file descriptor,"
- " an integer and optionally an integer or buffer argument",
- conv_descriptor, &fd, &code, &arg)) {
- return NULL;
+ PyErr_Clear();
+ arg = 0;
+ if (!PyArg_ParseTuple(args,
+- "O&I|i;ioctl requires a file or file descriptor,"
++ "O&k|i;ioctl requires a file or file descriptor,"
+ " an integer and optionally an integer or buffer argument",
+ conv_descriptor, &fd, &code, &arg)) {
+ return NULL;
diff --git a/lang/python32/files/patch-setup.py b/lang/python32/files/patch-setup.py
index 5f78c13849a4..ee5430f79091 100644
--- a/lang/python32/files/patch-setup.py
+++ b/lang/python32/files/patch-setup.py
@@ -1,7 +1,7 @@
---- setup.py.orig 2009-08-12 20:39:44.000000000 +0200
-+++ setup.py 2009-11-26 12:58:45.000000000 +0100
-@@ -16,7 +16,7 @@
- from distutils.command.install_lib import install_lib
+--- setup.py.orig 2010-11-26 19:56:26.000000000 +0800
++++ setup.py 2010-12-14 10:53:36.000000000 +0800
+@@ -17,7 +17,7 @@
+ from distutils.spawn import find_executable
# This global variable is used to hold the list of modules to be disabled.
-disabled_module_list = []
@@ -9,16 +9,16 @@
def add_dir_to_list(dirlist, dir):
"""Add the directory 'dir' to the list 'dirlist' (at the front) if
-@@ -514,7 +514,7 @@
-
- readline_libs = ['readline']
- if self.compiler.find_library_file(lib_dirs,
-- 'ncursesw'):
-+ 'XXXncursesw'):
- readline_libs.append('ncursesw')
- elif self.compiler.find_library_file(lib_dirs,
- 'ncurses'):
-@@ -526,7 +526,7 @@
+@@ -578,7 +578,7 @@
+ # curses_library = readline_termcap_library
+ # elif self.compiler.find_library_file(lib_dirs, 'ncursesw'):
+ # (...)
+- if self.compiler.find_library_file(lib_dirs, 'ncursesw'):
++ if self.compiler.find_library_file(lib_dirs, 'XXXncursesw'):
+ curses_library = 'ncursesw'
+ elif self.compiler.find_library_file(lib_dirs, 'ncurses'):
+ curses_library = 'ncurses'
+@@ -614,7 +614,7 @@
'termcap'):
readline_libs.append('termcap')
exts.append( Extension('readline', ['readline.c'],
@@ -27,7 +27,7 @@
extra_link_args=readline_extra_link_args,
libraries=readline_libs) )
else:
-@@ -619,6 +619,8 @@
+@@ -708,6 +708,8 @@
# OpenSSL doesn't do these until 0.9.8 so we'll bring our own hash
exts.append( Extension('_sha256', ['sha256module.c']) )
exts.append( Extension('_sha512', ['sha512module.c']) )
@@ -36,50 +36,49 @@
if openssl_ver < 0x00907000:
# no openssl at all, use our own md5 and sha1
-@@ -994,7 +996,7 @@
- # Curses support, requiring the System V version of curses, often
+@@ -1116,12 +1118,13 @@
# provided by the ncurses library.
panel_library = 'panel'
-- if (self.compiler.find_library_file(lib_dirs, 'ncursesw')):
-+ if (self.compiler.find_library_file(lib_dirs, 'XXXncursesw')):
- curses_libs = ['ncursesw']
- # Bug 1464056: If _curses.so links with ncursesw,
- # _curses_panel.so must link with panelw.
-@@ -1004,6 +1006,7 @@
- elif (self.compiler.find_library_file(lib_dirs, 'ncurses')):
- curses_libs = ['ncurses']
+ if curses_library.startswith('ncurses'):
+- if curses_library == 'ncursesw':
++ if curses_library == 'XXXncursesw':
+ # Bug 1464056: If _curses.so links with ncursesw,
+ # _curses_panel.so must link with panelw.
+ panel_library = 'panelw'
+ curses_libs = [curses_library]
exts.append( Extension('_curses', ['_cursesmodule.c'],
-+ library_dirs = ['/usr/lib'],
++ library_dirs = ['/usr/lib'],
libraries = curses_libs) )
- elif (self.compiler.find_library_file(lib_dirs, 'curses')
- and platform != 'darwin'):
-@@ -1025,6 +1028,7 @@
+ elif curses_library == 'curses' and platform != 'darwin':
+ # OSX has an old Berkeley curses, not good enough for
+@@ -1142,6 +1145,7 @@
if (module_enabled(exts, '_curses') and
self.compiler.find_library_file(lib_dirs, panel_library)):
exts.append( Extension('_curses_panel', ['_curses_panel.c'],
-+ library_dirs = ['/usr/lib'],
++ library_dirs = ['/usr/lib'],
libraries = [panel_library] + curses_libs) )
else:
missing.append('_curses_panel')
-@@ -1161,7 +1165,7 @@
+@@ -1278,7 +1282,7 @@
macros = dict()
libraries = []
- elif platform in ('freebsd4', 'freebsd5', 'freebsd6', 'freebsd7', 'freebsd8'):
-+ elif platform in ('freebsd4', 'freebsd5', 'freebsd6', 'freebsd7', 'freebsd8', 'freebsd9'):
++ elif platform in ('freebsd6', 'freebsd7', 'freebsd8', 'freebsd9'):
# FreeBSD's P1003.1b semaphore support is very experimental
# and has many known problems. (as of June 2008)
macros = dict()
-@@ -1204,7 +1208,7 @@
+@@ -1321,8 +1325,7 @@
+ # End multiprocessing
# Platform-specific libraries
- if platform in ('linux2', 'freebsd4', 'freebsd5', 'freebsd6',
+- if platform in ('linux2', 'freebsd4', 'freebsd5', 'freebsd6',
- 'freebsd7', 'freebsd8'):
-+ 'freebsd7', 'freebsd8', 'freebsd9'):
++ if platform in ('linux2', 'freebsd6', 'freebsd7', 'freebsd8', 'freebsd9'):
exts.append( Extension('ossaudiodev', ['ossaudiodev.c']) )
else:
missing.append('ossaudiodev')
-@@ -1665,8 +1669,7 @@
+@@ -1808,8 +1811,7 @@
# called unless there's at least one extension module defined.
ext_modules=[Extension('_struct', ['_struct.c'])],