I have a Application.mk and a Android.mk file.
Application.mk looks like
NDK_TOOLCHAIN_VERSION := 4.8
APP_PLATFORM := android-9
APP_STL := c++_shared
APP_ABI := armeabi-v7a
and my Android.mk looks like
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := foo1
LOCAL_SRC_FILES := foo1.cpp
# ... some other stuff ...
include $(BUILD_SHARED_LIBRARY)
include $(CLEAR_VARS)
LOCAL_MODULE := foo2
LOCAL_SRC_FILES := foo2.cpp
# ... some other stuff ...
include $(BUILD_SHARED_LIBRARY)
Now I want that library libfoo1 use c++_shared for APP_STL and libfoo2 use c++_static for APP_STL. (I know, normally that should not be made relation between app_stl values with static and shared build android). Is there a easy way without building a extra project and import the library to the other project?