]> code.ossystems Code Review - openembedded-core.git/commitdiff
python: add patch to fix cross compilation on host with linux-3.0
authorMartin Jansa <Martin.Jansa@gmail.com>
Wed, 20 Jul 2011 19:52:15 +0000 (21:52 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 21 Jul 2011 09:47:42 +0000 (10:47 +0100)
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
meta/recipes-devtools/python/python/07-linux3-regen-fix.patch [new file with mode: 0644]
meta/recipes-devtools/python/python_2.6.6.bb

diff --git a/meta/recipes-devtools/python/python/07-linux3-regen-fix.patch b/meta/recipes-devtools/python/python/07-linux3-regen-fix.patch
new file mode 100644 (file)
index 0000000..d7fb313
--- /dev/null
@@ -0,0 +1,18 @@
+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
index 76f32f248158365166b2d46081ba8b7a29d79bb6..598fea8143847d64496fdaa0d6f5b7f2fb3fa0b3 100644 (file)
@@ -15,6 +15,7 @@ SRC_URI = "\
   file://05-enable-ctypes-cross-build.patch \
   file://06-ctypes-libffi-fix-configure.patch \
   file://06-avoid_usr_lib_termcap_path_in_linking.patch \
+  file://07-linux3-regen-fix.patch \
   file://99-ignore-optimization-flag.patch \
   ${DISTRO_SRC_URI} \
   file://multilib.patch \