diff options
| author | Martin Jansa <Martin.Jansa@gmail.com> | 2012-12-12 06:19:48 +0100 |
|---|---|---|
| committer | Martin Jansa <Martin.Jansa@gmail.com> | 2012-12-12 20:08:40 +0100 |
| commit | 97f4709e4c5e3facea506cde3c98a4175c01be63 (patch) | |
| tree | 5319e7b5a148d02756cfc69424a188da56f130e6 /recipes-qt/qt5/qt5.inc | |
| parent | a03f6cc2bf012d5e43eb27210f8b835a80d50346 (diff) | |
| download | meta-qt5-97f4709e4c5e3facea506cde3c98a4175c01be63.tar.gz | |
qt5: move qtbase specific stuff from qt5.inc to qtbase.inc
* qt5.inc should be used by all qtmodule.inc
* add missing PACKAGES in qt5.inc
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'recipes-qt/qt5/qt5.inc')
| -rw-r--r-- | recipes-qt/qt5/qt5.inc | 95 |
1 files changed, 2 insertions, 93 deletions
diff --git a/recipes-qt/qt5/qt5.inc b/recipes-qt/qt5/qt5.inc index ef4dbd36..3ba352cb 100644 --- a/recipes-qt/qt5/qt5.inc +++ b/recipes-qt/qt5/qt5.inc | |||
| @@ -2,12 +2,6 @@ | |||
| 2 | 2 | ||
| 3 | inherit qmake5_base | 3 | inherit qmake5_base |
| 4 | 4 | ||
| 5 | SRC_URI += " \ | ||
| 6 | file://qmake-build.conf.sh \ | ||
| 7 | file://qmake.conf.sh \ | ||
| 8 | file://qplatformdefs.h \ | ||
| 9 | " | ||
| 10 | |||
| 11 | # Qt5 is dependent on icu for localization | 5 | # Qt5 is dependent on icu for localization |
| 12 | ICU = "icu " | 6 | ICU = "icu " |
| 13 | ICU_powerpc = "pango" | 7 | ICU_powerpc = "pango" |
| @@ -16,7 +10,7 @@ DEPENDS += "qt5-tools-native virtual/libgl freetype jpeg libpng zlib openssl gli | |||
| 16 | 10 | ||
| 17 | require qt5_arch.inc | 11 | require qt5_arch.inc |
| 18 | 12 | ||
| 19 | QT_MODULE ?= "${PN}" | 13 | QT_MODULE ?= "${BPN}" |
| 20 | 14 | ||
| 21 | QT_DISTRO_FLAGS ?= "-no-accessibility -no-sm" | 15 | QT_DISTRO_FLAGS ?= "-no-accessibility -no-sm" |
| 22 | QT_DISTRO_FLAGS_linuxstdbase = "-sm" | 16 | QT_DISTRO_FLAGS_linuxstdbase = "-sm" |
| @@ -79,76 +73,6 @@ do_configure() { | |||
| 79 | 73 | ||
| 80 | # Avoid problems with the linkers, since we want the linker to be g++ | 74 | # Avoid problems with the linkers, since we want the linker to be g++ |
| 81 | unset LD | 75 | unset LD |
| 82 | |||
| 83 | ### Make sure that our mkspecs will eventually end up in STAGING_DATADIR | ||
| 84 | ${OE_QMAKE_QMAKE} -set OE_CROSS_INSTALL_DATA ${datadir}/${QT_DIR_NAME} | ||
| 85 | sed -i '/mkspecs\.path/s/QT_HOST_DATA/OE_CROSS_INSTALL_DATA/' qtbase.pro | ||
| 86 | sed -i '/pritarget/s/QT_HOST_DATA/OE_CROSS_INSTALL_DATA/' mkspecs/features/qt_installs.prf | ||
| 87 | |||
| 88 | ### Same applies to the module headers... | ||
| 89 | ${OE_QMAKE_QMAKE} -set OE_CROSS_INSTALL_HEADERS ${includedir}/${QT_DIR_NAME} | ||
| 90 | sed -i 's/QT_INSTALL_HEADERS/OE_CROSS_INSTALL_HEADERS/g' mkspecs/features/qt_installs.prf | ||
| 91 | |||
| 92 | ### Create the mkspec for the target | ||
| 93 | mkdir -p mkspecs/${TARGET_OS}-oe-g++ | ||
| 94 | cp -f ${WORKDIR}/qplatformdefs.h mkspecs/${TARGET_OS}-oe-g++ | ||
| 95 | bash ${WORKDIR}/qmake.conf.sh > mkspecs/${TARGET_OS}-oe-g++/qmake.conf | ||
| 96 | |||
| 97 | ### Stage the base mkspecs so that 'HostData' will find them | ||
| 98 | mkdir -p ${STAGING_DATADIR}/${QT_DIR_NAME} | ||
| 99 | cp -r ${STAGING_DATADIR_NATIVE}/${QT_DIR_NAME}/mkspecs ${STAGING_DATADIR}/${QT_DIR_NAME}/ | ||
| 100 | ### Make sure that modules are installed correctly. During configure they will pick this one | ||
| 101 | ### instead of the one from ${S}/mkspecs... | ||
| 102 | sed -i '/pritarget/s/QT_HOST_DATA/OE_CROSS_INSTALL_DATA/' \ | ||
| 103 | ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/features/qt_installs.prf | ||
| 104 | rm -rf ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/modules* | ||
| 105 | |||
| 106 | ### Remove the old pri files | ||
| 107 | rm ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/*.pri | ||
| 108 | |||
| 109 | |||
| 110 | echo "[Paths]" > $QT_CONF_PATH | ||
| 111 | echo "Binaries=${bindir}" >> $QT_CONF_PATH | ||
| 112 | echo "Headers=${includedir}/${QT_DIR_NAME}" >> $QT_CONF_PATH | ||
| 113 | echo "Documentation=${docdir}/${QT_DIR_NAME}" >> $QT_CONF_PATH | ||
| 114 | echo "Libraries=${libdir}" >> $QT_CONF_PATH | ||
| 115 | echo "Plugins=${libdir}/${QT_DIR_NAME}/plugins" >> $QT_CONF_PATH | ||
| 116 | echo "Data=${datadir}/${QT_DIR_NAME}" >> $QT_CONF_PATH | ||
| 117 | echo "Translations=${datadir}/${QT_DIR_NAME}/translations" >> $QT_CONF_PATH | ||
| 118 | echo "Settings=${sysconfdir}/${QT_DIR_NAME}" >> $QT_CONF_PATH | ||
| 119 | echo "Examples=${bindir}/${QT_DIR_NAME}/examples" >> $QT_CONF_PATH | ||
| 120 | echo "HostBinaries=${STAGING_BINDIR_NATIVE}" >> $QT_CONF_PATH | ||
| 121 | echo "HostData=${STAGING_DATADIR}/${QT_DIR_NAME}" >> $QT_CONF_PATH | ||
| 122 | |||
| 123 | ./configure -v \ | ||
| 124 | -dont-process \ | ||
| 125 | -opensource -confirm-license \ | ||
| 126 | -prefix ${prefix} \ | ||
| 127 | -bindir ${bindir} \ | ||
| 128 | -libdir ${libdir} \ | ||
| 129 | -datadir ${datadir}/${QT_DIR_NAME} \ | ||
| 130 | -sysconfdir ${sysconfdir}/${QT_DIR_NAME} \ | ||
| 131 | -docdir ${docdir}/${QT_DIR_NAME} \ | ||
| 132 | -headerdir ${includedir}/${QT_DIR_NAME} \ | ||
| 133 | -plugindir ${libdir}/${QT_DIR_NAME}/plugins \ | ||
| 134 | -importdir ${libdir}/${QT_DIR_NAME}/imports \ | ||
| 135 | -translationdir ${datadir}/${QT_DIR_NAME}/translations \ | ||
| 136 | -examplesdir ${bindir}/${QT_DIR_NAME}/examples \ | ||
| 137 | -platform ${TARGET_OS}-oe-g++ \ | ||
| 138 | -xplatform ${TARGET_OS}-oe-g++ \ | ||
| 139 | ${QT_CONFIG_FLAGS} | ||
| 140 | |||
| 141 | ### Since we are pointing our host data we need to get them there before compilation | ||
| 142 | if [ ! -e ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/${TARGET_OS}-oe-g++ ]; then | ||
| 143 | cp -rf mkspecs/${TARGET_OS}-oe-g++ ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/${TARGET_OS}-oe-g++ | ||
| 144 | fi | ||
| 145 | ### qmodule.pri and qconfig.pri contain target specific stuff copy them over as well | ||
| 146 | cp -f mkspecs/qmodule.pri ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/qmodule.pri | ||
| 147 | cp -f mkspecs/qconfig.pri ${STAGING_DATADIR}/${QT_DIR_NAME}/mkspecs/qconfig.pri | ||
| 148 | |||
| 149 | ### As we provided the '-dont-process' switch inorder to allow us to stage a few files | ||
| 150 | ### generated by the configure we need to manually run qmake the generate _all_ the Makefiles (-r) | ||
| 151 | ${OE_QMAKE_QMAKE} -r -d | ||
| 152 | } | 76 | } |
| 153 | 77 | ||
| 154 | do_compile() { | 78 | do_compile() { |
| @@ -156,28 +80,13 @@ do_compile() { | |||
| 156 | unset CFLAGS CXXFLAGS AR | 80 | unset CFLAGS CXXFLAGS AR |
| 157 | 81 | ||
| 158 | oe_runmake ${EXTRA_ENV} | 82 | oe_runmake ${EXTRA_ENV} |
| 159 | |||
| 160 | # Build qmake for the target arch | ||
| 161 | cd ${S}/qmake | ||
| 162 | ${OE_QMAKE_QMAKE} | ||
| 163 | oe_runmake CC="${CC}" CXX="${CXX}" | ||
| 164 | cd ${S} | ||
| 165 | } | 83 | } |
| 166 | 84 | ||
| 167 | do_install() { | 85 | do_install() { |
| 168 | oe_runmake install INSTALL_ROOT=${D} | 86 | oe_runmake install INSTALL_ROOT=${D} |
| 169 | |||
| 170 | ### Fix up the binaries to the right location | ||
| 171 | ### TODO: FIX | ||
| 172 | install -d ${D}${bindir}/ | ||
| 173 | mv ${D}/${STAGING_BINDIR_NATIVE}/* ${D}${bindir}/ | ||
| 174 | rm -rf ${D}/${STAGING_BINDIR_NATIVE}/ | ||
| 175 | |||
| 176 | # Install the right arch qmake | ||
| 177 | rm ${D}/${bindir}/qmake | ||
| 178 | install -m 0755 bin/qmake2 ${D}${bindir}/qmake | ||
| 179 | } | 87 | } |
| 180 | 88 | ||
| 89 | PACKAGES .= "${PN}-tools ${PN}-plugins ${PN}-plugins-dbg" | ||
| 181 | FILES_${PN} = "${libdir}/*.so.*" | 90 | FILES_${PN} = "${libdir}/*.so.*" |
| 182 | FILES_${PN}-dbg = "${libdir}/.debug/*.so.*" | 91 | FILES_${PN}-dbg = "${libdir}/.debug/*.so.*" |
| 183 | FILES_${PN}-plugins = "${libdir}/${QT_DIR_NAME}/plugins/*" | 92 | FILES_${PN}-plugins = "${libdir}/${QT_DIR_NAME}/plugins/*" |
