summaryrefslogtreecommitdiff
path: root/meta-qt5
diff options
context:
space:
mode:
authorOtavio Salvador <otavio@ossystems.com.br>2014-10-09 12:45:06 -0300
committerPatrick Ohly <patrick.ohly@intel.com>2015-01-09 08:46:16 -0800
commit9d6c865151c956f4d479b0da480e4cc4327cae70 (patch)
treeaf1a7947ff37d311108f271a22605cad9747f1cc /meta-qt5
parent6537d43d0fb9c7a946d7f93f0a8b5f846f35dacd (diff)
downloadtizen-distro-9d6c865151c956f4d479b0da480e4cc4327cae70.tar.gz
tizen-distro-9d6c865151c956f4d479b0da480e4cc4327cae70.tar.bz2
tizen-distro-9d6c865151c956f4d479b0da480e4cc4327cae70.zip
Fix SDK environment setting
Since the change to use a meta-environment canadian package in the OE-Core, the SDK environment setting has been broken. This uses the new subscript environment to fix it and also move the environment generation to the nativesdk-qtbase recipe. (From meta-qt5 rev: 2f1b8fe630ac76c8ff5d184f109449b10fde5a92) Signed-off-by: Otavio Salvador <otavio@ossystems.com.br> Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Diffstat (limited to 'meta-qt5')
-rw-r--r--meta-qt5/classes/populate_sdk_qt5.bbclass21
-rw-r--r--meta-qt5/recipes-qt/qt5/nativesdk-qtbase.inc30
2 files changed, 31 insertions, 20 deletions
diff --git a/meta-qt5/classes/populate_sdk_qt5.bbclass b/meta-qt5/classes/populate_sdk_qt5.bbclass
index 7b31bbb070..79df489013 100644
--- a/meta-qt5/classes/populate_sdk_qt5.bbclass
+++ b/meta-qt5/classes/populate_sdk_qt5.bbclass
@@ -6,26 +6,7 @@ TOOLCHAIN_TARGET_TASK += "packagegroup-qt5-toolchain-target"
# This allow reuse of Qt paths
inherit qmake5_paths
-toolchain_create_sdk_env_script_append () {
- echo 'export PATH=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}:$PATH' >> $script
- echo 'export OE_QMAKE_CFLAGS="$CFLAGS"' >> $script
- echo 'export OE_QMAKE_CXXFLAGS="$CXXFLAGS"' >> $script
- echo 'export OE_QMAKE_LDFLAGS="$LDFLAGS"' >> $script
- echo 'export OE_QMAKE_CC=$CC' >> $script
- echo 'export OE_QMAKE_CXX=$CXX' >> $script
- echo 'export OE_QMAKE_LINK=$CXX' >> $script
- echo 'export OE_QMAKE_AR=$AR' >> $script
- echo 'export OE_QMAKE_LIBDIR_QT=${SDKTARGETSYSROOT}${OE_QMAKE_PATH_LIBS}' >> $script
- echo 'export OE_QMAKE_INCDIR_QT=${SDKTARGETSYSROOT}${OE_QMAKE_PATH_QT_HEADERS}' >> $script
- echo 'export OE_QMAKE_MOC=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/moc' >> $script
- echo 'export OE_QMAKE_UIC=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/uic' >> $script
- echo 'export OE_QMAKE_RCC=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/rcc' >> $script
- echo 'export OE_QMAKE_QDBUSCPP2XML=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/qdbuscpp2xml' >> $script
- echo 'export OE_QMAKE_QDBUSXML2CPP=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/qdbusxml2cpp' >> $script
- echo 'export OE_QMAKE_QT_CONFIG=${SDKTARGETSYSROOT}${OE_QMAKE_PATH_LIBS}/${QT_DIR_NAME}/mkspecs/qconfig.pri' >> $script
- echo 'export QMAKESPEC=${SDKTARGETSYSROOT}${OE_QMAKE_PATH_LIBS}/${QT_DIR_NAME}/mkspecs/linux-oe-g++' >> $script
- echo 'export QT_CONF_PATH=${SDKPATHNATIVE}${OE_QMAKE_PATH_HOST_BINS}/qt.conf' >> $script
-
+create_sdk_files_prepend () {
# make a symbolic link to mkspecs for compatibility with QTCreator
(cd ${SDK_OUTPUT}/${SDKPATHNATIVE}; \
ln -sf ${SDKTARGETSYSROOT}${libdir}/${QT_DIR_NAME}/mkspecs mkspecs;)
diff --git a/meta-qt5/recipes-qt/qt5/nativesdk-qtbase.inc b/meta-qt5/recipes-qt/qt5/nativesdk-qtbase.inc
index faecc64369..12f5a543bb 100644
--- a/meta-qt5/recipes-qt/qt5/nativesdk-qtbase.inc
+++ b/meta-qt5/recipes-qt/qt5/nativesdk-qtbase.inc
@@ -57,6 +57,7 @@ FILES_${PN}-tools-dbg = " \
FILES_${PN}-tools = " \
${libdir}/lib*${SOLIBS} \
${OE_QMAKE_PATH_BINS}/* \
+ ${SDKPATHNATIVE}/environment-setup.d \
"
# qttools binaries are placed in a subdir of bin in order to avoid
@@ -218,3 +219,32 @@ do_install() {
-not -name 'libQt5Bootstrap.a' \
-exec rm '{}' ';'
}
+
+do_generate_qt_environment_file() {
+ mkdir -p ${D}${SDKPATHNATIVE}/environment-setup.d/
+ script=${D}${SDKPATHNATIVE}/environment-setup.d/qt5.sh
+
+ echo 'export PATH=${OE_QMAKE_PATH_HOST_BINS}:$PATH' > $script
+ echo 'export OE_QMAKE_CFLAGS="$CFLAGS"' >> $script
+ echo 'export OE_QMAKE_CXXFLAGS="$CXXFLAGS"' >> $script
+ echo 'export OE_QMAKE_LDFLAGS="$LDFLAGS"' >> $script
+ echo 'export OE_QMAKE_CC=$CC' >> $script
+ echo 'export OE_QMAKE_CXX=$CXX' >> $script
+ echo 'export OE_QMAKE_LINK=$CXX' >> $script
+ echo 'export OE_QMAKE_AR=$AR' >> $script
+ echo 'export QT_CONF_PATH=${OE_QMAKE_PATH_HOST_BINS}/qt.conf' >> $script
+ echo 'export OE_QMAKE_LIBDIR_QT=`qmake -query QT_INSTALL_LIBS`' >> $script
+ echo 'export OE_QMAKE_INCDIR_QT=`qmake -query QT_INSTALL_HEADERS`' >> $script
+ echo 'export OE_QMAKE_MOC=${OE_QMAKE_PATH_HOST_BINS}/moc' >> $script
+ echo 'export OE_QMAKE_UIC=${OE_QMAKE_PATH_HOST_BINS}/uic' >> $script
+ echo 'export OE_QMAKE_RCC=${OE_QMAKE_PATH_HOST_BINS}/rcc' >> $script
+ echo 'export OE_QMAKE_QDBUSCPP2XML=${OE_QMAKE_PATH_HOST_BINS}/qdbuscpp2xml' >> $script
+ echo 'export OE_QMAKE_QDBUSXML2CPP=${OE_QMAKE_PATH_HOST_BINS}/qdbusxml2cpp' >> $script
+ echo 'export OE_QMAKE_QT_CONFIG=${OE_QMAKE_PATH_TARGET_LIBS}/${QT_DIR_NAME}/mkspecs/qconfig.pri' >> $script
+ echo 'export QMAKESPEC=`qmake -query QT_INSTALL_LIBS`/mkspecs/linux-oe-g++' >> $script
+
+ # Use relocable sysroot
+ sed -i -e 's:${SDKPATHNATIVE}:$OECORE_NATIVE_SYSROOT:g' $script
+}
+
+addtask generate_qt_environment_file after do_install before do_package