[oe-commits] Peter Kjellerstedt : python-scons-native: Make it useable if old host install exists

git at git.openembedded.org git at git.openembedded.org
Fri Aug 15 07:47:46 UTC 2014


Module: openembedded-core.git
Branch: master-next
Commit: e90c4568ddc2a5036cb2c40b407f0fa19f5fe63a
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=e90c4568ddc2a5036cb2c40b407f0fa19f5fe63a

Author: Peter Kjellerstedt <peter.kjellerstedt at axis.com>
Date:   Wed Aug 13 19:41:04 2014 +0200

python-scons-native: Make it useable if old host install exists

This was recently fixed to work on Fedora 17 if no scons is installed
on the host by setting the PYTHONPATH to where BitBake has installed
scons. However, if an older version of scons than 2.3.0 is installed,
then it still breaks. This is due to how scons tries to determine its
installation by searching through standard paths. If it finds an old
installation it prepends that path to sys.path thereby causing it to
ignore the PYTHONPATH. The solution is to instead set SCONS_LIB_PATH
which works both if scons is not installed and if an older version is
installed.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt at axis.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 meta/recipes-devtools/python/python-scons-native_2.3.2.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-devtools/python/python-scons-native_2.3.2.bb b/meta/recipes-devtools/python/python-scons-native_2.3.2.bb
index 067ed61..dae89ab 100644
--- a/meta/recipes-devtools/python/python-scons-native_2.3.2.bb
+++ b/meta/recipes-devtools/python/python-scons-native_2.3.2.bb
@@ -4,5 +4,5 @@ DEPENDS = "python-native"
 RDEPENDS_${PN} = ""
 
 do_install_append() {
-    create_wrapper ${D}${bindir}/scons  PYTHONPATH='$PYTHONPATH:${STAGING_DIR_HOST}/${PYTHON_SITEPACKAGES_DIR}'
+    create_wrapper ${D}${bindir}/scons SCONS_LIB_DIR='${STAGING_DIR_HOST}/${PYTHON_SITEPACKAGES_DIR}'
 }



More information about the Openembedded-commits mailing list