android2018. 6. 19. 10:43

System app에서 so file을 로딩하기 위한 방법으로 아래와 같이 library를 추가해 준다.

차이는 아래와 같이 LOCAL_JNI_SHARED_LIBRARIES를 사용할 경우 system/lib 경로에 so 가 복사된다.


LOCAL_JNI_SHARED_LIBRARIES := libbluetooth_jni


out/target/product/project/system$ find . -name "libbluetooth_jni.so"

./lib/libbluetooth_jni.so

./app/Bluetooth/lib/arm/libbluetooth_jni.so



 LOCAL_PREBUILT_JNI_LIBS_arm := libs/armeabi-v7a/libAesJni.so

system$ find . -name "libAesJni.so"

./priv-app/RemoteVoiceInput/lib/arm/libAesJni.so



Posted by easy16