Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Jni android.mk
#Start from here
LOCAL+PATH:= $(call my-dir)
#Module1 definition start
include $(CLEAR_VARS)
LOCAL_MODULE := modulename1
LOCAL_SRC_FILES := modulesource1.c
include $(BUILD_STATIC_LIBRARY)
#Module1 definition end, this is a lib module, so it is "BUILD_STATIC_LIBRARY"
#Module2 difinition start
include $(CLEAR_VARS)
LOCAL_MODULE := modulename2
LOCAL_SRC_FILES := modulesource2.c
LOCAL_STATIC_LIBRARIES := modulename1
include $(BUILD_SHARED_LIBRARY)
#Module2 definition end, this is a normal module, use module1 as a library, so call "LOCAL_STATIC_LIBRARIES := modulename1"
#And it is "BUILD_SHARED_LIBRARY"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.