aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Jansa <Martin.Jansa@gmail.com>2021-04-06 12:25:20 +0200
committerMartin Jansa <Martin.Jansa@gmail.com>2021-04-07 09:16:40 +0200
commitb744c3805f1e3c04a620287fea80cbcdd9754bb3 (patch)
tree6388165038f5bdc06b153222d977867607294b3a
parent6f853340dafb8a53b08403729957b473f0f4884e (diff)
downloadmeta-python2-b744c3805f1e3c04a620287fea80cbcdd9754bb3.tar.gz
meta-python2-b744c3805f1e3c04a620287fea80cbcdd9754bb3.tar.bz2
meta-python2-b744c3805f1e3c04a620287fea80cbcdd9754bb3.zip
python-pyrex: fix installed-vs-shipped QA issue with usrmerge
* fixes: ERROR: python-pyrex-0.9.9-r4 do_package: QA Issue: python-pyrex: Files/directories were installed but not shipped in any package: /usr/share /usr/share/lib /usr/share/lib/python2.7 /usr/share/lib/python2.7/site-packages /usr/share/lib/python2.7/site-packages/Pyrex /usr/share/lib/python2.7/site-packages/Pyrex/Compiler /usr/share/lib/python2.7/site-packages/Pyrex/Compiler/Lexicon.pickle Please set FILES such that these items are packaged. Alternatively if they are unneeded, avoid installing them or delete them within do_install. python-pyrex: 7 installed and not shipped files. [installed-vs-shipped] ERROR: python-pyrex-0.9.9-r4 do_package: Fatal QA errors found, failing task. * base_libdir becames /usr/lib with usrmerge in DISTRO_FEATURES: # $base_libdir [4 operations] # exported /OE/build/oe-core/openembedded-core/meta/conf/bitbake.conf:26 # [export] "1" # set /OE/build/oe-core/openembedded-core/meta/conf/bitbake.conf:26 # "${root_prefix}/${baselib}" # override[native]:set /OE/build/oe-core/openembedded-core/meta/conf/bitbake.conf:62 # "/lib" # override[nativesdk]:set /OE/build/oe-core/openembedded-core/meta/conf/bitbake.conf:73 # "/lib" # pre-expansion value: # "${root_prefix}/${baselib}" export base_libdir="/usr/lib" # $root_prefix # set /OE/build/oe-core/openembedded-core/meta/conf/bitbake.conf:21 # "${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', '${exec_prefix}', '${base_prefix}', d)}" root_prefix="/usr" * but pyrex setup.py is using get_python_lib from distutils.sysconfig and that doesn't get changed to /usr/lib prefix: data_files=[ (compiler_dir, ['Pyrex/Compiler/Lexicon.pickle']) ] compiler_dir = os.path.join(get_python_lib(prefix=''), 'Pyrex', 'Compiler') >>> from distutils.sysconfig import get_python_lib >>> print(get_python_lib(prefix='')) lib/python2.7/dist-packages * python3 is also using baselib meta/recipes-devtools/python/python3_3.9.2.bb:EXTRA_OECONF = " --without-ensurepip --enable-shared --with-platlibdir=${baselib}" meta/recipes-devtools/python/python3_3.9.2.bb: LIB=${baselib} \ meta-oe/recipes-extended/mraa/mraa_git.bb: -DPYTHON3_PACKAGES_PATH:PATH=${baselib}/python${PYTHON_BASEVERSION}/site-packages in python2 it seems to implement the same but through libdirleaf dropping ${prefix}/ recipes-devtools/python/python.inc: libdirleaf="$(echo ${libdir} | sed -e 's:${prefix}/::')" recipes-devtools/python/python.inc: sed -i -e "s:SEDMELIBLEAF:${libdirleaf}:g" \ before that it was using "basename ${libdir}" https://git.openembedded.org/openembedded-core/commit/?id=c61c416a6504f7e8885df3c94c839d1031920a1c Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
-rw-r--r--recipes-devtools/python/python-pyrex_0.9.9.bb2
1 files changed, 1 insertions, 1 deletions
diff --git a/recipes-devtools/python/python-pyrex_0.9.9.bb b/recipes-devtools/python/python-pyrex_0.9.9.bb
index 3df784f8..51786df6 100644
--- a/recipes-devtools/python/python-pyrex_0.9.9.bb
+++ b/recipes-devtools/python/python-pyrex_0.9.9.bb
@@ -19,6 +19,6 @@ S = "${WORKDIR}/${SRCNAME}-${PV}"
inherit distutils
-FILES_${PN} += "${datadir}${base_libdir}/${PYTHON_DIR}/site-packages/Pyrex/Compiler/Lexicon.pickle"
+FILES_${PN} += "${datadir}${baselib}/${PYTHON_DIR}/site-packages/Pyrex/Compiler/Lexicon.pickle"
PNBLACKLIST[python-pyrex] ?= "${@bb.utils.contains('I_SWEAR_TO_MIGRATE_TO_PYTHON3', 'yes', '', 'python2 is out of support for long time, read https://www.python.org/doc/sunset-python-2/ https://python3statement.org/ and if you really have to temporarily use this, then set I_SWEAR_TO_MIGRATE_TO_PYTHON3 to "yes"', d)}"