Warning: Android platform 'android-20' does not exist in NDK. in Qt



  • Hi everyone
    i wrote a application in android in Qt 5.3.1 . i used SDK 20 ,NDK r10 , i set all configurations.
    but now after compiling :

    *_Warning: Android platform 'android-20' does not exist in NDK.
    _Building the android package failed!
    -- For more information, run this command with --verbose.
    09:57:00: The process "C:\Qt\Qt5.3.1\5.3\android_armv7\bin\androiddeployqt.exe" exited with code 14.
    Error while building/deploying project digitalclock (kit: Android for armeabi-v7a (GCC 4.8, Qt 5.3.1))
    When executing step 'Deploy to Android device'

    That s right but i check may NDK pack . no android-20 .i check all available ndk on android site but all of them have android-19.
    SO HELP What i must DOOOOO???


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    Did you try to update the NDK content to ensure you have the latest stuff installed ?



  • What I think is the same setup seemed to build (at least) when I installed API 20 using Android SDK Manager and created an AVD that uses API 20. Despite that there is no directory android-ndk-r10/platforms/api-20.

    But my app (helloAndroid using PyQt and pyqtdeploy) crashed. Then I uninstalled API 20 from the SDK and installed API 19 using the Android SDK Manager and created an AVD that uses API 19. Then I get the same error as above. So I would suggest you install API 20 and create an AVD using API 20.

    I don't understand why Qt Creator wants to build for API 20 (how to configure Qt Creator to build for a different API.) I suppose it must be in a spec file?

    SGaist: I don't know what you mean by update the ndk content. Android SDK Manager will update the sdk content, but I can't find any notion of updating the ndk (unless you mean download another release, but I think r10 is the latest, I just downloaded it a week ago. Its probably moot if what you mean is to install API 20 in the sdk.

    (I don't really care which API Qt Creator uses, if it works. I was only experimenting with API 19 to see if my app would not crash. Now I am building Qt for Android to turn debugging on and to harness Qt code so I can see where my app is crashing. It seems to crash before the debugger can get started properly. The Qt platform plugin process dies, after it logs 'qt start'. But thats another problem.)



  • With only API 19 installed, I still get:

    @16:15:00: Package deploy: Running command '/home/bootch/android-sdk-linux/platform-tools/adb -s emulator-5554 pull /system/lib/libc.so /home/bootch/helloBuild/build-hello-plain/libc.so'.
    Warning: Android platform 'android-20' does not exist in NDK.
    Error: Target id 'android-20' is not valid. Use 'android list targets' to get the target ids.@

    I don't understand where libc.so is coming from. It doesn't seem to be compiled during the build. Maybe Qt Creator is copying it from somewhere, and it is built for API 20, adb knows that, and complains?



  • Hi,

    I had a similar problem and I suppose that is the same cause. I explain that I did and how solved.

    • I installed API 14.
    • Created the Android Project.
    • Upgraded the API 14 to API 15 (uninstalled API 14 and installed API 15).

    After that, gave me this error:

    Warning: Android platform 'android-14' does not exist in NDK.
    Error: Target id 'android-14' is not valid

    and not run.

    The reason is that when creates the APK package, it passes the android-14 parameter.

    The solution:

    • Goto Projects
    • On Build Settings \ Build Steps \ Build Android APK select Details.
    • Exists a property named "Android build SDK:". Select on the combobox the apropiate platform, in my case android-15, and I suppose that in your case android-19


  • Hi,

    I had a similar problem and I suppose that is the same cause. I explain that I did and how solved.

    • I installed API 14.
    • Created the Android Project.
    • Upgraded the API 14 to API 15 (uninstalled API 14 and installed API 15).

    After that, gave me this error:

    Warning: Android platform 'android-14' does not exist in NDK.
    Error: Target id 'android-14' is not valid

    and not run.

    The reason is that when creates the APK package, it passes the android-14 parameter.

    The solution:

    • Goto Projects
    • On Build Settings \ Build Steps \ Build Android APK select Details.
    • Exists a property named "Android build SDK:". Select on the combobox the apropiate platform, in my case android-15, and I suppose that in your case android-19

Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.