4

Let's say we have 64 bit hardware with 64 bit linux kernel and 64 bit android.
So Zygote will be running as 64 bit process with its own instance of DVM.

Now assume that there is a third party application which contains a 32 bit native library that is loaded at runtime using system.loadlibrary call.

I think that when we try to run this application, zygote will be able to start the process and DVM will be able to interpret classes.dex file even if the apk was built for 32 bit machine. But failure will happen when the application will try to load 32 bit native library since on the device bionic libc and other libraries will be all 64 bit.

Is this understanding correct?

JoshDM
  • 4,939
  • 7
  • 43
  • 72
user3441633
  • 41
  • 1
  • 3

1 Answers1

0

As I knew, 32bits Native libraries will run successfully at 64bits OS if the OS supports many 32bits libraries(Java Native Interface 32 bit dll on 64 bit system), and In Android system, the OS arch is 32bits limit(https://android.stackexchange.com/questions/36291/is-android-a-32-bit-or-64-bit-os), so you need compiling 32 bits native libraries.

In summary, 32bits need 32bits libraries if it runs at 64bits OS.

Community
  • 1
  • 1
QJGui
  • 907
  • 8
  • 10