Details
-
Bug
-
Resolution: Duplicate
-
P1: Critical
-
None
-
5.11.0
-
None
Description
I moved my Android application from 5.10.1 to 5.11 and now it crashes at startup.
The crash occurs when calling a native method in my activity onResume().
No implementation found for void qtTest.Natives.testNative() (tried Java_qtTest_Natives_testNative and Java_qtTest_Natives_testNative__) E AndroidRuntime: FATAL EXCEPTION: main E AndroidRuntime: Process: org.qtproject.example, PID: 9997 E AndroidRuntime: java.lang.UnsatisfiedLinkError: No implementation found for void qtTest.Natives.testNative() (tried Java_qtTest_Natives_testNative and Java_qtTest_Natives_testNative__) E AndroidRuntime: at qtTest.Natives.testNative(Native Method)
Native methods in the rest of the code work.
The attached code works fine with 5.10.1 but crashes with 5.11. If I comment
Natives.testNative();
in onResume(), then it works with 5.11.
I looked at the changes between 5.10.1 and 5.11 and this was removed in QtLoader.java line 246. When I put it back in 5.11, then it works.
// now load the application library so it's accessible from this class loader if (libName != null) System.loadLibrary(libName);
Attachments
Issue Links
- duplicates
-
QTBUG-68813 UnsatisfiedLinkError when manually registering functions via JNI_OnLoad
- Closed