Question

I'm implementing a system to trace all the calls to the API from any APK. The idea is add a call to my module in dvmResolveMethod, JNICall, etc... This module is implemented inside the DVM, in the same library. All the traces are send to a process daemon to parse and detect malware.

Between the daemon and the module I'm using sockets. The daemon is implemented with FrameworkListener using the service way to create a "named" socket. Now I need to use the socket from the module, and I'd like to use FrameworkClient. So I wanna add include libsysutils.

Adding "LOCAL_SHARED_LIBRARIES := libsysutils" in the Dvm.mk file makes this error:

make: * No rule to make target out/host/linux-x86/obj/SHARED_LIBRARIES/libsysutils_intermediates/export_includes', needed byout/host/linux-x86/obj/SHARED_LIBRARIES/libdvm_intermediates/import_includes'. Stop.

I think that the error is caused by the compiling order, so maybe I should try to change it and compile the lib before the DVM but I'm not sure how I can do that. Android's makefiles is too much for me.

Any help will be very appreciated.

Thanks

Was it helpful?

Solution

system/core/libsysutils is only compiled in target device. But dalvik will be compiled in target and host device. Here I suggest you close dalvik vm host platform compiling.

dalvik/vm/Android.mk: assign WITH_HOST_DALVIK to false.

And you should mm @ system/core/libsysutils first.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top