[Qbs] QML import issue on iOS

Fabian Kosmale fabian.kosmale at qt.io
Thu Jun 23 10:13:03 CEST 2022


Hi,

the short answer is "does not work". The long answer is that  currently, Qt
relies on qmlimportscanner to figure out dependencies for deployent, and that
one only considers QML files.

In theory, we could use a smarter approach: A proper QML module has a qmldir
file, and that one can use a depends entry [0] to tell tooling that there is in
fact a dependency on some other module, even if that dependency is not visible
in any QML file.
There are some ideas to improve the situation when using CMake to actually make
use of that information, but that is currently merely at the brainstorming
stage.  The QBS project could of course start creating their own approach of
handling this; though I'm not sure if that would make sense at this stage.

Also, none of that would help if you use a QML library which is a "degenerate"
module (one wtih no qmldir file).


Hope that answers your question.

Fabian

[0]: https://doc.qt.io/qt-6/qtqml-modules-qmldir.html


More information about the Qbs mailing list