Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4ac4231c authored by Dan Albert's avatar Dan Albert
Browse files

Add LOCAL_COPY_TO_INTERMEDIATE_LIBRARIES.

This allows a module to avoid being installed to the common library
directory.

Test: Prevents copying of NDK libraries with the NDK sysroot patches.
Bug: http://b/27533932
Change-Id: I24f11d5a70595bcd524ac5bd85034c226d2de211
parent 653980bf
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -199,6 +199,7 @@ LOCAL_NOTICE_FILE:=
# to avoid installing the presigned apks with classes.dex unstripped.
LOCAL_REPLACE_PREBUILT_APK_INSTALLED:=
LOCAL_NDK_VERSION:=current
LOCAL_COPY_TO_INTERMEDIATE_LIBRARIES:=
LOCAL_LOGTAGS_FILES:=

# arch specific variables
+12 −3
Original line number Diff line number Diff line
@@ -46,9 +46,18 @@ my_pack_module_relocations := $(firstword \
  $(LOCAL_PACK_MODULE_RELOCATIONS))

ifeq (SHARED_LIBRARIES,$(LOCAL_MODULE_CLASS))
  # LOCAL_COPY_TO_INTERMEDIATE_LIBRARIES indicates that this prebuilt should be
  # installed to the common directory of libraries. This is needed for the NDK
  # shared libraries built by soong, as we build many different versions of each
  # library (one for each API level). Since they all have the same basename,
  # they'd clobber each other (as well as any platform libraries by the same
  # name).
  ifneq ($(LOCAL_COPY_TO_INTERMEDIATE_LIBRARIES),false)
    # 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)
    OVERRIDE_BUILT_MODULE_PATH :=  \
        $($(LOCAL_2ND_ARCH_VAR_PREFIX)$(my_prefix)OUT_INTERMEDIATE_LIBRARIES)
  endif
  ifeq ($(LOCAL_IS_HOST_MODULE)$(my_strip_module),)
    # Strip but not try to add debuglink
    my_strip_module := no_debuglink