[Qt-creator] Problem with Android SDK tools and platform SDK

Harri Pasanen harri at mpaja.com
Sun Apr 12 19:21:55 CEST 2020


Hi again,

Qt 5.14.2 does work in the end, after fixing the tools and SDK
configuration as described before.

It just defaults to building armeabi-v7a only.  One has to go to project
setting, android build steps for Qmake, and tick x86 ABI checkbox on to run
in the emulator.
It is not obvious how to make it work, even if it is simple in the end.

As the connected devices architecture should be known, it would be user
friendly to automatically build for those, or default to all if in doubt.

Taking an old Android project that builds with Qt 5.13.1, It still does not
build out of the box with 5.14.2.  It seems
 like old AndroidManifest.xml will need something tweaked, Gradle complains
about deprecated features being used, and fails:

AndroidManifest.xml:16:13-120: AAPT: error: resource array/bundled_in_lib
(aka com.mpaja.stoppola:array/bundled_in_lib) not found.
AndroidManifest.xml:17:13-126: AAPT: error: resource
array/bundled_in_assets (aka com.mpaja.stoppola:array/bundled_in_assets)
not found.


Now I need to find out how to upgrade the AndroidManifest.xml


Anyway, looking quite promising.


Thanks,

Harri






On Sun, Apr 12, 2020 at 9:28 AM Harri Pasanen <harri at mpaja.com> wrote:

> This looks like https://bugreports.qt.io/browse/QTCREATORBUG-23726 to me.
> Using Filip's workaround from the ticket made it work for me with Qt
> Creator 4.10.0 packaged with Qt 5.13.1.
> I can run examples and deploy to emulator and devices with it.
>
> But for some reason QtCreator 4.11.1 from Qt 5.14.2 failed elsewhere, when
> deploying to device, neither emulator nor actual device worked:
>
> adb: failed to install
> /home/harri/Qt5.14.2/Examples/Qt-5.14.2/quick/build-animation-Android_for_armeabi_v7a_arm64_v8a_x86_x86_64_Clang_Qt_5_14_2_for_Android-Debug/android-build//build/outputs/apk/debug/android-build-debug.apk:
> Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native
> libraries, res=-113]
>
> Installing Android package to device.
>
> Running command "/home/harri/Android/Sdk/platform-tools/adb -s
> emulator-5554 install -r
> /home/harri/Qt5.14.2/Examples/Qt-5.14.2/quick/build-animation-Android_for_armeabi_v7a_arm64_v8a_x86_x86_64_Clang_Qt_5_14_2_for_Android-Debug/android-build//build/outputs/apk/debug/android-build-debug.apk"
>
> Performing Streamed Install
>
> Installing to device failed!
>
> So all of android chain in Qt 5.14.2 seems to need some quality control
> work.
>
> Thanks,
> Harri
>
>
>
>
>
>
>
>
> On Sat, Apr 11, 2020 at 3:30 PM Christian Gagneraud <chgans at gmail.com>
> wrote:
>
>> On Sat, 11 Apr 2020 at 00:15, Assam Boudjelthia <assam.boudjelthia at qt.io>
>> wrote:
>> > Hi Christian,
>> > > I never had this problem with previous installs of Qt & Android.
>> >
>> > Looking at this it seems that Android SDK introduced a new packages
>> "cmdline-tools" which offers the same as the old package "tools" and Qt
>> Creator is looking for "tools" package. So QC would need a fix for this.
>> Meanwhile, I suggest installing the package "tools" if it's still available
>> from the sdkmanager and make sure you have the SDK tools directory under
>> <sdkPath>/tools which has sdkmanager and avdmanager tools.
>>
>> cd $SDK
>> ln -s cmdline-tools/latest tools
>> solves the 'SDK tools installed' problem
>>
>> cd cmdline-tools/latest
>> cp -a ../../platform-tools/* .
>> solves the 'Plaform SDK installed' one.
>>
>> I guess this is a quick and dirty workaround, using SDK manager via
>> QtC will unlikely be reliable.
>>
>> Any chance this will be fixed with next QtC release (minor or patch).
>> Should i open a bug report?
>>
>> Chris
>> _______________________________________________
>> Qt-creator mailing list
>> Qt-creator at qt-project.org
>> https://lists.qt-project.org/listinfo/qt-creator
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/qt-creator/attachments/20200412/cebbd83e/attachment.html>


More information about the Qt-creator mailing list