[oe] building and running a qt5 application
Trevor Woerner
trevor.woerner at linaro.org
Fri Aug 16 04:13:15 UTC 2013
Hi,
I am trying to build and run a simple qt5 example:
http://qt-project.org/doc/qt-5.0/qtuitools/textfinder.html
The first interesting thing that I come across is that the qt5 header
files in the sysroot are located in:
${PKG_CONFIG_SYSROOT_DIR}/usr/include/qt5
but when the build system configures itself to build the qt5
application, it uses a bunch of include directories such as:
${PKG_CONFIG_SYSROOT_DIR}/usr/include/QtCore
${PKG_CONFIG_SYSROOT_DIR}/usr/include/QtGui
${PKG_CONFIG_SYSROOT_DIR}/usr/include/QtWidgets
Therefore any recipe that wants to build a qt5 application is forced
to either modify the CXXFLAGS variable or say:
OE_QMAKE_PATH_HEADERS = "${OE_QMAKE_PATH_QT_HEADERS}"
If the build system knows it's going to be putting the qt5 header
files in $sysroot/usr/include/qt5/etc, why not simply use that instead
of requiring the users to update the include paths themselves in all
their recipes?
Secondly, I added both "qtbase" and my package to IMAGE_INSTALL, added
the "meta-qt5" layer to "bblayers.conf", specified "QT5_VERSION" as
"5.0.2", and then built:
$ bitbake core-image-x11
When I tried to run my application I received:
Failed to load platform plugin "xcb". Available platforms are:
Aborted
Shouldn't an x11 image have included the xcb platform?
Any tips on building and running a simple qt5 application in a
yocto-based image?
Best regards,
Trevor
More information about the Openembedded-devel
mailing list