Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. Testing Android APK with QtCreator fails with an error.
Forum Updated to NodeBB v4.3 + New Features

Testing Android APK with QtCreator fails with an error.

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
34 Posts 5 Posters 961 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.
  • SMF-QtS SMF-Qt

    @jsulm

    I could but I think this is a build issue, I think I need to find out more about this "app_process" file that is missing.
    I ran strace on qtcreator and re-built the app and the only reference to "app_process" is a test for its existance which failed:

    access("/work/Qt-Android/QtTest-V1.1.5c/application/build/Android_QtAndroid_Clang_arm64_v8a-Debug/android-app-process/app_process", F_OK) = -1 ENOENT (No such file or directory)

    SMF-QtS Offline
    SMF-QtS Offline
    SMF-Qt
    wrote last edited by
    #25

    @SMF-Qt

    According to Googles AI:

    1. What is app_process?

      app_process is a binary found in the /system/bin directory on Android devices. According to Stack Overflow, it's a device binary created by the full device build.

    It's the entry point for starting a Java process within the Android runtime environment.
    It's used to run applications, often those that need to interact with system-level services or bypass normal Android application lifecycle restrictions.
    It can be used to execute JAR files or DEX files within a Dalvik/ART environment.
    Essentially, it's how you can run custom Java code as a separate process on an Android device, outside the typical app sandbox.

    SMF-QtS 1 Reply Last reply
    1
    • SMF-QtS SMF-Qt

      @SMF-Qt

      According to Googles AI:

      1. What is app_process?

        app_process is a binary found in the /system/bin directory on Android devices. According to Stack Overflow, it's a device binary created by the full device build.

      It's the entry point for starting a Java process within the Android runtime environment.
      It's used to run applications, often those that need to interact with system-level services or bypass normal Android application lifecycle restrictions.
      It can be used to execute JAR files or DEX files within a Dalvik/ART environment.
      Essentially, it's how you can run custom Java code as a separate process on an Android device, outside the typical app sandbox.

      SMF-QtS Offline
      SMF-QtS Offline
      SMF-Qt
      wrote last edited by
      #26

      @SMF-Qt

      So if I understand what adb and google are telling me the issue is that the operating system on my test phone is blocking adb's access to /system/bin/.

      I wonder if this is a Samsung thing the test phone is a Samsung A06 ?

      SMF-QtS 1 Reply Last reply
      0
      • SMF-QtS SMF-Qt

        @SMF-Qt

        So if I understand what adb and google are telling me the issue is that the operating system on my test phone is blocking adb's access to /system/bin/.

        I wonder if this is a Samsung thing the test phone is a Samsung A06 ?

        SMF-QtS Offline
        SMF-QtS Offline
        SMF-Qt
        wrote last edited by SMF-Qt
        #27

        @SMF-Qt

        Using adb shell I have found the adbd server on my test phone:

        shell 26668 1 0 40:23 ? 00:04:49 adbd --root_seclabel=u:r:su:s0 --tim_seclabel=u:r:adbd_tradeinmode:s0

        It is running as user shell which I think does not have read access to /system/bin.

        So I think my next step is to root the Test Phone and see if that helps.

        1 Reply Last reply
        0
        • cristian-adamC Offline
          cristian-adamC Offline
          cristian-adam
          wrote last edited by
          #28

          The adb: error: failed to copy '/system/bin/app_process64' is something new with Android 15.

          I have started seeing this issue with my Samsung Galaxy S23 with Android 15.

          See this other report at https://forum.qt.io/topic/162537/qt-creator-android-15-adb.exe-pull-system-bin-app_process64-error

          In my case native debugging with Android Studio doesn't work with the Galaxy S23. It does work with the Arm64 Emulator with Android 15.

          I tested with a Samsung Galaxy S10e with Android 12, and everything worked fine with Qt Creator 17...

          SMF-QtS 1 Reply Last reply
          0
          • cristian-adamC cristian-adam

            The adb: error: failed to copy '/system/bin/app_process64' is something new with Android 15.

            I have started seeing this issue with my Samsung Galaxy S23 with Android 15.

            See this other report at https://forum.qt.io/topic/162537/qt-creator-android-15-adb.exe-pull-system-bin-app_process64-error

            In my case native debugging with Android Studio doesn't work with the Galaxy S23. It does work with the Arm64 Emulator with Android 15.

            I tested with a Samsung Galaxy S10e with Android 12, and everything worked fine with Qt Creator 17...

            SMF-QtS Offline
            SMF-QtS Offline
            SMF-Qt
            wrote last edited by
            #29

            @cristian-adam

            Thanks for the info, the Samsung A06 I am currently using has Android 14 currently installed.

            SMF-QtS 1 Reply Last reply
            0
            • SMF-QtS SMF-Qt

              @cristian-adam

              Thanks for the info, the Samsung A06 I am currently using has Android 14 currently installed.

              SMF-QtS Offline
              SMF-QtS Offline
              SMF-Qt
              wrote last edited by
              #30

              @SMF-Qt

              I did not make any progress rooting my Test Phone (Samsung A06), however I tried an old HTC M9 running Android 7.0 and that did proceed past the adb pull request for "app_process" but failed because the APK package is too new for Android 7.0 (expected failure).

              cristian-adamC 1 Reply Last reply
              0
              • SMF-QtS SMF-Qt

                @SMF-Qt

                I did not make any progress rooting my Test Phone (Samsung A06), however I tried an old HTC M9 running Android 7.0 and that did proceed past the adb pull request for "app_process" but failed because the APK package is too new for Android 7.0 (expected failure).

                cristian-adamC Offline
                cristian-adamC Offline
                cristian-adam
                wrote last edited by
                #31

                @SMF-Qt said in Testing Android APK with QtCreator fails with an error.:

                I did not make any progress rooting my Test Phone (Samsung A06), however I tried an old HTC M9 running Android 7.0 and that did proceed past the adb pull request for "app_process" but failed because the APK package is too new for Android 7.0 (expected failure).

                Android 9 is the minimum required for Qt for Android 6.9.

                According to Wikipedia you can get Android 11 for HTC One M9. The steps to do this unofficial upgrade are listed here. I have no idea how this would work.

                1 Reply Last reply
                0
                • SMF-QtS Offline
                  SMF-QtS Offline
                  SMF-Qt
                  wrote last edited by SMF-Qt
                  #32

                  I think for now I am going to put arm64-v8a activities on hold as both hardware and emulated deployments have issues and try jsulm's suggestion of an X86_64 setup. I have already tested the X86_64 phone simulator outside of both qtcreator and Android Studio and it appears to function ok.

                  SMF-QtS 1 Reply Last reply
                  0
                  • SMF-QtS SMF-Qt

                    I think for now I am going to put arm64-v8a activities on hold as both hardware and emulated deployments have issues and try jsulm's suggestion of an X86_64 setup. I have already tested the X86_64 phone simulator outside of both qtcreator and Android Studio and it appears to function ok.

                    SMF-QtS Offline
                    SMF-QtS Offline
                    SMF-Qt
                    wrote last edited by
                    #33

                    @SMF-Qt

                    Ok thanks for the suggestions I now have a working X86_64 emulator and an X86_64 apk build that deploys to the emulated phone.

                    My next problem is that the deployed app crashes on startup, but to investigate that I think I will start a new thread and come back to the arm64-v8a problems when my test application is more usable.

                    ...
                    Installing Android package to device.
                    Running command "/opt/android/sdk/platform-tools/adb -s emulator-5554 install -r /work/Qt-Android/QtTest/application/build/Android_Qt_6_9_1_qt_androidX86_Clang_x86_64-Debug/android-build//build/outputs/apk/debug/android-build-debug.apk"
                    Performing Streamed Install
                    Success
                    Android package built successfully in 0.572 ms.
                    -- It can now be run from the selected device/emulator.
                    -- File: /work/Qt-Android/QtTest/application/build/Android_Qt_6_9_1_qt_androidX86_Clang_x86_64-Debug/android-build//build/outputs/apk/debug/android-build-debug.apk
                    14:18:06: The process "/opt/qt6/bin/androiddeployqt" exited normally.
                    14:18:06: Package deploy: Running command "/opt/android/sdk/platform-tools/adb -s emulator-5554 pull /system/bin/app_process64 /work/Qt-Android/QtTest/application/build/Android_Qt_6_9_1_qt_androidX86_Clang_x86_64-Debug/android-app-process/app_process".
                    14:18:06: Package deploy: Running command "/opt/android/sdk/platform-tools/adb -s emulator-5554 pull /system/bin/linker64 /work/Qt-Android/QtTest/application/build/Android_Qt_6_9_1_qt_androidX86_Clang_x86_64-Debug/android-app-process/linker64".
                    14:18:06: Package deploy: Running command "/opt/android/sdk/platform-tools/adb -s emulator-5554 pull /system/lib64/libc.so /work/Qt-Android/QtTest/application/build/Android_Qt_6_9_1_qt_androidX86_Clang_x86_64-Debug/android-app-process/libc.so".
                    14:18:06: Elapsed time: 00:05.

                    1 Reply Last reply
                    0
                    • SMF-QtS SMF-Qt referenced this topic
                    • D Offline
                      D Offline
                      danish777
                      wrote last edited by
                      #34

                      Thanks for sharing the detailed steps — it looks like you're almost there. The error about the missing ABI usually means QtCreator isn’t detecting the correct architecture for deployment. Adding ```
                      ANDROID_ABIS = arm64-v8a

                      
                      Double-check that the Kit you're using is actually set up with the correct Qt for Android version and the appropriate architecture. Also, make sure the NDK path is correctly configured in the SDK settings — mismatches there can silently cause issues like this.
                      
                      Running on an emulator first is definitely a smart move. Hopefully with those tweaks, you'll be able to deploy without issues. Let us know how it goes!
                      1 Reply Last reply
                      0

                      • Login

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