Revert "Use Soong-processed files for file_contexts.bin"
This reverts commit d1401b7a2f
.
Reason for revert: DroidMonitor-triggered revert due to breakage, bug 308055894
Change-Id: Ic22a37a6d32662344da80fb28751e8c34803a82e
This commit is contained in:
parent
d1401b7a2f
commit
32a83de069
1 changed files with 21 additions and 5 deletions
26
Android.mk
26
Android.mk
|
@ -94,6 +94,13 @@ define build_policy
|
|||
$(strip $(foreach type, $(1), $(foreach file, $(addsuffix /$(type), $(2)), $(sort $(wildcard $(file))))))
|
||||
endef
|
||||
|
||||
# Builds paths for all policy files found in BOARD_VENDOR_SEPOLICY_DIRS.
|
||||
# $(1): the set of policy name paths to build
|
||||
build_vendor_policy = $(call build_policy, $(1), $(PLAT_VENDOR_POLICY) $(BOARD_VENDOR_SEPOLICY_DIRS))
|
||||
|
||||
# Builds paths for all policy files found in BOARD_ODM_SEPOLICY_DIRS.
|
||||
build_odm_policy = $(call build_policy, $(1), $(BOARD_ODM_SEPOLICY_DIRS))
|
||||
|
||||
sepolicy_build_files := security_classes \
|
||||
initial_sids \
|
||||
access_vectors \
|
||||
|
@ -458,14 +465,21 @@ include $(BUILD_SYSTEM)/base_rules.mk
|
|||
# Note: That a newline file is placed between each file_context file found to
|
||||
# ensure a proper build when an fc file is missing an ending newline.
|
||||
|
||||
local_fc_files := $(call intermediates-dir-for,ETC,plat_file_contexts)/plat_file_contexts
|
||||
local_fc_files := $(call build_policy, file_contexts, $(PLAT_PRIVATE_POLICY))
|
||||
|
||||
ifdef HAS_SYSTEM_EXT_SEPOLICY_DIR
|
||||
local_fc_files += $(call intermediates-dir-for,ETC,system_ext_file_contexts)/system_ext_file_contexts
|
||||
local_fc_files += $(call build_policy, file_contexts, $(SYSTEM_EXT_PRIVATE_POLICY))
|
||||
endif
|
||||
|
||||
ifdef HAS_PRODUCT_SEPOLICY_DIR
|
||||
local_fc_files += $(call intermediates-dir-for,ETC,product_file_contexts)/product_file_contexts
|
||||
local_fc_files += $(call build_policy, file_contexts, $(PRODUCT_PRIVATE_POLICY))
|
||||
endif
|
||||
|
||||
ifneq ($(filter address,$(SANITIZE_TARGET)),)
|
||||
local_fc_files += $(wildcard $(addsuffix /file_contexts_asan, $(PLAT_PRIVATE_POLICY)))
|
||||
endif
|
||||
ifneq (,$(filter userdebug eng,$(TARGET_BUILD_VARIANT)))
|
||||
local_fc_files += $(wildcard $(addsuffix /file_contexts_overlayfs, $(PLAT_PRIVATE_POLICY)))
|
||||
endif
|
||||
|
||||
###########################################################
|
||||
|
@ -492,10 +506,10 @@ $(call merge-fc-files,$(local_fc_files),$(file_contexts.local.tmp))
|
|||
# it gathers LOCAL_FILE_CONTEXTS from product_MODULES
|
||||
file_contexts.modules.tmp := $(intermediates)/file_contexts.modules.tmp
|
||||
|
||||
device_fc_files += $(call intermediates-dir-for,ETC,vendor_file_contexts)/vendor_file_contexts
|
||||
device_fc_files := $(call build_vendor_policy, file_contexts)
|
||||
|
||||
ifdef BOARD_ODM_SEPOLICY_DIRS
|
||||
device_fc_files += $(call intermediates-dir-for,ETC,odm_file_contexts)/odm_file_contexts
|
||||
device_fc_files += $(call build_odm_policy, file_contexts)
|
||||
endif
|
||||
|
||||
file_contexts.device.tmp := $(intermediates)/file_contexts.device.tmp
|
||||
|
@ -559,6 +573,8 @@ base_product_pub_policy.cil :=
|
|||
#################################
|
||||
|
||||
|
||||
build_vendor_policy :=
|
||||
build_odm_policy :=
|
||||
build_policy :=
|
||||
built_sepolicy :=
|
||||
built_sepolicy_neverallows :=
|
||||
|
|
Loading…
Reference in a new issue