Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 1 | # Build the unit tests. |
| 2 | LOCAL_PATH := $(call my-dir) |
| 3 | include $(CLEAR_VARS) |
| 4 | |
Jeff Brown | 3f607c1 | 2010-07-14 22:40:08 -0700 | [diff] [blame] | 5 | # Build the unit tests. |
Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 6 | test_src_files := \ |
Kenny Root | 2fe13f1 | 2012-10-02 09:09:10 -0700 | [diff] [blame] | 7 | BasicHashtable_test.cpp \ |
| 8 | BlobCache_test.cpp \ |
Michael Wright | d614ee4 | 2013-05-21 14:11:34 -0700 | [diff] [blame] | 9 | BitSet_test.cpp \ |
Kenny Root | 2fe13f1 | 2012-10-02 09:09:10 -0700 | [diff] [blame] | 10 | Looper_test.cpp \ |
Raph Levien | b6ea175 | 2012-10-25 23:11:13 -0700 | [diff] [blame] | 11 | LruCache_test.cpp \ |
Kenny Root | 2fe13f1 | 2012-10-02 09:09:10 -0700 | [diff] [blame] | 12 | String8_test.cpp \ |
| 13 | Unicode_test.cpp \ |
Mathias Agopian | 9eb2a3b | 2013-05-06 20:20:50 -0700 | [diff] [blame] | 14 | Vector_test.cpp |
Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 15 | |
Jeff Brown | 80d9c1c | 2010-06-14 15:44:41 -0700 | [diff] [blame] | 16 | shared_libraries := \ |
Kenny Root | 2fe13f1 | 2012-10-02 09:09:10 -0700 | [diff] [blame] | 17 | libz \ |
| 18 | liblog \ |
| 19 | libcutils \ |
| 20 | libutils \ |
Dan Albert | 7bc49a1 | 2014-05-30 19:40:58 +0000 | [diff] [blame] | 21 | libstlport |
| 22 | |
| 23 | static_libraries := \ |
| 24 | libgtest \ |
| 25 | libgtest_main |
Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 26 | |
| 27 | $(foreach file,$(test_src_files), \ |
Jeff Brown | 80d9c1c | 2010-06-14 15:44:41 -0700 | [diff] [blame] | 28 | $(eval include $(CLEAR_VARS)) \ |
| 29 | $(eval LOCAL_SHARED_LIBRARIES := $(shared_libraries)) \ |
| 30 | $(eval LOCAL_STATIC_LIBRARIES := $(static_libraries)) \ |
Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 31 | $(eval LOCAL_SRC_FILES := $(file)) \ |
| 32 | $(eval LOCAL_MODULE := $(notdir $(file:%.cpp=%))) \ |
Kenny Root | 2fe13f1 | 2012-10-02 09:09:10 -0700 | [diff] [blame] | 33 | $(eval include $(BUILD_NATIVE_TEST)) \ |
Jeff Brown | 66db689 | 2010-04-22 18:58:52 -0700 | [diff] [blame] | 34 | ) |