2

I'm developing an Android application with native C is the core processing. I use NDKr10 to build libs from native code and success. But when I try to load the libs then the the error is shown:

Cannot load library soinfo_relocate(linker.cpp:975): cannot locate symbol "log2f" referenced by "libvlfeat.so"...

I found some resources say that this error caused by gcc compiler and Android target version, but I'm not sure about it.(My target SDK is 21).

Update: My app work fine on api 21 device but the lower version showing error.

Someone know about this problem?Please give me a solution to fix this.

Thanks.

1 Answers1

0

You must load the .so libraries in the order that would resolve dependencies between them. That is, you must hard-code the order of loading.

Some knowledge about Android.mk may be found here, here and here. (But if your project compiles successfully, your Android.mk is likely working.)

There is a gotcha that .so libraries in libs/armeabi and libs/armeabi-v7a do not get combined. That is, if you have some pre-compiled library only in the armeabi version, there is no use in compiling your libraries for armeabi-v7a (because the pre-compiled armeabi library will not be found).

Community
  • 1
  • 1
18446744073709551615
  • 16,368
  • 4
  • 94
  • 127