summaryrefslogtreecommitdiffstats
path: root/meta-extras/packages/python/python-2.5.1
diff options
context:
space:
mode:
Diffstat (limited to 'meta-extras/packages/python/python-2.5.1')
-rw-r--r--meta-extras/packages/python/python-2.5.1/autohell.patch49
-rw-r--r--meta-extras/packages/python/python-2.5.1/bindir-libdir.patch20
-rw-r--r--meta-extras/packages/python/python-2.5.1/crosscompile.patch110
-rw-r--r--meta-extras/packages/python/python-2.5.1/default-is-optimized.patch13
-rw-r--r--meta-extras/packages/python/python-2.5.1/fix-tkinter-detection.patch41
-rw-r--r--meta-extras/packages/python/python-2.5.1/sitebranding.patch21
6 files changed, 254 insertions, 0 deletions
diff --git a/meta-extras/packages/python/python-2.5.1/autohell.patch b/meta-extras/packages/python/python-2.5.1/autohell.patch
new file mode 100644
index 0000000000..e2d63145be
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/autohell.patch
@@ -0,0 +1,49 @@
1#
2# FIXME: Don't simply rip this test out... add getting it from cache
3#
4Index: Python-2.5.1/configure.in
5===================================================================
6--- Python-2.5.1.orig/configure.in
7+++ Python-2.5.1/configure.in
8@@ -3367,41 +3367,6 @@ else
9 AC_MSG_RESULT(no)
10 fi
11
12-AC_MSG_CHECKING(for %zd printf() format support)
13-AC_TRY_RUN([#include <stdio.h>
14-#include <stddef.h>
15-#include <string.h>
16-
17-int main()
18-{
19- char buffer[256];
20-
21-#ifdef HAVE_SSIZE_T
22-typedef ssize_t Py_ssize_t;
23-#elif SIZEOF_VOID_P == SIZEOF_LONG
24-typedef long Py_ssize_t;
25-#else
26-typedef int Py_ssize_t;
27-#endif
28-
29- if(sprintf(buffer, "%zd", (size_t)123) < 0)
30- return 1;
31-
32- if (strcmp(buffer, "123"))
33- return 1;
34-
35- if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
36- return 1;
37-
38- if (strcmp(buffer, "-123"))
39- return 1;
40-
41- return 0;
42-}],
43-[AC_MSG_RESULT(yes)
44- AC_DEFINE(PY_FORMAT_SIZE_T, "z", [Define to printf format modifier for Py_ssize_t])],
45- AC_MSG_RESULT(no))
46-
47 AC_CHECK_TYPE(socklen_t,,
48 AC_DEFINE(socklen_t,int,
49 Define to `int' if <sys/socket.h> does not define.),[
diff --git a/meta-extras/packages/python/python-2.5.1/bindir-libdir.patch b/meta-extras/packages/python/python-2.5.1/bindir-libdir.patch
new file mode 100644
index 0000000000..047c358a55
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/bindir-libdir.patch
@@ -0,0 +1,20 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6Index: Python-2.5.1/Makefile.pre.in
7===================================================================
8--- Python-2.5.1.orig/Makefile.pre.in
9+++ Python-2.5.1/Makefile.pre.in
10@@ -83,8 +83,8 @@ prefix= @prefix@
11 exec_prefix= @exec_prefix@
12
13 # Expanded directories
14-BINDIR= $(exec_prefix)/bin
15-LIBDIR= $(exec_prefix)/lib
16+BINDIR= @bindir@
17+LIBDIR= @libdir@
18 MANDIR= @mandir@
19 INCLUDEDIR= @includedir@
20 CONFINCLUDEDIR= $(exec_prefix)/include
diff --git a/meta-extras/packages/python/python-2.5.1/crosscompile.patch b/meta-extras/packages/python/python-2.5.1/crosscompile.patch
new file mode 100644
index 0000000000..f456048ef5
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/crosscompile.patch
@@ -0,0 +1,110 @@
1#
2# Patch (C) by Michael 'Mickey' Lauer <mlauer@vanille-media.de>
3#
4Index: Python-2.5.1/Makefile.pre.in
5===================================================================
6--- Python-2.5.1.orig/Makefile.pre.in
7+++ Python-2.5.1/Makefile.pre.in
8@@ -170,6 +170,7 @@ UNICODE_OBJS= @UNICODE_OBJS@
9
10 PYTHON= python$(EXE)
11 BUILDPYTHON= python$(BUILDEXE)
12+HOSTPYTHON= $(BUILDPYTHON)
13
14 # === Definitions added by makesetup ===
15
16@@ -196,7 +197,7 @@ GRAMMAR_INPUT= $(srcdir)/Grammar/Grammar
17 ##########################################################################
18 # Parser
19 PGEN= Parser/pgen$(EXE)
20-
21+HOSTPGEN= $(PGEN)$(EXE)
22 POBJS= \
23 Parser/acceler.o \
24 Parser/grammar1.o \
25@@ -345,8 +346,8 @@ platform: $(BUILDPYTHON)
26 # Build the shared modules
27 sharedmods: $(BUILDPYTHON)
28 case $$MAKEFLAGS in \
29- *-s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \
30- *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
31+ *-s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py -q build;; \
32+ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py build;; \
33 esac
34
35 # Build static library
36@@ -470,7 +471,7 @@ Modules/python.o: $(srcdir)/Modules/pyth
37
38
39 $(GRAMMAR_H) $(GRAMMAR_C): $(PGEN) $(GRAMMAR_INPUT)
40- -$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
41+ -$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
42
43 $(PGEN): $(PGENOBJS)
44 $(CC) $(OPT) $(LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
45@@ -773,19 +774,19 @@ libinstall: $(BUILDPYTHON) $(srcdir)/Lib
46 done
47 $(INSTALL_DATA) $(srcdir)/LICENSE $(DESTDIR)$(LIBDEST)/LICENSE.txt
48 PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
49- ./$(BUILDPYTHON) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \
50+ $(HOSTPYTHON) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \
51 -d $(LIBDEST) -f \
52 -x 'bad_coding|badsyntax|site-packages' $(DESTDIR)$(LIBDEST)
53 PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
54- ./$(BUILDPYTHON) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \
55+ $(HOSTPYTHON) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \
56 -d $(LIBDEST) -f \
57 -x 'bad_coding|badsyntax|site-packages' $(DESTDIR)$(LIBDEST)
58 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
59- ./$(BUILDPYTHON) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \
60+ $(HOSTPYTHON) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \
61 -d $(LIBDEST)/site-packages -f \
62 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
63 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
64- ./$(BUILDPYTHON) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \
65+ $(HOSTPYTHON) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \
66 -d $(LIBDEST)/site-packages -f \
67 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
68
69@@ -885,7 +886,7 @@ libainstall: all
70 # Install the dynamically loadable modules
71 # This goes into $(exec_prefix)
72 sharedinstall:
73- $(RUNSHARED) ./$(BUILDPYTHON) -E $(srcdir)/setup.py install \
74+ $(RUNSHARED) $(HOSTPYTHON) -E $(srcdir)/setup.py install \
75 --prefix=$(prefix) \
76 --install-scripts=$(BINDIR) \
77 --install-platlib=$(DESTSHARED) \
78Index: Python-2.5.1/setup.py
79===================================================================
80--- Python-2.5.1.orig/setup.py
81+++ Python-2.5.1/setup.py
82@@ -211,6 +211,7 @@ class PyBuildExt(build_ext):
83 except ImportError, why:
84 self.announce('*** WARNING: renaming "%s" since importing it'
85 ' failed: %s' % (ext.name, why), level=3)
86+ return
87 assert not self.inplace
88 basename, tail = os.path.splitext(ext_filename)
89 newname = basename + "_failed" + tail
90@@ -244,8 +245,8 @@ class PyBuildExt(build_ext):
91
92 def detect_modules(self):
93 # Ensure that /usr/local is always used
94- add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
95- add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
96+ # add_dir_to_list(self.compiler.library_dirs, '/usr/local/lib')
97+ # add_dir_to_list(self.compiler.include_dirs, '/usr/local/include')
98
99 # Add paths specified in the environment variables LDFLAGS and
100 # CPPFLAGS for header and library files.
101@@ -341,6 +342,9 @@ class PyBuildExt(build_ext):
102
103 # XXX Omitted modules: gl, pure, dl, SGI-specific modules
104
105+ lib_dirs = [ os.getenv( "STAGING_LIBDIR" ) ]
106+ inc_dirs = [ os.getenv( "STAGING_INCDIR" ) ]
107+
108 #
109 # The following modules are all pretty straightforward, and compile
110 # on pretty much any POSIXish platform.
diff --git a/meta-extras/packages/python/python-2.5.1/default-is-optimized.patch b/meta-extras/packages/python/python-2.5.1/default-is-optimized.patch
new file mode 100644
index 0000000000..6beeb6e022
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/default-is-optimized.patch
@@ -0,0 +1,13 @@
1Index: Python-2.5.1/Python/compile.c
2===================================================================
3--- Python-2.5.1.orig/Python/compile.c
4+++ Python-2.5.1/Python/compile.c
5@@ -30,7 +30,7 @@
6 #include "symtable.h"
7 #include "opcode.h"
8
9-int Py_OptimizeFlag = 0;
10+int Py_OptimizeFlag = 1;
11
12 /*
13 ISSUES:
diff --git a/meta-extras/packages/python/python-2.5.1/fix-tkinter-detection.patch b/meta-extras/packages/python/python-2.5.1/fix-tkinter-detection.patch
new file mode 100644
index 0000000000..93bd343381
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/fix-tkinter-detection.patch
@@ -0,0 +1,41 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6Index: Python-2.5.1/setup.py
7===================================================================
8--- Python-2.5.1.orig/setup.py
9+++ Python-2.5.1/setup.py
10@@ -1227,7 +1227,7 @@ class PyBuildExt(build_ext):
11 dotversion = dotversion[:-1] + '.' + dotversion[-1]
12 tcl_include_sub = []
13 tk_include_sub = []
14- for dir in inc_dirs:
15+ for dir in [os.getenv("STAGING_INCDIR")]:
16 tcl_include_sub += [dir + os.sep + "tcl" + dotversion]
17 tk_include_sub += [dir + os.sep + "tk" + dotversion]
18 tk_include_sub += tcl_include_sub
19@@ -1246,22 +1246,6 @@ class PyBuildExt(build_ext):
20 if dir not in include_dirs:
21 include_dirs.append(dir)
22
23- # Check for various platform-specific directories
24- if platform == 'sunos5':
25- include_dirs.append('/usr/openwin/include')
26- added_lib_dirs.append('/usr/openwin/lib')
27- elif os.path.exists('/usr/X11R6/include'):
28- include_dirs.append('/usr/X11R6/include')
29- added_lib_dirs.append('/usr/X11R6/lib64')
30- added_lib_dirs.append('/usr/X11R6/lib')
31- elif os.path.exists('/usr/X11R5/include'):
32- include_dirs.append('/usr/X11R5/include')
33- added_lib_dirs.append('/usr/X11R5/lib')
34- else:
35- # Assume default location for X11
36- include_dirs.append('/usr/X11/include')
37- added_lib_dirs.append('/usr/X11/lib')
38-
39 # If Cygwin, then verify that X is installed before proceeding
40 if platform == 'cygwin':
41 x11_inc = find_file('X11/Xlib.h', [], include_dirs)
diff --git a/meta-extras/packages/python/python-2.5.1/sitebranding.patch b/meta-extras/packages/python/python-2.5.1/sitebranding.patch
new file mode 100644
index 0000000000..c6e486ae97
--- /dev/null
+++ b/meta-extras/packages/python/python-2.5.1/sitebranding.patch
@@ -0,0 +1,21 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6Index: Python-2.5.1/Lib/site.py
7===================================================================
8--- Python-2.5.1.orig/Lib/site.py
9+++ Python-2.5.1/Lib/site.py
10@@ -323,8 +323,9 @@ def setcopyright():
11 "Jython is maintained by the Jython developers (www.jython.org).")
12 else:
13 __builtin__.credits = _Printer("credits", """\
14- Thanks to CWI, CNRI, BeOpen.com, Zope Corporation and a cast of thousands
15- for supporting Python development. See www.python.org for more information.""")
16+ This version of Python has been built by the OpenEmbedded buildsystem (http://openembedded.org).
17+ It is a part of the Python-For-Embedded-Systems initiative which is maintained by
18+ Michael 'Mickey' Lauer (http://www.Vanille.de/projects/python.spy).""")
19 here = os.path.dirname(os.__file__)
20 __builtin__.license = _Printer(
21 "license", "See http://www.python.org/%.3s/license.html" % sys.version,