[OE-core] [OE-CORE][thud][PATCH] python3_3.5.6.bb: Remove setting of PYTHONHOME

Jaewon Lee jaewon.lee at xilinx.com
Tue Mar 5 22:29:48 UTC 2019


PYTHONHOME was set in python wrapper to 'ensure that the nativesdk
python functions correctly without needing to set PYTHONHOME in the sdk
environment setup script' (From OE-Core rev:c5629268b0f8ae0a425c98337d13e8dc83107e13)
But thud doesnt use python3 libraries from buildtools like python2 does
so oe-buildenv-internal throws the following error when running any
devtool command from an extracted esdk:

ImportError: No module named site
OpenEmbedded requires 'python' to be python v2 (>= 2.7.3), not python v3.
Please upgrade your python v2.

There is no lib/python3 in the path PYTHONHOME is being set to
( buildtools/sysroots/x86_64.../usr ).
Taking out the setting of PYTHONHOME in the python3 wrapper to get rid
of this issue

[YOCTO #13208]

Signed-off-by: Jaewon Lee <jaewon.lee at xilinx.com>
Signed-off-by: Alejandro Enedino Hernandez Samaniego <alejandr at xilinx.com>
---
 meta/recipes-devtools/python/python3_3.5.6.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-devtools/python/python3_3.5.6.bb b/meta/recipes-devtools/python/python3_3.5.6.bb
index 2cb6504..c2fe943 100644
--- a/meta/recipes-devtools/python/python3_3.5.6.bb
+++ b/meta/recipes-devtools/python/python3_3.5.6.bb
@@ -178,7 +178,7 @@ do_install() {
 }
 
 do_install_append_class-nativesdk () {
-	create_wrapper ${D}${bindir}/python${PYTHON_MAJMIN} PYTHONHOME='${prefix}' TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo' PYTHONNOUSERSITE='1'
+	create_wrapper ${D}${bindir}/python${PYTHON_MAJMIN} TERMINFO_DIRS='${sysconfdir}/terminfo:/etc/terminfo:/usr/share/terminfo:/usr/share/misc/terminfo:/lib/terminfo' PYTHONNOUSERSITE='1'
 }
 
 SSTATE_SCAN_FILES += "Makefile"
-- 
1.8.3.1



More information about the Openembedded-core mailing list