summaryrefslogtreecommitdiffstats
path: root/core/notice_files.mk
diff options
context:
space:
mode:
authorThe Android Open Source Project <initial-contribution@android.com>2009-03-03 18:28:14 -0800
committerThe Android Open Source Project <initial-contribution@android.com>2009-03-03 18:28:14 -0800
commit05806d7af62e07c6225b2e7103a1b115ecf6c9ad (patch)
tree4b825dc642cb6eb9a060e54bf8d69288fbee4904 /core/notice_files.mk
parent094268cf8cb37b9d904c8a1e3559cdd46d73cf66 (diff)
downloadbuild-05806d7af62e07c6225b2e7103a1b115ecf6c9ad.zip
build-05806d7af62e07c6225b2e7103a1b115ecf6c9ad.tar.gz
build-05806d7af62e07c6225b2e7103a1b115ecf6c9ad.tar.bz2
auto import from //depot/cupcake/@135843
Diffstat (limited to 'core/notice_files.mk')
-rw-r--r--core/notice_files.mk65
1 files changed, 0 insertions, 65 deletions
diff --git a/core/notice_files.mk b/core/notice_files.mk
deleted file mode 100644
index 24295c7..0000000
--- a/core/notice_files.mk
+++ /dev/null
@@ -1,65 +0,0 @@
-###########################################################
-## Track NOTICE files
-###########################################################
-
-notice_file:=$(shell find $(LOCAL_PATH) -maxdepth 1 -name NOTICE)
-
-ifneq ($(strip $(notice_file)),)
-
-# This relies on the name of the directory in PRODUCT_OUT matching where
-# it's installed on the target - i.e. system, data, etc. This does
-# not work for root and isn't exact, but it's probably good enough for
-# compliance.
-# Includes the leading slash
-ifdef LOCAL_INSTALLED_MODULE
- module_installed_filename := $(patsubst $(PRODUCT_OUT)%,%,$(LOCAL_INSTALLED_MODULE))
-else
- # This module isn't installable
- ifeq ($(LOCAL_MODULE_CLASS),STATIC_LIBRARIES)
- # Stick the static libraries with the dynamic libraries.
- # We can't use xxx_OUT_STATIC_LIBRARIES because it points into
- # device-obj or host-obj.
- module_installed_filename := \
- $(patsubst $(PRODUCT_OUT)%,%,$($(my_prefix)OUT_SHARED_LIBRARIES))/$(notdir $(LOCAL_BUILT_MODULE))
- else
- ifeq ($(LOCAL_MODULE_CLASS),JAVA_LIBRARIES)
- # Stick the static java libraries with the regular java libraries.
- module_installed_filename := \
- $(patsubst $(PRODUCT_OUT)%,%,$($(my_prefix)OUT_JAVA_LIBRARIES))/$(notdir $(LOCAL_BUILT_MODULE))
- else
- $(error Cannot determine where to install NOTICE file for $(LOCAL_MODULE))
- endif # JAVA_LIBRARIES
- endif # STATIC_LIBRARIES
-endif
-
-# In case it's actually a host file
-module_installed_filename := $(patsubst $(HOST_OUT)%,%,$(module_installed_filename))
-
-installed_notice_file := $($(my_prefix)OUT_NOTICE_FILES)/src/$(module_installed_filename).txt
-
-$(installed_notice_file): PRIVATE_INSTALLED_MODULE := $(module_installed_filename)
-
-$(installed_notice_file): $(notice_file)
- @echo Notice file: $< -- $@
- $(hide) mkdir -p $(dir $@)
- $(hide) cat $< >> $@
-
-ifdef LOCAL_INSTALLED_MODULE
-# Make LOCAL_INSTALLED_MODULE depend on NOTICE files if they exist
-# libraries so they get installed along with it. Make it an order-only
-# dependency so we don't re-install a module when the NOTICE changes.
-$(LOCAL_INSTALLED_MODULE): | $(installed_notice_file)
-endif
-
-else
-# NOTICE file does not exist
-installed_notice_file :=
-endif
-
-# Create a predictable, phony target to build this notice file.
-# Define it even if the notice file doesn't exist so that other
-# modules can depend on it.
-notice_target := NOTICE-$(if \
- $(LOCAL_IS_HOST_MODULE),HOST,TARGET)-$(LOCAL_MODULE_CLASS)-$(LOCAL_MODULE)
-.PHONY: $(notice_target)
-$(notice_target): $(installed_notice_file)