Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. QT 6.4.1 Android Installing the app failed with an unknown error.
Forum Updated to NodeBB v4.3 + New Features

QT 6.4.1 Android Installing the app failed with an unknown error.

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
7 Posts 6 Posters 4.4k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    cyniu88
    wrote on last edited by
    #1

    When compiling / installing a sample Android application (QT Creator 9, new instalation) I get this error:

    Skipping createRCC
    adb: failed to install C:/Qt/Examples/Qt-6.4.1/quickcontrols2/build-gallery-Android_Qt_6_4_1_Clang_x86_64-Release/android-build//build/outputs/apk/release/android-build-release-unsigned.apk: Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from /data/app/vmdl686382759.tmp/base.apk: Attempt to get length of null array]
    Installing Android package to device.
    Running command "C:/Users/cyniu/AppData/Local/Android/Sdk/platform-tools/adb.exe -s emulator-5554 install -r C:/Qt/Examples/Qt-6.4.1/quickcontrols2/build-gallery-Android_Qt_6_4_1_Clang_x86_64-Release/android-build//build/outputs/apk/release/android-build-release-unsigned.apk"
    Performing Streamed Install
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Windows
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.macOS
    Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.iOS
    Installing to device failed!
    14:22:13: Proces "C:\Qt\6.4.1\mingw_64\bin\androiddeployqt.exe" finished the job with the output code 16.
    14:22:13: Installing the app failed with an unknown error.
    14:22:13: Pulling files necessary for debugging.

    how to fix it ?

    1 Reply Last reply
    0
    • AninossA Offline
      AninossA Offline
      Aninoss
      wrote on last edited by
      #2

      The same problem after installing QT 6.4.1 this problem show up

      :-1: warning: 
      Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.Windows
      Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.macOS
      Warning: QML import could not be resolved in any of the import paths: QtQuick.Controls.iOS
      Import found outside of import paths: C:/Users/Aninoss/Documents/Programming/Qt/Android Test/gallery/gallery.qml.
      
      1 Reply Last reply
      0
      • TomZT Offline
        TomZT Offline
        TomZ
        wrote on last edited by
        #3

        My go-to solution has been to create a signed APK (using androiddeployqt), copy it manually to the device and install it from the file-app.
        Works just fine.

        But its needed to sign the apk, a simple self-signed keystore is no problem there. I even pushed that keystore to my public git repo (will not use that for actual releases obviously) to make it easy for everyone.
        If I didn't sign the apk, I just got a weird error like "install failed" in the Android interface.

        mzimmersM 1 Reply Last reply
        1
        • TomZT TomZ

          My go-to solution has been to create a signed APK (using androiddeployqt), copy it manually to the device and install it from the file-app.
          Works just fine.

          But its needed to sign the apk, a simple self-signed keystore is no problem there. I even pushed that keystore to my public git repo (will not use that for actual releases obviously) to make it easy for everyone.
          If I didn't sign the apk, I just got a weird error like "install failed" in the Android interface.

          mzimmersM Offline
          mzimmersM Offline
          mzimmers
          wrote on last edited by mzimmers
          #4

          @TomZ this problem just appeared for me as well. What's interesting is that I had been able to start my app on an emulator, but now get this error. I never had to use androiddeployqt to get it to work.

          errors.PNG

          Any suggestions on what to look at?

          Thanks...

          TomZT 1 Reply Last reply
          0
          • mzimmersM mzimmers

            @TomZ this problem just appeared for me as well. What's interesting is that I had been able to start my app on an emulator, but now get this error. I never had to use androiddeployqt to get it to work.

            errors.PNG

            Any suggestions on what to look at?

            Thanks...

            TomZT Offline
            TomZT Offline
            TomZ
            wrote on last edited by
            #5

            @mzimmers said in QT 6.4.1 Android Installing the app failed with an unknown error.:

            I never had to use androiddeployqt to get it to work.

            Thats run by QtCreator (well, really by cmake) under the covers. You won't notice. The point to the original poster is that you can sidestep the auto-deploy-to-device and just copy the apk and install it. Provided you sign it.

            That helps a lot with debugging and figuring out which part fails.

            1 Reply Last reply
            1
            • O Offline
              O Offline
              ovzap
              wrote on last edited by
              #6

              Actually for me helps signing the apk:
              go to: Projects|Build Settings|Build Android APK|Application Signature
              To create "android_release.keystore" push the button: Create
              After creating and choice the Keystore, check "Sign package".
              Enjoy.

              1 Reply Last reply
              2
              • mzimmersM Offline
                mzimmersM Offline
                mzimmers
                wrote on last edited by
                #7

                Thanks, guys - when I posted that, I didn't realize that I had to re-check the sign box every time I build. Your suggestions were the fix.

                1 Reply Last reply
                0
                • Z ZINE referenced this topic on

                • Login

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • Users
                • Groups
                • Search
                • Get Qt Extensions
                • Unsolved