Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 1 | LOCAL_PATH:= $(call my-dir) |
Colin Cross | 2764fce | 2014-03-19 17:47:39 -0700 | [diff] [blame] | 2 | |
Christopher Ferris | ad81791 | 2015-06-17 15:03:20 -0700 | [diff] [blame] | 3 | # This is a list of libraries that need to be included in order to avoid |
| 4 | # bad apps. This prevents a library from having a mismatch when resolving |
| 5 | # new/delete from an app shared library. |
| 6 | # See b/21032018 for more details. |
| 7 | app_process_common_shared_libs := \ |
| 8 | libwilhelm \ |
| 9 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 10 | include $(CLEAR_VARS) |
| 11 | |
| 12 | LOCAL_SRC_FILES:= \ |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 13 | app_main.cpp |
Dmitriy Ivanov | 96e0cfa | 2014-10-07 13:34:42 -0700 | [diff] [blame] | 14 | |
| 15 | LOCAL_LDFLAGS := -Wl,--version-script,art/sigchainlib/version-script.txt -Wl,--export-dynamic |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 16 | |
| 17 | LOCAL_SHARED_LIBRARIES := \ |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 18 | libdl \ |
| 19 | libcutils \ |
| 20 | libutils \ |
| 21 | liblog \ |
| 22 | libbinder \ |
Christopher Ferris | ad81791 | 2015-06-17 15:03:20 -0700 | [diff] [blame] | 23 | libandroid_runtime \ |
| 24 | $(app_process_common_shared_libs) \ |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 25 | |
Dmitriy Ivanov | 5ba317c | 2014-10-20 14:14:39 -0700 | [diff] [blame] | 26 | LOCAL_WHOLE_STATIC_LIBRARIES := libsigchain |
| 27 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 28 | LOCAL_MODULE:= app_process |
Colin Cross | f130f0a | 2014-03-27 10:20:29 -0700 | [diff] [blame] | 29 | LOCAL_MULTILIB := both |
Yongqin Liu | 559484e | 2014-05-06 23:30:40 +0800 | [diff] [blame] | 30 | LOCAL_MODULE_STEM_32 := app_process32 |
Colin Cross | f130f0a | 2014-03-27 10:20:29 -0700 | [diff] [blame] | 31 | LOCAL_MODULE_STEM_64 := app_process64 |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 32 | |
| 33 | LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code |
| 34 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 35 | include $(BUILD_EXECUTABLE) |
| 36 | |
Yongqin Liu | 559484e | 2014-05-06 23:30:40 +0800 | [diff] [blame] | 37 | # Create a symlink from app_process to app_process32 or 64 |
| 38 | # depending on the target configuration. |
| 39 | include $(BUILD_SYSTEM)/executable_prefer_symlink.mk |
| 40 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 41 | # Build a variant of app_process binary linked with ASan runtime. |
| 42 | # ARM-only at the moment. |
| 43 | ifeq ($(TARGET_ARCH),arm) |
| 44 | |
| 45 | include $(CLEAR_VARS) |
| 46 | |
| 47 | LOCAL_SRC_FILES:= \ |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 48 | app_main.cpp |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 49 | |
| 50 | LOCAL_SHARED_LIBRARIES := \ |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 51 | libcutils \ |
| 52 | libutils \ |
| 53 | liblog \ |
| 54 | libbinder \ |
Christopher Ferris | ad81791 | 2015-06-17 15:03:20 -0700 | [diff] [blame] | 55 | libandroid_runtime \ |
| 56 | $(app_process_common_shared_libs) \ |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 57 | |
Dmitriy Ivanov | 5ba317c | 2014-10-20 14:14:39 -0700 | [diff] [blame] | 58 | LOCAL_WHOLE_STATIC_LIBRARIES := libsigchain |
| 59 | |
Dmitriy Ivanov | 96e0cfa | 2014-10-07 13:34:42 -0700 | [diff] [blame] | 60 | LOCAL_LDFLAGS := -ldl -Wl,--version-script,art/sigchainlib/version-script.txt -Wl,--export-dynamic |
Dmitriy Ivanov | 5ba317c | 2014-10-20 14:14:39 -0700 | [diff] [blame] | 61 | LOCAL_CPPFLAGS := -std=c++11 |
Dmitriy Ivanov | 96e0cfa | 2014-10-07 13:34:42 -0700 | [diff] [blame] | 62 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 63 | LOCAL_MODULE := app_process__asan |
Evgenii Stepanov | e740b17 | 2015-05-07 10:55:59 -0700 | [diff] [blame] | 64 | LOCAL_MULTILIB := both |
| 65 | LOCAL_MODULE_STEM_32 := app_process32 |
| 66 | LOCAL_MODULE_STEM_64 := app_process64 |
| 67 | |
Dan Albert | f98dae5 | 2015-06-16 14:06:49 -0700 | [diff] [blame] | 68 | LOCAL_SANITIZE := address |
Dan Albert | b9f6b0e | 2015-04-17 10:40:48 -0700 | [diff] [blame] | 69 | LOCAL_CLANG := true |
Evgenii Stepanov | e740b17 | 2015-05-07 10:55:59 -0700 | [diff] [blame] | 70 | LOCAL_MODULE_PATH := $(TARGET_OUT_EXECUTABLES)/asan |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 71 | |
Andreas Gampe | cfedceb | 2014-09-30 21:48:18 -0700 | [diff] [blame] | 72 | LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code |
| 73 | |
Mike Lockwood | e0e9e94 | 2012-10-24 11:52:57 -0700 | [diff] [blame] | 74 | include $(BUILD_EXECUTABLE) |
| 75 | |
| 76 | endif # ifeq($(TARGET_ARCH),arm) |