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 5.14.2: Android application crashed. Why?

Qt 5.14.2: Android application crashed. Why?

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
6 Posts 2 Posters 1.3k Views
  • 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.
  • B Offline
    B Offline
    bogong
    wrote on last edited by bogong
    #1

    Hello all!
    I've got this error on Qt Android application:

    W/System.err(24004): java.lang.Exception:
    W/System.err(24004): 	at org.qtproject.qt5.android.bindings.QtLoader.loadApplication(QtLoader.java:268)
    W/System.err(24004): 	at org.qtproject.qt5.android.bindings.QtLoader.startApp(QtLoader.java:505)
    W/System.err(24004): 	at org.qtproject.qt5.android.bindings.QtActivityLoader.onCreate(QtActivityLoader.java:166)
    W/System.err(24004): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreateHook(QtActivity.java:266)
    W/System.err(24004): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreate(QtActivity.java:273)
    W/System.err(24004): 	at android.app.Activity.performCreate(Activity.java:6147)
    W/System.err(24004): 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1112)
    W/System.err(24004): 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2498)
    W/System.err(24004): 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2625)
    W/System.err(24004): 	at android.app.ActivityThread.access$700(ActivityThread.java:183)
    W/System.err(24004): 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1484)
    W/System.err(24004): 	at android.os.Handler.dispatchMessage(Handler.java:111)
    W/System.err(24004): 	at android.os.Looper.loop(Looper.java:194)
    W/System.err(24004): 	at android.app.ActivityThread.main(ActivityThread.java:5667)
    W/System.err(24004): 	at java.lang.reflect.Method.invoke(Native Method)
    W/System.err(24004): 	at java.lang.reflect.Method.invoke(Method.java:372)
    W/System.err(24004): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:962)
    W/System.err(24004): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)
    

    It's perfectly working on iOS and MacOS but crashed on Android. Why? Is it next of Qt Android bugs?
    I ma running it on Qt 5.14.2 on MacOS.

    1 Reply Last reply
    0
    • sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      Have you used this app on Android in Qt < 5.14? If yes, then you need to regenerate your templates. Backup and remove your android dir (from your project), then in Qt Creator go to Project->Build->Build Android APK->Create Templates. Do a full rebuild and try if that works. If yes, then you can adjust your Android manifest etc. to match your old config.

      (Z(:^

      B 1 Reply Last reply
      1
      • sierdzioS sierdzio

        Have you used this app on Android in Qt < 5.14? If yes, then you need to regenerate your templates. Backup and remove your android dir (from your project), then in Qt Creator go to Project->Build->Build Android APK->Create Templates. Do a full rebuild and try if that works. If yes, then you can adjust your Android manifest etc. to match your old config.

        B Offline
        B Offline
        bogong
        wrote on last edited by bogong
        #3

        @sierdzio I have list of prototyped applications that is using by me like test pool for Qt, it's about 20 applications. They have been developing for older Qt versions. Thx, updated all files from scratch. It's working now. But not Qt Test application. When run tests I have this

        E/art     (24318): No implementation found for int[] org.qtproject.qt5.android.ExtractStyle.extractNativeChunkInfo20(long) (tried Java_org_qtproject_qt5_android_ExtractStyle_extractNativeChunkInfo20 and Java_org_qtproject_qt5_android_ExtractStyle_extractNativeChunkInfo20__J)
        W/System.err(24318): java.lang.reflect.InvocationTargetException
        W/System.err(24318): 	at java.lang.reflect.Method.invoke(Native Method)
        W/System.err(24318): 	at java.lang.reflect.Method.invoke(Method.java:372)
        W/System.err(24318): 	at org.qtproject.qt5.android.bindings.QtLoader.loadApplication(QtLoader.java:267)
        W/System.err(24318): 	at org.qtproject.qt5.android.bindings.QtLoader.startApp(QtLoader.java:505)
        W/System.err(24318): 	at org.qtproject.qt5.android.bindings.QtActivityLoader.onCreate(QtActivityLoader.java:166)
        W/System.err(24318): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreateHook(QtActivity.java:266)
        W/System.err(24318): 	at org.qtproject.qt5.android.bindings.QtActivity.onCreate(QtActivity.java:273)
        W/System.err(24318): 	at android.app.Activity.performCreate(Activity.java:6147)
        W/System.err(24318): 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1112)
        W/System.err(24318): 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2498)
        W/System.err(24318): 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2625)
        W/System.err(24318): 	at android.app.ActivityThread.access$700(ActivityThread.java:183)
        W/System.err(24318): 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1484)
        W/System.err(24318): 	at android.os.Handler.dispatchMessage(Handler.java:111)
        W/System.err(24318): 	at android.os.Looper.loop(Looper.java:194)
        W/System.err(24318): 	at android.app.ActivityThread.main(ActivityThread.java:5667)
        W/System.err(24318): 	at java.lang.reflect.Method.invoke(Native Method)
        W/System.err(24318): 	at java.lang.reflect.Method.invoke(Method.java:372)
        W/System.err(24318): 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:962)
        W/System.err(24318): 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:757)
        W/System.err(24318): Caused by: java.lang.UnsatisfiedLinkError: No implementation found for int[] org.qtproject.qt5.android.ExtractStyle.extractNativeChunkInfo20(long) (tried Java_org_qtproject_qt5_android_ExtractStyle_extractNativeChunkInfo20 and Java_org_qtproject_qt5_android_ExtractStyle_extractNativeChunkInfo20__J)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.extractNativeChunkInfo20(Native Method)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.findPatchesMarings(ExtractStyle.java:796)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.getDrawable(ExtractStyle.java:1130)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.extractViewInformations(ExtractStyle.java:1234)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.extractTextAppearanceInformations(ExtractStyle.java:1327)
        W/System.err(24318): 	at org.qtproject.qt5.android.ExtractStyle.<init>(ExtractStyle.java:2003)
        W/System.err(24318): 	at org.qtproject.qt5.android.QtActivityDelegate.loadApplication(QtActivityDelegate.java:614)
        W/System.err(24318): 	... 20 more
        

        Why is that?

        1 Reply Last reply
        0
        • sierdzioS Offline
          sierdzioS Offline
          sierdzio
          Moderators
          wrote on last edited by
          #4

          Hm I think I've seen it but I don't remember how I solved it. I think I had to tweak the API level (NDK, SDK minimal or target), but not sure.

          That's Qt for Android in a nutshell: tweak it until it works, then pray Google won't change the APIs again.

          (Z(:^

          B 1 Reply Last reply
          0
          • sierdzioS sierdzio

            Hm I think I've seen it but I don't remember how I solved it. I think I had to tweak the API level (NDK, SDK minimal or target), but not sure.

            That's Qt for Android in a nutshell: tweak it until it works, then pray Google won't change the APIs again.

            B Offline
            B Offline
            bogong
            wrote on last edited by
            #5

            @sierdzio You mean "try to lower API"?

            1 Reply Last reply
            0
            • sierdzioS Offline
              sierdzioS Offline
              sierdzio
              Moderators
              wrote on last edited by
              #6

              I'd rather try setting it higher first.

              (Z(:^

              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