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

Commit 57cbc990 authored by Jaewoong Jung's avatar Jaewoong Jung Committed by Gerrit Code Review
Browse files

Merge "Skip unneeded notice files for ETC modules."

parents db57997c dca3186b
Loading
Loading
Loading
Loading
+9 −4
Original line number Diff line number Diff line
@@ -38,6 +38,8 @@ else
endif
endif

installed_notice_file :=

ifdef notice_file

ifdef my_register_name
@@ -71,12 +73,17 @@ else
      endif
      module_installed_filename := \
          $(patsubst $(PRODUCT_OUT)/%,%,$($(my_prefix)OUT_JAVA_LIBRARIES))/$(module_leaf)
    else ifeq ($(LOCAL_MODULE_CLASS),ETC)
      # ETC modules may be uninstallable, yet still have a NOTICE file. e.g. apex components
      module_installed_filename :=
    else
      $(error Cannot determine where to install NOTICE file for $(LOCAL_MODULE))
    endif # JAVA_LIBRARIES
  endif # STATIC_LIBRARIES
endif

ifdef module_installed_filename

# In case it's actually a host file
module_installed_filename := $(patsubst $(HOST_OUT)/%,%,$(module_installed_filename))
module_installed_filename := $(patsubst $(HOST_CROSS_OUT)/%,%,$(module_installed_filename))
@@ -110,10 +117,8 @@ $(LOCAL_BUILT_MODULE): | $(installed_notice_file)
endif  # JAVA_LIBRARIES
endif  # TARGET_BUILD_APPS

else
# NOTICE file does not exist
installed_notice_file :=
endif
endif  # module_installed_filename
endif  # notice_file

# Create a predictable, phony target to build this notice file.
# Define it even if the notice file doesn't exist so that other