Customize Yocto meta-qt5
-
wrote on 27 Sept 2019, 19:20 last edited by
I'm learning Yocto and I'm trying to customize the
meta-qt5
layer.
I read the docs, but they are very concise.Currently, my only need is very simple: I want to disable some top-level modules. For example I want only:
- qtbase
- qtserialport
- qtserialbus
- qtwebsockets
- qtwebchannel
- qtconnectivity
The link above says:
By default, meta-qt5 enables only a minimal set of features that is available in a Qt module
but I don't understand that. It seems it wants to compile everything!
How can I disable the other top-level modules I don't want to build? -
I'm learning Yocto and I'm trying to customize the
meta-qt5
layer.
I read the docs, but they are very concise.Currently, my only need is very simple: I want to disable some top-level modules. For example I want only:
- qtbase
- qtserialport
- qtserialbus
- qtwebsockets
- qtwebchannel
- qtconnectivity
The link above says:
By default, meta-qt5 enables only a minimal set of features that is available in a Qt module
but I don't understand that. It seems it wants to compile everything!
How can I disable the other top-level modules I don't want to build?It seems it wants to compile everything!
That depends on the build command you give. If you build something, that needs all of Qt, then well, all will be build.
bitbake qtbase
should only build that (plus dependencies).Regards
-
It seems it wants to compile everything!
That depends on the build command you give. If you build something, that needs all of Qt, then well, all will be build.
bitbake qtbase
should only build that (plus dependencies).Regards
wrote on 28 Sept 2019, 05:59 last edited by@aha_1980 I'm using the Distribution Package of ST using the following settings:
DISTRO=openstlinux-eglfs MACHINE=stm32mp1 IMAGE=st-example-image-qt
so I
bitbake st-example-image-qt
that contains themeta-qt5
layer, in theconf/bblayers.conf
:ADDONSLAYERS += "${@'${OEROOT}/layers/meta-qt5' if os.path.isfile('${OEROOT}/layers/meta-qt5/conf/layer.conf') else ''}"
I guess I need to add something below this line to customize the building of the Qt Framework.
Basically I'm trying to understand how to "translate" theconfigure
command into the Yocto syntax. Of course I don't want to mess themeta-qt5
layer. I bet there's a way to do this from the higher level. -
@aha_1980 I'm using the Distribution Package of ST using the following settings:
DISTRO=openstlinux-eglfs MACHINE=stm32mp1 IMAGE=st-example-image-qt
so I
bitbake st-example-image-qt
that contains themeta-qt5
layer, in theconf/bblayers.conf
:ADDONSLAYERS += "${@'${OEROOT}/layers/meta-qt5' if os.path.isfile('${OEROOT}/layers/meta-qt5/conf/layer.conf') else ''}"
I guess I need to add something below this line to customize the building of the Qt Framework.
Basically I'm trying to understand how to "translate" theconfigure
command into the Yocto syntax. Of course I don't want to mess themeta-qt5
layer. I bet there's a way to do this from the higher level.@Mark81 have you actually tried what I wrote?
Adding a layer itself does not force anything to build. but referencing recipes from the layer does.
so if your complete image forces all of Qt, everything will be build. but you can create your own, minimal image.
Regards
-
@Mark81 have you actually tried what I wrote?
Adding a layer itself does not force anything to build. but referencing recipes from the layer does.
so if your complete image forces all of Qt, everything will be build. but you can create your own, minimal image.
Regards
wrote on 30 Sept 2019, 06:23 last edited by@aha_1980 I apologize. Please understand: I didn't try what you suggested because it wasn't what I was looking for. I appreciated a lot your answer because it put me on the right way.
I found the file to configure Qt5:
layers/meta-st/meta-st-openstlinux/recipes-samples/images/st-example-image-qt.bb
inside it defines what to build, example:
# QT part Essentials IMAGE_QT_MANDATORY_PART = " \ qtbase \ liberation-fonts \ qtbase-plugins \ qtbase-tools \ qtdeclarative \ qtdeclarative-qmlplugins\ qtdeclarative-tools \ qtgraphicaleffects-qmlplugins \ qtmultimedia \ qtmultimedia-plugins \ qtmultimedia-qmlplugins \ qtscript \ openstlinux-qt-eglfs \ " # QT part add-ons IMAGE_QT_OPTIONAL_PART = " \ qtserialport \ "
1/5