forked from openkylin/platform_build
Build: Skip JNI lib symlink in second-stage build
When creating a sanitized image, skip creating JNI library symlinks in the second round. Bug: 33279120 Test: m && m SANITIZE_TARGET=address & ls -l $OUT/system/app/NfcNci/lib/* Change-Id: Ib5eace9a49eb8b693603ba5cc59e392d575c44e3
This commit is contained in:
parent
fcf364b15a
commit
445553f4e7
|
@ -59,6 +59,8 @@ my_shared_library_path := $($(my_2nd_arch_prefix)TARGET_OUT$(partition_tag)_SHAR
|
|||
$(LOCAL_INSTALLED_MODULE) : $(addprefix $(my_shared_library_path)/, $(my_jni_filenames))
|
||||
|
||||
# Create symlink in the app specific lib path
|
||||
# Skip creating this symlink when running the second part of a target sanitization build.
|
||||
ifndef SANITIZE_TARGET
|
||||
ifdef LOCAL_POST_INSTALL_CMD
|
||||
# Add a shell command separator
|
||||
LOCAL_POST_INSTALL_CMD += ;
|
||||
|
@ -70,6 +72,11 @@ LOCAL_POST_INSTALL_CMD += \
|
|||
mkdir -p $(my_app_lib_path) \
|
||||
$(foreach lib, $(my_jni_filenames), ;ln -sf $(my_symlink_target_dir)/$(lib) $(my_app_lib_path)/$(lib))
|
||||
$(LOCAL_INSTALLED_MODULE): PRIVATE_POST_INSTALL_CMD := $(LOCAL_POST_INSTALL_CMD)
|
||||
else
|
||||
ifdef LOCAL_POST_INSTALL_CMD
|
||||
$(LOCAL_INSTALLED_MODULE): PRIVATE_POST_INSTALL_CMD := $(LOCAL_POST_INSTALL_CMD)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Clear jni_shared_libraries to not embed it into the apk.
|
||||
my_jni_shared_libraries :=
|
||||
|
|
Loading…
Reference in New Issue