aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDennis Menschel <menschel-d@posteo.de>2018-06-28 19:38:17 +0200
committerMartin Jansa <Martin.Jansa@gmail.com>2018-07-09 07:35:22 +0000
commit7cec24ffd4be3db2640da2449c5f69f1da8c0c6d (patch)
treec9b923454178f301ab78d8ec49274f9ac64ff5e9
parent681aa041f403513b365c209f76ba79447a7eb066 (diff)
qtbase: fix runtime dependency on python
When running the task "do_populate_sdk()" for an image inheriting from "populate_sdk_qt5.bbclass", the following error could be observed in case PACKAGE_CLASSES included "package_rpm": ERROR: Could not invoke dnf. [...] Error: Problem: package packagegroup-qt5-toolchain-target-1.0-r0.noarch requires qtbase-mkspecs, but none of the providers can be installed - conflicting requests - nothing provides /usr/bin/python needed by qtbase-mkspecs-5.10.1+git0+6c6ace9d23-r0.armv5e The script file in question that requires python to run is located at "/usr/lib/qt5/mkspecs/features/uikit/devices.py". The aforementioned dependency has been circumvented by calling python indirectly via "/usr/bin/env". Signed-off-by: Dennis Menschel <menschel-d@posteo.de>
-rw-r--r--recipes-qt/qt5/nativesdk-qtbase_git.bb4
-rw-r--r--recipes-qt/qt5/qtbase_git.bb4
2 files changed, 6 insertions, 2 deletions
diff --git a/recipes-qt/qt5/nativesdk-qtbase_git.bb b/recipes-qt/qt5/nativesdk-qtbase_git.bb
index 87da66e4..da963d1a 100644
--- a/recipes-qt/qt5/nativesdk-qtbase_git.bb
+++ b/recipes-qt/qt5/nativesdk-qtbase_git.bb
@@ -176,8 +176,8 @@ do_install() {
install -m 644 ${WORKDIR}/OEQt5Toolchain.cmake ${D}${datadir}/cmake/OEToolchainConfig.cmake.d/
# Fix up absolute paths in scripts
- grep -lr /usr/bin/python ${D}${OE_QMAKE_PATH_QT_ARCHDATA}/ | \
- xargs -r sed -i -e '1s,#!.*python,#! ${USRBINPATH}/env python,'
+ sed -i -e '1s,#!/usr/bin/python,#! ${USRBINPATH}/env python,' \
+ ${D}${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/features/uikit/devices.py
}
fakeroot do_generate_qt_environment_file() {
diff --git a/recipes-qt/qt5/qtbase_git.bb b/recipes-qt/qt5/qtbase_git.bb
index 0078c801..3064b748 100644
--- a/recipes-qt/qt5/qtbase_git.bb
+++ b/recipes-qt/qt5/qtbase_git.bb
@@ -237,6 +237,10 @@ do_install_append() {
echo "isEmpty(QMAKE_STRIP): QMAKE_STRIP = ${TARGET_PREFIX}strip" >> $conf
generate_target_qt_config_file ${D}${OE_QMAKE_PATH_BINS}/qt.conf
+
+ # Fix up absolute paths in scripts
+ sed -i -e '1s,#!/usr/bin/python,#! ${USRBINPATH}/env python,' \
+ ${D}${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/features/uikit/devices.py
}
# mkspecs have mac specific scripts that depend on perl and bash