summaryrefslogtreecommitdiff
path: root/meta/recipes-qt/qt4
diff options
context:
space:
mode:
authorEric Bénard <eric@eukrea.com>2011-09-10 11:17:57 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2011-10-04 11:34:21 +0100
commit5f6fb92b939147d2d6aa7790a378d4b7cce3ada5 (patch)
treecdc07d2d8101ab5d3ff144116de23011d1ee3dcf /meta/recipes-qt/qt4
parentc2f4bae0a100f3752153ecb93adb9ede4f55322a (diff)
downloadopenembedded-core-5f6fb92b939147d2d6aa7790a378d4b7cce3ada5.tar.gz
openembedded-core-5f6fb92b939147d2d6aa7790a378d4b7cce3ada5.tar.bz2
openembedded-core-5f6fb92b939147d2d6aa7790a378d4b7cce3ada5.zip
qt4: fix generated sdk
- qt4-tools-nativesdk : actually the qmake binary which gets installed comes from the native recipe. This patch fix this problem by launching configure twice : once to compile qmake using the right toolchain for nativesdk, and a second time using the native qmake to compile all the other tools for the nativesdk. Then we install the right qmake. - mkspec : the link actually created in qt4-tools-nativesdk's do_install point to nowhere so remove it and generate the link in meta-toolchain-qte as it's the only place where we have all the variable to create it. - toolchain_create_sdk_env_script_append : we need to add OE_QMAKE_CFLAGS, OE_QMAKE_CXXFLAGS and OE_QMAKE_LDFLAGS else the sdk won't find these variables that are inserted by qmake in the Makefiles. - with this patch, oe-core generates a working meta-toolchain-qte which can compile a small example and is properly recognized by qtcreator (this brings oe-core's meta-toolchain-qte to oe-dev's functional state). Signed-off-by: Eric Bénard <eric@eukrea.com>
Diffstat (limited to 'meta/recipes-qt/qt4')
-rw-r--r--meta/recipes-qt/qt4/qt4-tools-nativesdk.inc22
1 files changed, 11 insertions, 11 deletions
diff --git a/meta/recipes-qt/qt4/qt4-tools-nativesdk.inc b/meta/recipes-qt/qt4/qt4-tools-nativesdk.inc
index 6c396a5ae4..097fadc980 100644
--- a/meta/recipes-qt/qt4/qt4-tools-nativesdk.inc
+++ b/meta/recipes-qt/qt4/qt4-tools-nativesdk.inc
@@ -51,10 +51,6 @@ EXTRA_OECONF = "-prefix ${prefix} \
EXTRA_OEMAKE = " "
do_configure() {
- if [ ! -e bin/qmake ]; then
- ln -sf ${STAGING_BINDIR_NATIVE}/qmake2 bin/qmake
- fi
-
if [ ! -e mkspecs/${TARGET_OS}-oe-g++ ]; then
ln -sf linux-g++ mkspecs/${TARGET_OS}-oe-g++
fi
@@ -62,7 +58,16 @@ do_configure() {
cp ../g++.conf mkspecs/common
cp ../linux.conf mkspecs/common
- (echo o; echo yes) | ./configure ${EXTRA_OECONF} || die "Configuring qt failed. EXTRA_OECONF was ${EXTRA_OECONF}"
+ # first launch configure to get qmake compiled for the nativesdk
+ (echo o; echo yes) | CC="${CC}" CXX="${CXX}" ./configure ${EXTRA_OECONF} || true
+
+ # then backup the binary and start again with a qmake which can run on the build host
+ mv bin/qmake bin/qmake_nativesdk
+ if [ ! -e bin/qmake ]; then
+ ln -sf ${STAGING_BINDIR_NATIVE}/qmake2 bin/qmake
+ fi
+
+ (echo o; echo yes) | CC="${CC}" CXX="${CXX}" ./configure ${EXTRA_OECONF} || die "Configuring qt failed. EXTRA_OECONF was ${EXTRA_OECONF}"
}
TOBUILD = "\
@@ -91,7 +96,7 @@ do_compile() {
do_install() {
install -d ${D}${bindir}
- install -m 0755 bin/qmake ${D}${bindir}/qmake2
+ install -m 0755 bin/qmake_nativesdk ${D}${bindir}/qmake2
for i in moc uic uic3 rcc lrelease lupdate qdbuscpp2xml qdbusxml2cpp; do
install -m 0755 bin/${i} ${D}${bindir}/${i}4
done
@@ -101,9 +106,4 @@ do_install() {
for i in moc uic uic3 rcc lrelease lupdate qdbuscpp2xml qdbusxml2cpp; do \
ln -s ${i}4 ${i}; \
done)
-
- # make a symbolic link to mkspecs for compatibility with Nokia's SDK
- # and QTCreator
- (cd ${D}${bindir}/..; ln -s ${TARGET_SYS}/usr/share/qtopia/mkspecs mkspecs;)
}
-