diff options
Diffstat (limited to 'data/python/starpython.diff')
-rw-r--r-- | data/python/starpython.diff | 152 |
1 files changed, 152 insertions, 0 deletions
diff --git a/data/python/starpython.diff b/data/python/starpython.diff new file mode 100644 index 000000000..8750b00e7 --- /dev/null +++ b/data/python/starpython.diff @@ -0,0 +1,152 @@ +Only in Python-2.7.15+iPhone/Lib: _scproxy.py +diff -ur Python-2.7.15/Makefile.pre.in Python-2.7.15+iPhone/Makefile.pre.in +--- Python-2.7.15/Makefile.pre.in 2018-04-29 12:47:33.000000000 -1000 ++++ Python-2.7.15+iPhone/Makefile.pre.in 2018-09-04 18:39:57.000000000 -1000 +@@ -1131,28 +1131,30 @@ + $(INSTALL_DATA) $(srcdir)/Modules/xxmodule.c \ + $(DESTDIR)$(LIBDEST)/distutils/tests ; \ + fi +- PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \ +- -d $(LIBDEST) -f \ +- -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ +- $(DESTDIR)$(LIBDEST) +- PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \ +- -d $(LIBDEST) -f \ +- -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ +- $(DESTDIR)$(LIBDEST) +- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \ +- -d $(LIBDEST)/site-packages -f \ +- -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages +- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \ +- -d $(LIBDEST)/site-packages -f \ +- -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages +- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt +- -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ +- $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/PatternGrammar.txt ++# compile use host python, which may not be 2.7.9, which lead to fail. ++# So, we not compile, by srplab ++# PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -Wi -tt $(DESTDIR)$(LIBDEST)/compileall.py \ ++# -d $(LIBDEST) -f \ ++# -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ ++# $(DESTDIR)$(LIBDEST) ++# PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -Wi -tt -O $(DESTDIR)$(LIBDEST)/compileall.py \ ++# -d $(LIBDEST) -f \ ++# -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ ++# $(DESTDIR)$(LIBDEST) ++# -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -Wi -t $(DESTDIR)$(LIBDEST)/compileall.py \ ++# -d $(LIBDEST)/site-packages -f \ ++# -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages ++# -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -Wi -t -O $(DESTDIR)$(LIBDEST)/compileall.py \ ++# -d $(LIBDEST)/site-packages -f \ ++# -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages ++# -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt ++# -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \ ++# $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/PatternGrammar.txt + + # Create the PLATDIR source directory, if one wasn't distributed.. + $(srcdir)/Lib/$(PLATDIR): +Only in Python-2.7.15+iPhone: Makefile.pre.in.orig +diff -ur Python-2.7.15/Python/dynload_shlib.c Python-2.7.15+iPhone/Python/dynload_shlib.c +--- Python-2.7.15/Python/dynload_shlib.c 2018-04-29 12:47:33.000000000 -1000 ++++ Python-2.7.15+iPhone/Python/dynload_shlib.c 2018-09-04 18:39:57.000000000 -1000 +@@ -84,6 +84,14 @@ + PyOS_snprintf(funcname, sizeof(funcname), + LEAD_UNDERSCORE "init%.200s", shortname); + ++ /* On IOS, dlopen crash as soon as we try to open one of our library. ++ * Instead, we have done a redirection of linking to convert our .so into a ++ * .a. Then the main executable is linked with theses symbol. So, instead ++ * of trying to dlopen, directly do the dlsym. ++ * -- Mathieu ++ */ ++ return (dl_funcptr) dlsym(RTLD_DEFAULT, funcname); ++#if 0 + if (fp != NULL) { + int i; + struct stat statb; +@@ -140,4 +148,5 @@ + handles[nhandles++].handle = handle; + p = (dl_funcptr) dlsym(handle, funcname); + return p; ++#endif + } +diff -ur Python-2.7.15/Python/pythonrun.c Python-2.7.15+iPhone/Python/pythonrun.c +--- Python-2.7.15/Python/pythonrun.c 2018-04-29 12:47:33.000000000 -1000 ++++ Python-2.7.15+iPhone/Python/pythonrun.c 2018-09-04 18:39:57.000000000 -1000 +@@ -287,8 +287,10 @@ + _PyGILState_Init(interp, tstate); + #endif /* WITH_THREAD */ + ++#if 0 + if (!Py_NoSiteFlag) + initsite(); /* Module site */ ++#endif + + if ((p = Py_GETENV("PYTHONIOENCODING")) && *p != '\0') { + p = icodeset = codeset = strdup(p); +Only in Python-2.7.15+iPhone/Python: pythonrun.c.orig +Only in Python-2.7.15+iPhone: config.site +diff -ur Python-2.7.15/configure Python-2.7.15+iPhone/configure +--- Python-2.7.15/configure 2018-04-29 12:47:33.000000000 -1000 ++++ Python-2.7.15+iPhone/configure 2018-09-04 18:39:57.000000000 -1000 +@@ -3287,6 +3287,9 @@ + *-*-cygwin*) + ac_sys_system=Cygwin + ;; ++ *-*-darwin*) ++ ac_sys_system=Darwin ++ ;; + *) + # for now, limit cross builds to known configurations + MACHDEP="unknown" +@@ -3333,6 +3336,15 @@ + *-*-cygwin*) + _host_cpu= + ;; ++ *-*-darwin*) ++ case "$host_cpu" in ++ arm*) ++ _host_cpu=arm ++ ;; ++ *) ++ _host_cpu=$host_cpu ++ esac ++ ;; + *) + # for now, limit cross builds to known configurations + MACHDEP="unknown" +Only in Python-2.7.15+iPhone: configure.orig +diff -ur Python-2.7.15/setup.py Python-2.7.15+iPhone/setup.py +--- Python-2.7.15/setup.py 2018-04-29 12:47:33.000000000 -1000 ++++ Python-2.7.15+iPhone/setup.py 2018-09-04 18:40:07.000000000 -1000 +@@ -188,7 +188,7 @@ + ext_map = dict((ext.name, i) for i, ext in enumerate(extensions)) + if "_ctypes" in ext_map: + ctypes = extensions.pop(ext_map["_ctypes"]) +- extensions.append(ctypes) ++ # extensions.append(ctypes) # not build ctypes, by srplab + self.extensions = extensions + + # Fix up the autodetected modules, prefixing all the source files +@@ -1433,8 +1433,8 @@ + missing.append('zlib') + else: + missing.append('zlib') +- else: +- missing.append('zlib') ++ #else: ++ # missing.append('zlib') + + # Helper module for various ascii-encoders. Uses zlib for an optimized + # crc32 if we have it. Otherwise binascii uses its own. +Only in Python-2.7.15+iPhone: setup.py.orig |