Priority: P2: Important
Affects Version/s: Qt Creator 4.15.0
Component/s: Android Support
Steps to reproduce
1) Clone qtscxml repository: git clone git://code.qt.io/qt/qtscxml.git
2) Open the qtscxml toplevel CMakeLists.txt in QtCreator, select Android kit (arm & debug build in my case).
3) Enable building of examples (Projects tab => Build pane => set QT_BUILD_EXAMPLES=ON) and hit “Apply configuration changes” button below.
4) Select an example on the Projects => Run => Run Configuration. For example “pinball” or whatever, as long a plugin is not selected (see later).
5) Click “build” button and build.
6) At the end of the build (after 100%) there is an error:
This is the error this bug is about. There are two related behaviours into this error, depending on the action on step #4 above.
- If an executable application is selected in the “Run configuration”, the real .json file can be found and the hack / workaround below can be done.
- If a plugin is selected, the build directory will not contain a .json file that would work.
The error message comes from androiddeployqt, it tries to find "architectures" keyword from a .json file, but it contains a "target-architecture" keyword instead. By grepping qt-creator source, which creates these .json files, this is not wrong per se - it generates .json files with 2 different keywords. I did not investigate why, but I assume it is as it should.
All in all since the real .json files are there, I think they are just looked up from the wrong place.
The dirty workaround / hack
Open terminal and go to the build directory of the project and copy all android deployment .json files to root of the build folder:
Then go back to QtCreator and build again => no error.