1LOCAL_PATH:= $(call my-dir) 2include $(CLEAR_VARS) 3 4rs_cpp_SRC_FILES := \ 5 RenderScript.cpp \ 6 BaseObj.cpp \ 7 Element.cpp \ 8 Type.cpp \ 9 Allocation.cpp \ 10 Script.cpp \ 11 ScriptC.cpp \ 12 ScriptIntrinsics.cpp \ 13 ScriptIntrinsicBLAS.cpp \ 14 Sampler.cpp 15 16rs_cpp_SRC_FILES += ../rsCppUtils.cpp 17 18LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk 19include frameworks/compile/slang/rs_version.mk 20local_cflags_for_rs_cpp += $(RS_VERSION_DEFINE) \ 21 -Werror -Wall -Wextra \ 22 -Wno-unused-parameter -Wno-unused-variable 23 -std=c++11 24 25LOCAL_SRC_FILES := $(rs_cpp_SRC_FILES) 26 27LOCAL_CFLAGS += $(local_cflags_for_rs_cpp) 28 29LOCAL_SHARED_LIBRARIES := \ 30 libz \ 31 libutils \ 32 liblog \ 33 libdl \ 34 libgui 35 36LOCAL_STATIC_LIBRARIES := \ 37 libRSDispatch 38 39LOCAL_MODULE:= libRScpp 40 41LOCAL_C_INCLUDES += frameworks/rs 42LOCAL_C_INCLUDES += $(intermediates) 43 44# We need to export not just rs/cpp but also rs. This is because 45# RenderScript.h includes rsCppStructs.h, which includes rs/rsDefines.h. 46LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH) $(LOCAL_PATH)/.. 47 48include $(BUILD_SHARED_LIBRARY) 49 50#################################################################### 51 52include $(CLEAR_VARS) 53LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk 54 55LOCAL_CFLAGS += $(local_cflags_for_rs_cpp) 56 57ifeq ($(my_32_64_bit_suffix),32) 58LOCAL_SDK_VERSION := 9 59else 60LOCAL_SDK_VERSION := 21 61endif 62LOCAL_CFLAGS += -DRS_COMPATIBILITY_LIB 63 64LOCAL_SRC_FILES := $(rs_cpp_SRC_FILES) 65 66LOCAL_WHOLE_STATIC_LIBRARIES := \ 67 libRSDispatch 68 69LOCAL_MODULE:= libRScpp_static 70 71LOCAL_C_INCLUDES += frameworks/rs 72LOCAL_C_INCLUDES += $(intermediates) 73 74LOCAL_LDFLAGS := -llog -lz -ldl -Wl,--exclude-libs,libc++_static.a 75LOCAL_NDK_STL_VARIANT := c++_static 76 77LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH) $(LOCAL_PATH)/.. 78 79include $(BUILD_STATIC_LIBRARY) 80