Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
sepolicy
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CodeLinaro
public-release-test
platform
system
sepolicy
Commits
43a0a8e1
Commit
43a0a8e1
authored
6 years ago
by
Anton Hansson
Committed by
Gerrit Code Review
6 years ago
Browse files
Options
Downloads
Plain Diff
Merge "Split selinux_policy module into two."
parents
589dbe14
8cfe1e61
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Android.mk
+60
-35
60 additions, 35 deletions
Android.mk
with
60 additions
and
35 deletions
Android.mk
+
60
−
35
View file @
43a0a8e1
...
@@ -178,51 +178,32 @@ else
...
@@ -178,51 +178,32 @@ else
SHAREDLIB_EXT
=
so
SHAREDLIB_EXT
=
so
endif
endif
#################################
include
$(CLEAR_VARS)
include
$(CLEAR_VARS)
LOCAL_MODULE
:=
selinux_policy
LOCAL_MODULE
:=
selinux_policy
LOCAL_MODULE_TAGS
:=
optional
LOCAL_MODULE_TAGS
:=
optional
# Include SELinux policy. We do this here because different modules
# need to be included based on the value of PRODUCT_SEPOLICY_SPLIT. This
# type of conditional inclusion cannot be done in top-level files such
# as build/target/product/embedded.mk.
# This conditional inclusion closely mimics the conditional logic
# inside init/init.cpp for loading SELinux policy from files.
# Include precompiled policy, unless told otherwise.
ifneq
($(PRODUCT_PRECOMPILED_SEPOLICY),false)
LOCAL_REQUIRED_MODULES
+=
\
LOCAL_REQUIRED_MODULES
+=
\
precompiled_sepolicy
\
selinux_policy_nonsystem
\
precompiled_sepolicy.plat_and_mapping.sha256
\
selinux_policy_system
\
endif
# ($(PRODUCT_PRECOMPILED_SEPOLICY),false)
ifneq
($(PRODUCT_SEPOLICY_SPLIT),true)
include
$(BUILD_PHONY_PACKAGE)
# The following files are only allowed for non-Treble devices.
LOCAL_REQUIRED_MODULES
+=
\
sepolicy
\
vendor_service_contexts
\
endif
# ($(PRODUCT_SEPOLICY_SPLIT),true)
include
$(CLEAR_VARS)
LOCAL_MODULE
:=
selinux_policy_system
# These build targets are not used on non-Treble devices. However, we build these to avoid
# These build targets are not used on non-Treble devices. However, we build these to avoid
# divergence between Treble and non-Treble devices.
# divergence between Treble and non-Treble devices.
LOCAL_REQUIRED_MODULES
+=
\
LOCAL_REQUIRED_MODULES
+=
\
$(
platform_mapping_file
)
\
$(
platform_mapping_file
)
\
$(
addsuffix .cil,
$(
PLATFORM_SEPOLICY_COMPAT_VERSIONS
))
\
$(
addsuffix .cil,
$(
PLATFORM_SEPOLICY_COMPAT_VERSIONS
))
\
plat_pub_versioned.cil
\
vendor_sepolicy.cil
\
plat_sepolicy.cil
\
plat_sepolicy.cil
\
plat_and_mapping_sepolicy.cil.sha256
\
plat_and_mapping_sepolicy.cil.sha256
\
secilc
\
secilc
\
plat_sepolicy_vers.txt
\
LOCAL_REQUIRED_MODULES
+=
\
LOCAL_REQUIRED_MODULES
+=
\
build_sepolicy
\
build_sepolicy
\
vendor_file_contexts
\
vendor_mac_permissions.xml
\
vendor_property_contexts
\
vendor_seapp_contexts
\
vendor_hwservice_contexts
\
plat_file_contexts
\
plat_file_contexts
\
plat_mac_permissions.xml
\
plat_mac_permissions.xml
\
plat_property_contexts
\
plat_property_contexts
\
...
@@ -230,7 +211,16 @@ LOCAL_REQUIRED_MODULES += \
...
@@ -230,7 +211,16 @@ LOCAL_REQUIRED_MODULES += \
plat_service_contexts
\
plat_service_contexts
\
plat_hwservice_contexts
\
plat_hwservice_contexts
\
searchpolicy
\
searchpolicy
\
vndservice_contexts
\
# This conditional inclusion closely mimics the conditional logic
# inside init/init.cpp for loading SELinux policy from files.
ifneq
($(PRODUCT_SEPOLICY_SPLIT),true)
# The following files are only allowed for non-Treble devices.
LOCAL_REQUIRED_MODULES
+=
\
sepolicy
\
vendor_service_contexts
\
endif
# ($(PRODUCT_SEPOLICY_SPLIT),true)
ifneq
($(TARGET_BUILD_VARIANT), user)
ifneq
($(TARGET_BUILD_VARIANT), user)
LOCAL_REQUIRED_MODULES
+=
\
LOCAL_REQUIRED_MODULES
+=
\
...
@@ -248,6 +238,48 @@ LOCAL_REQUIRED_MODULES += \
...
@@ -248,6 +238,48 @@ LOCAL_REQUIRED_MODULES += \
endif
endif
endif
endif
ifneq
($(PLATFORM_SEPOLICY_VERSION),$(TOT_SEPOLICY_VERSION))
LOCAL_REQUIRED_MODULES
+=
\
sepolicy_freeze_test
\
endif
# ($(PLATFORM_SEPOLICY_VERSION),$(TOT_SEPOLICY_VERSION))
include
$(BUILD_PHONY_PACKAGE)
#################################
include
$(CLEAR_VARS)
LOCAL_MODULE
:=
selinux_policy_nonsystem
# Include precompiled policy, unless told otherwise.
ifneq
($(PRODUCT_PRECOMPILED_SEPOLICY),false)
LOCAL_REQUIRED_MODULES
+=
\
precompiled_sepolicy
\
precompiled_sepolicy.plat_and_mapping.sha256
\
vendor_file_contexts
\
vendor_mac_permissions.xml
\
vendor_property_contexts
\
vendor_seapp_contexts
\
vendor_hwservice_contexts
\
endif
# ($(PRODUCT_PRECOMPILED_SEPOLICY),false)
# These build targets are not used on non-Treble devices. However, we build these to avoid
# divergence between Treble and non-Treble devices.
LOCAL_REQUIRED_MODULES
+=
\
plat_pub_versioned.cil
\
vendor_sepolicy.cil
\
plat_sepolicy_vers.txt
\
LOCAL_REQUIRED_MODULES
+=
\
vendor_file_contexts
\
vendor_mac_permissions.xml
\
vendor_property_contexts
\
vendor_seapp_contexts
\
vendor_hwservice_contexts
\
vndservice_contexts
\
ifdef
BOARD_ODM_SEPOLICY_DIRS
ifdef
BOARD_ODM_SEPOLICY_DIRS
LOCAL_REQUIRED_MODULES
+=
\
LOCAL_REQUIRED_MODULES
+=
\
odm_sepolicy.cil
\
odm_sepolicy.cil
\
...
@@ -257,13 +289,6 @@ LOCAL_REQUIRED_MODULES += \
...
@@ -257,13 +289,6 @@ LOCAL_REQUIRED_MODULES += \
odm_hwservice_contexts
\
odm_hwservice_contexts
\
odm_mac_permissions.xml
odm_mac_permissions.xml
endif
endif
ifneq
($(PLATFORM_SEPOLICY_VERSION),$(TOT_SEPOLICY_VERSION))
LOCAL_REQUIRED_MODULES
+=
\
sepolicy_freeze_test
\
endif
# ($(PLATFORM_SEPOLICY_VERSION),$(TOT_SEPOLICY_VERSION))
include
$(BUILD_PHONY_PACKAGE)
include
$(BUILD_PHONY_PACKAGE)
#################################
#################################
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment