blob: 1dd88854140ce702db5dd3f5bb640442ed4bb3fa [file] [log] [blame]
Jamie Gennis134f0422011-03-08 12:18:54 -08001# Build the unit tests.
2LOCAL_PATH:= $(call my-dir)
3include $(CLEAR_VARS)
4
5ifneq ($(TARGET_SIMULATOR),true)
6
7# Build the unit tests.
8test_src_files := \
9 SurfaceTextureClient_test.cpp \
10
11shared_libraries := \
12 libcutils \
13 libutils \
14 libbinder \
15 libgui \
16 libstlport \
17
18static_libraries := \
19 libgtest \
20 libgtest_main \
21
22c_includes := \
23 bionic \
24 bionic/libstdc++/include \
25 external/gtest/include \
26 external/stlport/stlport \
27
28module_tags := tests
29
30$(foreach file,$(test_src_files), \
31 $(eval include $(CLEAR_VARS)) \
32 $(eval LOCAL_SHARED_LIBRARIES := $(shared_libraries)) \
33 $(eval LOCAL_STATIC_LIBRARIES := $(static_libraries)) \
34 $(eval LOCAL_C_INCLUDES := $(c_includes)) \
35 $(eval LOCAL_SRC_FILES := $(file)) \
36 $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \
37 $(eval LOCAL_MODULE_TAGS := $(module_tags)) \
38 $(eval include $(BUILD_EXECUTABLE)) \
39)
40
41# Build the manual test programs.
42include $(call all-subdir-makefiles)
43
44endif
45
46# Include subdirectory makefiles
47# ============================================================
48
49# If we're building with ONE_SHOT_MAKEFILE (mm, mmm), then what the framework
50# team really wants is to build the stuff defined by this makefile.
51ifeq (,$(ONE_SHOT_MAKEFILE))
52include $(call first-makefiles-under,$(LOCAL_PATH))
53endif