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

Commit 27db0284 authored by Ulyana Trafimovich's avatar Ulyana Trafimovich Committed by Gerrit Code Review
Browse files

Merge "Don't expect all Java modules to have a manifest."

parents 7a8965c1 6ef5779c
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -169,12 +169,13 @@ LOCAL_DEX_PREOPT := false
endif

my_dex_jar := $(my_prebuilt_src_file)
my_manifest_or_apk := $(my_prebuilt_src_file)
dex_preopt_profile_src_file := $(my_prebuilt_src_file)

#######################################
# defines built_odex along with rule to install odex
my_manifest_or_apk := $(my_prebuilt_src_file)
include $(BUILD_SYSTEM)/dex_preopt_odex_install.mk
my_manifest_or_apk :=
#######################################
ifneq ($(LOCAL_REPLACE_PREBUILT_APK_INSTALLED),)
# There is a replacement for the prebuilt .apk we can install without any processing.
+12 −1
Original line number Diff line number Diff line
@@ -208,6 +208,17 @@ add_json_class_loader_context = \
# Verify <uses-library> coherence between the build system and the manifest.
################################################################################

# Some libraries do not have a manifest, so there is nothing to check against.
# Handle it as if the manifest had zero <uses-library> tags: it is ok unless the
# module has non-empty LOCAL_USES_LIBRARIES or LOCAL_OPTIONAL_USES_LIBRARIES.
ifndef my_manifest_or_apk
  ifneq (,$(strip $(LOCAL_USES_LIBRARIES)$(LOCAL_OPTIONAL_USES_LIBRARIES)))
    $(error $(LOCAL_MODULE) has non-empty <uses-library> list but no manifest)
  else
    LOCAL_ENFORCE_USES_LIBRARIES := false
  endif
endif

# Verify LOCAL_USES_LIBRARIES/LOCAL_OPTIONAL_USES_LIBRARIES
# If LOCAL_ENFORCE_USES_LIBRARIES is not set, default to true if either of LOCAL_USES_LIBRARIES or
# LOCAL_OPTIONAL_USES_LIBRARIES are specified.
@@ -360,7 +371,7 @@ ifdef LOCAL_DEX_PREOPT
  $(call add_json_str,  ProfileClassListing,            $(if $(my_process_profile),$(LOCAL_DEX_PREOPT_PROFILE)))
  $(call add_json_bool, ProfileIsTextListing,           $(my_profile_is_text_listing))
  $(call add_json_str,  EnforceUsesLibrariesStatusFile, $(my_enforced_uses_libraries))
  $(call add_json_bool, EnforceUsesLibraries,           $(LOCAL_ENFORCE_USES_LIBRARIES))
  $(call add_json_bool, EnforceUsesLibraries,           $(filter true,$(LOCAL_ENFORCE_USES_LIBRARIES)))
  $(call add_json_str,  ProvidesUsesLibrary,            $(firstword $(LOCAL_PROVIDES_USES_LIBRARY) $(LOCAL_MODULE)))
  $(call add_json_map,  ClassLoaderContexts)
  $(call add_json_class_loader_context, any, $(my_dexpreopt_libs))
+0 −1
Original line number Diff line number Diff line
@@ -33,7 +33,6 @@ endif

ifeq ($(prebuilt_module_is_dex_javalib),true)
my_dex_jar := $(my_prebuilt_src_file)
my_manifest_or_apk := $(my_prebuilt_src_file)
# This is a target shared library, i.e. a jar with classes.dex.

$(foreach pair,$(PRODUCT_BOOT_JARS), \