python: refresh patches

git-svn-id: svn://svn.openwrt.org/openwrt/packages@22968 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
mb
2010-09-07 11:16:04 +00:00
parent aa323f78f1
commit 469dd1b2a8
10 changed files with 114 additions and 97 deletions

View File

@ -1,16 +1,18 @@
Index: Python-2.5.1/Makefile.pre.in
===================================================================
--- Python-2.5.1.orig/Makefile.pre.in 2007-07-30 12:55:24.000000000 -0500
+++ Python-2.5.1/Makefile.pre.in 2007-07-30 12:55:24.000000000 -0500
@@ -175,6 +175,7 @@
---
Makefile.pre.in | 25 +++++++++++++------------
1 file changed, 13 insertions(+), 12 deletions(-)
--- Python-2.6.4.orig/Makefile.pre.in
+++ Python-2.6.4/Makefile.pre.in
@@ -175,6 +175,7 @@ UNICODE_OBJS= @UNICODE_OBJS@
PYTHON= python$(EXE)
BUILDPYTHON= python$(BUILDEXE)
+HOSTPYTHON= $(BUILDPYTHON)
# === Definitions added by makesetup ===
@@ -205,7 +206,7 @@
# The task to run while instrument when building the profile-opt target
PROFILE_TASK= $(srcdir)/Tools/pybench/pybench.py -n 2 --with-gc --with-syscheck
@@ -205,7 +206,7 @@ GRAMMAR_INPUT= $(srcdir)/Grammar/Grammar
##########################################################################
# Parser
PGEN= Parser/pgen$(EXE)
@ -19,41 +21,7 @@ Index: Python-2.5.1/Makefile.pre.in
POBJS= \
Parser/acceler.o \
Parser/grammar1.o \
@@ -394,8 +395,8 @@
# Build the shared modules
sharedmods: $(BUILDPYTHON)
@case $$MAKEFLAGS in \
- *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \
- *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
+ *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py -q build;; \
+ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py build;; \
esac
# Build static library
@@ -512,8 +513,8 @@
$(GRAMMAR_H) $(GRAMMAR_C): $(PGEN) $(GRAMMAR_INPUT)
-@$(INSTALL) -d Include
- -$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
+ -$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
$(PGEN): $(PGENOBJS)
$(CC) $(OPT) $(LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
@@ -993,7 +994,7 @@
# Install the dynamically loadable modules
# This goes into $(exec_prefix)
sharedinstall:
- $(RUNSHARED) ./$(BUILDPYTHON) -E $(srcdir)/setup.py install \
+ $(RUNSHARED) $(HOSTPYTHON) -E $(srcdir)/setup.py install \
--prefix=$(prefix) \
--install-scripts=$(BINDIR) \
--install-platlib=$(DESTSHARED) \
diff --git a/Makefile.pre.in b/Makefile.pre.in
index c2ce5c6..63dc91e 100644
--- a/Makefile.pre.in
+++ b/Makefile.pre.in
@@ -371,7 +371,7 @@ build_all_generate_profile:
@@ -370,7 +371,7 @@ build_all_generate_profile:
$(MAKE) all CFLAGS="$(CFLAGS) -fprofile-generate" LIBS="$(LIBS) -lgcov"
run_profile_task:
@ -62,7 +30,7 @@ index c2ce5c6..63dc91e 100644
build_all_use_profile:
$(MAKE) all CFLAGS="$(CFLAGS) -fprofile-use"
@@ -389,7 +389,7 @@ $(BUILDPYTHON): Modules/python.o $(LIBRARY) $(LDLIBRARY)
@@ -388,14 +389,14 @@ $(BUILDPYTHON): Modules/python.o $(LIBRA
$(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
platform: $(BUILDPYTHON)
@ -71,7 +39,25 @@ index c2ce5c6..63dc91e 100644
# Build the shared modules
@@ -669,7 +669,7 @@ $(LIBRARY_OBJS) $(MODOBJS) Modules/python.o: $(PYTHON_HEADERS)
sharedmods: $(BUILDPYTHON)
@case $$MAKEFLAGS in \
- *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py -q build;; \
- *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' ./$(BUILDPYTHON) -E $(srcdir)/setup.py build;; \
+ *s*) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py -q build;; \
+ *) $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' $(HOSTPYTHON) -E $(srcdir)/setup.py build;; \
esac
# Build static library
@@ -517,7 +518,7 @@ Modules/python.o: $(srcdir)/Modules/pyth
$(GRAMMAR_H) $(GRAMMAR_C): $(PGEN) $(GRAMMAR_INPUT)
-@$(INSTALL) -d Include
- -$(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
+ -$(HOSTPGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
$(PGEN): $(PGENOBJS)
$(CC) $(OPT) $(LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
@@ -676,7 +677,7 @@ $(LIBRARY_OBJS) $(MODOBJS) Modules/pytho
TESTOPTS= -l $(EXTRATESTOPTS)
TESTPROG= $(srcdir)/Lib/test/regrtest.py
@ -79,8 +65,17 @@ index c2ce5c6..63dc91e 100644
+TESTPYTHON= $(RUNSHARED) $(HOSTPYTHON) -E -tt
test: all platform
-find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f
@@ -1032,7 +1014,7 @@ frameworkinstallstructure: $(LDLIBRARY)
-$(TESTPYTHON) $(TESTPROG) $(TESTOPTS)
@@ -1001,7 +1002,7 @@ libainstall: all
# Install the dynamically loadable modules
# This goes into $(exec_prefix)
sharedinstall:
- $(RUNSHARED) ./$(BUILDPYTHON) -E $(srcdir)/setup.py install \
+ $(RUNSHARED) $(HOSTPYTHON) -E $(srcdir)/setup.py install \
--prefix=$(prefix) \
--install-scripts=$(BINDIR) \
--install-platlib=$(DESTSHARED) \
@@ -1039,7 +1040,7 @@ frameworkinstallstructure: $(LDLIBRARY)
fi; \
done
$(LN) -fsn include/python$(VERSION) $(DESTDIR)$(prefix)/Headers
@ -89,7 +84,7 @@ index c2ce5c6..63dc91e 100644
$(LN) -fsn $(VERSION) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Versions/Current
$(LN) -fsn Versions/Current/$(PYTHONFRAMEWORK) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/$(PYTHONFRAMEWORK)
$(LN) -fsn Versions/Current/Headers $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Headers
@@ -1074,7 +1056,7 @@ frameworkinstallextras:
@@ -1081,7 +1082,7 @@ frameworkinstallextras:
# This installs a few of the useful scripts in Tools/scripts
scriptsinstall:
SRCDIR=$(srcdir) $(RUNSHARED) \
@ -98,7 +93,7 @@ index c2ce5c6..63dc91e 100644
--prefix=$(prefix) \
--install-scripts=$(BINDIR) \
--root=/$(DESTDIR)
@@ -1096,7 +1078,7 @@ config.status: $(srcdir)/configure
@@ -1103,7 +1104,7 @@ config.status: $(srcdir)/configure
# Run reindent on the library
reindent:
@ -107,7 +102,7 @@ index c2ce5c6..63dc91e 100644
# Rerun configure with the same options as it was run last time,
# provided the config.status script exists
@@ -1192,7 +1174,7 @@ funny:
@@ -1200,7 +1201,7 @@ funny:
# Perform some verification checks on any modified files.
patchcheck: