Skip to content
Snippets Groups Projects
Commit 4d24a775 authored by Dan Cashman's avatar Dan Cashman
Browse files

Fix build part 2. Always create platform_mapping_file.

commit 552fb537 fixed an undefined
module error by removing the module when not defined (on non-treble
devices), but the sepolicy build on non-treble devices was changed
to rely on the split treble files, even though the split is not used.
Change this so that the file is always present, to allow policy
compilation.

Test: policy fully builds.
Change-Id: Ia0934c739336cea54228bbff8d6644aa3ae501e5
parent 552fb537
No related branches found
No related tags found
No related merge requests found
......@@ -95,6 +95,9 @@ $(warning BOARD_SEPOLICY_VERS not specified, assuming current platform version)
BOARD_SEPOLICY_VERS := $(PLATFORM_SEPOLICY_VERSION)
endif
platform_mapping_file := $(BOARD_SEPOLICY_VERS).cil
###########################################################
# Compute policy files to be used in policy build.
# $(1): files to include
......@@ -166,8 +169,6 @@ LOCAL_MODULE_TAGS := optional
# inside init/init.cpp for loading SELinux policy from files.
ifeq ($(PRODUCT_FULL_TREBLE),true)
platform_mapping_file := $(BOARD_SEPOLICY_VERS).cil
# Use split SELinux policy
LOCAL_REQUIRED_MODULES += \
$(platform_mapping_file) \
......@@ -343,7 +344,6 @@ $(LOCAL_BUILT_MODULE) :
echo $(PRIVATE_PLAT_SEPOL_VERS) > $@
#################################
ifeq ($(PRODUCT_FULL_TREBLE),true)
include $(CLEAR_VARS)
LOCAL_MODULE := $(platform_mapping_file)
......@@ -377,7 +377,6 @@ $(LOCAL_BUILT_MODULE): $(mapping_policy_nvr)
built_mapping_cil := $(LOCAL_BUILT_MODULE)
current_mapping.cil :=
endif # ifeq ($(PRODUCT_FULL_TREBLE),true)
#################################
include $(CLEAR_VARS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment