0

I did build an Android app using Qt, the same build works on Android 4.4 and 4.3 but fails on 4.1 and below. Not tested for 4.2. It throws error that libopencv_java.so not found

W/dalvikvm( 3915): threadid=1: thread exiting with uncaught exception (group=0x409c01f8)
E/AndroidRuntime( 3915): FATAL EXCEPTION: main
E/AndroidRuntime( 3915): java.lang.UnsatisfiedLinkError: Cannot load library: link_image[1936]:    37 could not load needed library 'libopencv_java.so' for 'libTrackerDemo.so' (load_library[1091]: Library 'libopencv_java.so' not found)

Moreover, I have specified min req sdk version to be 14 and haven't set any target SDK.

sumsrv
  • 654
  • 3
  • 8
  • 25

1 Answers1

0

This ended up on a surprising solution. One has to specify ANDROID_EXTRA_LIBS as well along with LIBS for every architecture. Values for both shall be same. The need for this duplicated entry is that NDK uses LIBS to compile the project and ANDROID_EXTRA_LIBS is someway related to enable Android to locate the libs in the APK.

sumsrv
  • 654
  • 3
  • 8
  • 25