diff options
author | Ying Wang <wangying@google.com> | 2014-08-20 17:12:32 -0700 |
---|---|---|
committer | Ying Wang <wangying@google.com> | 2014-09-03 12:11:06 -0700 |
commit | bfb52a2ec199a75e1a0e4e92148af0a6323c9f46 (patch) | |
tree | ef39b44ce9a77e7b3845153e5242c88ebc97156d /core/prebuilt_internal.mk | |
parent | df71e5b1c5cd637ac6eb5cd6df8cce1965c91593 (diff) | |
download | build-bfb52a2ec199a75e1a0e4e92148af0a6323c9f46.zip build-bfb52a2ec199a75e1a0e4e92148af0a6323c9f46.tar.gz build-bfb52a2ec199a75e1a0e4e92148af0a6323c9f46.tar.bz2 |
Strip prebuilt shared library by default.
Strip prebuilt shared library but not try adding gnu debuglink.
It would fail if you try run the adding gnu debuglink command if a
prebuilt is already stripped.
Bug: 17177288
Change-Id: If5811865715c2437e45fbd329983ef1212ef0109
Diffstat (limited to 'core/prebuilt_internal.mk')
-rw-r--r-- | core/prebuilt_internal.mk | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/core/prebuilt_internal.mk b/core/prebuilt_internal.mk index 5666cfd..0544c54 100644 --- a/core/prebuilt_internal.mk +++ b/core/prebuilt_internal.mk @@ -39,6 +39,10 @@ ifeq (SHARED_LIBRARIES,$(LOCAL_MODULE_CLASS)) # Put the built targets of all shared libraries in a common directory # to simplify the link line. OVERRIDE_BUILT_MODULE_PATH := $($(LOCAL_2ND_ARCH_VAR_PREFIX)$(my_prefix)OUT_INTERMEDIATE_LIBRARIES) + ifeq ($(LOCAL_IS_HOST_MODULE)$(LOCAL_STRIP_MODULE),) + # Strip but not try to add debuglink + LOCAL_STRIP_MODULE := no_debuglink + endif endif ifneq ($(filter STATIC_LIBRARIES SHARED_LIBRARIES,$(LOCAL_MODULE_CLASS)),) @@ -59,7 +63,7 @@ LOCAL_BUILT_MODULE_STEM := package.apk LOCAL_INSTALLED_MODULE_STEM := $(LOCAL_MODULE).apk endif -ifeq ($(LOCAL_STRIP_MODULE),true) +ifneq ($(filter true no_debuglink,$(LOCAL_STRIP_MODULE)),) ifdef LOCAL_IS_HOST_MODULE $(error Cannot strip host module LOCAL_PATH=$(LOCAL_PATH)) endif @@ -71,6 +75,7 @@ ifeq ($(LOCAL_STRIP_MODULE),true) endif include $(BUILD_SYSTEM)/dynamic_binary.mk built_module := $(linked_module) + else # LOCAL_STRIP_MODULE not true include $(BUILD_SYSTEM)/base_rules.mk built_module := $(LOCAL_BUILT_MODULE) @@ -109,6 +114,8 @@ $(LOCAL_BUILT_MODULE) : $(built_shared_libraries) endif endif +# We need to enclose the above export_includes and built_shared_libraries in +# "LOCAL_STRIP_MODULE not true" because otherwise the rules are defined in dynamic_binary.mk. endif # LOCAL_STRIP_MODULE not true ifeq ($(LOCAL_MODULE_CLASS),APPS) |