From c8f2f585fc653db728e44812246d16ed8ae993d2 Mon Sep 17 00:00:00 2001 From: Andreas Oberritter Date: Mon, 12 Mar 2012 22:24:08 +0100 Subject: python, python-native: always set platform to linux2 * Fixes many problems with linux2 vs. linux3. At least: - Detected version was from build-host instead of target-host. - linuxaudiodev and ossaudiodev were disabled for linux3. - Files were missing in /usr/lib/python2.7/plat-linux3. * Imported from upstream HG rev c816479f6aaf * Bugtracker URL: http://bugs.python.org/issue12326 (From OE-Core rev: accb2b728ab10cae20be59253a56ac6410b8de10) Signed-off-by: Andreas Oberritter Signed-off-by: Richard Purdie --- .../python/python/07-linux3-regen-fix.patch | 18 ---------- .../python/sys_platform_is_now_always_linux2.patch | 39 ++++++++++++++++++++++ 2 files changed, 39 insertions(+), 18 deletions(-) delete mode 100644 meta/recipes-devtools/python/python/07-linux3-regen-fix.patch create mode 100644 meta/recipes-devtools/python/python/sys_platform_is_now_always_linux2.patch (limited to 'meta/recipes-devtools/python/python') diff --git a/meta/recipes-devtools/python/python/07-linux3-regen-fix.patch b/meta/recipes-devtools/python/python/07-linux3-regen-fix.patch deleted file mode 100644 index d7fb313..0000000 --- a/meta/recipes-devtools/python/python/07-linux3-regen-fix.patch +++ /dev/null @@ -1,18 +0,0 @@ -Upstream-Status: Inappropriate [embedded specific] - -Without this patch it calls cross-compiled python if host is running linux-3.0 -python$EXE ../../Tools/scripts/h2py.py -i '(u_long)' /usr/include/netinet/in.h -| ./regen: line 3: /OE/shr-core/tmp/work/armv4t-oe-linux-gnueabi/python-2.6.6-nk2.8/Python-2.6.6/python: cannot execute binary file - -diff -uNr Python-2.6.6.orig//Lib/plat-linux3/regen Python-2.6.6/Lib/plat-linux3/regen ---- Python-2.6.6.orig//Lib/plat-linux3/regen 1970-01-01 01:00:00.000000000 +0100 -+++ Python-2.6.6/Lib/plat-linux3/regen 2001-08-09 14:48:17.000000000 +0200 -@@ -0,0 +1,8 @@ -+#! /bin/sh -+case `uname` in -+Linux*) ;; -+*) echo Probably not on a Linux system 1>&2 -+ exit 1;; -+esac -+set -v -+h2py -i '(u_long)' /usr/include/sys/types.h /usr/include/netinet/in.h /usr/include/dlfcn.h diff --git a/meta/recipes-devtools/python/python/sys_platform_is_now_always_linux2.patch b/meta/recipes-devtools/python/python/sys_platform_is_now_always_linux2.patch new file mode 100644 index 0000000..ed52936 --- /dev/null +++ b/meta/recipes-devtools/python/python/sys_platform_is_now_always_linux2.patch @@ -0,0 +1,39 @@ +Upstream-Status: Accepted [http://hg.python.org/cpython/rev/c816479f6aaf/] +Bugtracker: http://bugs.python.org/issue12326 + +[Removed "Misc/NEWS" hunk] + +Signed-off-by: Andreas Oberritter + +# HG changeset patch +# User Victor Stinner +# Date 1313841758 -7200 +# Node ID c816479f6aaf71dbd3f3fe4b239186d60c55ce48 +# Parent 3e093590ac57fdda428c7da3f72ddf0c475ecf2b +Issue #12326: sys.platform is now always 'linux2' on Linux + +Even if Python is compiled on Linux 3. + +diff --git a/configure b/configure +--- a/configure ++++ b/configure +@@ -2995,6 +2995,7 @@ then + MACHDEP="$ac_md_system$ac_md_release" + + case $MACHDEP in ++ linux*) MACHDEP="linux2";; + cygwin*) MACHDEP="cygwin";; + darwin*) MACHDEP="darwin";; + atheos*) MACHDEP="atheos";; +diff --git a/configure.in b/configure.in +--- a/configure.in ++++ b/configure.in +@@ -293,6 +293,7 @@ then + MACHDEP="$ac_md_system$ac_md_release" + + case $MACHDEP in ++ linux*) MACHDEP="linux2";; + cygwin*) MACHDEP="cygwin";; + darwin*) MACHDEP="darwin";; + atheos*) MACHDEP="atheos";; + -- cgit v1.1