To do that.
I have to declare these libs as modules. Like the following.
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := curl
LOCAL_SRC_FILES := libcurl.a
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
include $(PREBUILT_STATIC_LIBRARY)
With a libcurl.a file in the same folder as this Android.mk file, and a /include fodler with the headers.
Now in the main module just declare the lib and the Android NDK will take care of the rest.
LOCAL_PATH := $(call my-dir)
include $(call all-subdir-makefiles)
include $(CLEAR_VARS)
LOCAL_LDLIBS := -llog -ldl
LOCAL_MODULE := rmsdk
LOCAL_SRC_FILES := curlnetprovider.cpp native.c
LOCAL_STATIC_LIBRARIES := curl
include $(BUILD_SHARED_LIBRARY)
Note.. you should include the Android.mk file of the module before using it. I do that with the call all-subdir-makefiles.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…