QtCharts cross-compile for ARM
-
Hello everybody,
I would like to use the qtcharts library for my Gumstix Overo with Yocto Rocko platform.
I work with a Ubuntu 16.04 virtual machin and I have installed all tools to cross-compile a Qt5 application from the virtual machin to the Gumstix Overo with QtCreator.
Unfortunately I really need to use the qtcharts and when I try to cross-compile the code that produce an error:
Unknown module(s) in QT:charts
I think that is because the qtcharts is not compiled for my Yocot distribution and so I need to cross-compile it like it's describe there.
I do that:
$ sudo /opt/poky/2.4.3/sysroot/x86_64-pokysdk-linux/usr/bin/qt5/qmake /usr/lib/x86_65-linux-gnu/Qt5.9.5/5.9.5/Src/qtchats
The result is that:
/opt/poky/2.4.3/sysroot/cortexa8hf-neon-poky-linux-gnueabi/usr/lib/qt5/mkspecs/features/resolve_config.prf:25 'addExclusiveBuilds' is not a recognized test function.
/opt/poky/2.4.3/sysroot/cortexa8hf-neon-poky-linux-gnueabi/usr/lib/qt5/mkspecs/features/resolve_config.prf:37 'addExclusiveBuilds' is not a recognized test function.
If I still do the
make
I have multiple failed and Error.....My question is how can I use qtcharts on my Gumstix Overo with Yocto Rocko ?
Thanks for your attention.
Regards. -
@falcon1990 which version of Qt are you using in Yocto?
-
@aha_1980 Hello and thanks for your answer.
I don't know which version it is because I use 3 files to do the bootable SD card from there.
MLO ; u-boot.img ; tar.bz2
.
There is no informations about the version and in the distribution there is no "qmake", juste the compiled library.
I just know is qt5....Maybe you know how I can give you this information ?
Thanks a lot.
Regards. -
Based on title
yocto-overo-rocko-2018-06-12-qt5
it's probably yocto-rocko release. By default in rocko release Qt was in 5.9 version. Anyway in standard yocto-rocko builds withmeta-qt5
layer inside there is no QtCharts module added to sdk or image by default. You need to add it by yourself durning generating sdk or image, or build it after using previously generated sdk. -
@tomasz3dk Hello and thanks for your answer.
I download the image from there so I can't modify them, juste use it.
I also try to build my own Yocto version like this but the image generated doesn't contain any Qt5 library. I can just use the cross-compiler with QtCreator.
I thought as I have the cross-compiler for the ARM cortex (Gumstix Overo) I can manually compile the qtcharts library and transfert the folder into it.The solution is to build an Yocto version that is contain the qtcharts library ?
If yes, how can I do that, because as I said, I already try it...Thanks a lot.
Regards. -
the error you posted earlier just looks as if the Qt version does not fit the QtCharts version. otherwise cross-compiling charts should be just fine.
-
Like @aha_1980 wrote cross-compilling proper version of QtCharts should be fine with yocto sdk. Another but much more complicated option is to build new image and sdk with yocto.
-
@aha_1980 @tomasz3dk Ok fine so as I ask at the begining of this topic, what did I do wrong when I cross-compile the qtcharts library from Ubuntu to Yocto ?
Thanks for your both answers. -
the error you posted earlier just looks as if the Qt version does not fit the QtCharts version.
-
@aha_1980 -_-' yes that the point you right.
If I rightly understand you I have 2 options:- Ask Gumstiox to build a version with qtcharts.
- Build my own Yocto distribution with Qt, qtcharts and compatible with the Gumstix Overo.
The first option will be not works so how can I do the second option ?
Can you help me for that too ?Thanks a lot :)
Regards. -
sorry, I did not see your answer earlier.
You have option 3 for the beginning: compile QtCharts against Gumstix' Qt ( without Yocto, just using the toolchain).
you have to investigate which Qt version they are using und then find a suitable QtCharts for that.
In the long run, you will of course build your own image.
(and sorry, I cannot help much here, my Yocto knowledge is limited)
-
sorry, I did not see your answer earlier.
No problem, thanks for your answer.
As I said and if I understand you, I already try to cross-compile the library QtCharts with the toolchain (my first message):
I do that:
$ sudo /opt/poky/2.4.3/sysroot/x86_64-pokysdk-linux/usr/bin/qt5/qmake /usr/lib/x86_65-linux-gnu/Qt5.9.5/5.9.5/Src/qtchats
The result is that:
/opt/poky/2.4.3/sysroot/cortexa8hf-neon-poky-linux-gnueabi/usr/lib/qt5/mkspecs/features/resolve_config.prf:25 'addExclusiveBuilds' is not a recognized test function.
/opt/poky/2.4.3/sysroot/cortexa8hf-neon-poky-linux-gnueabi/usr/lib/qt5/mkspecs/features/resolve_config.prf:37 'addExclusiveBuilds' is not a recognized test function.
If I still do the make I have multiple failed and Error.....But that didn't works.
Maybe you know where I can ask my question because the Gumstix support is useless.
Thank you one more time !
Regards. -
@falcon1990 hi,
the only advice i have: find out which Qt version Gumstix is using, and search for a fitting charts version.
or build everything yourself.
regards