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

Move compatibility files out of prebuilts dir.

The treble compatibility tests check for policy differences between old
and new policy.  To do this correctly, we must not modify the policy which
represents the older policies.  Move the files meant to be changed to a
different location from the ones that are not meant to be touched to avoid
any undesired changes to old policy, e.g. commit:
2bdefd65078d890889672938c6f0d2accdd25bc5

Bug: 36899958
Test: Build-time tests build.
Change-Id: I8fa3947cfae756f37556fb34e1654382e2e48372
parent 124e1f65
No related branches found
No related tags found
No related merge requests found
...@@ -1192,8 +1192,8 @@ $(built_26.0_plat_sepolicy): $(26.0_plat_policy.conf) $(HOST_OUT_EXECUTABLES)/ch ...@@ -1192,8 +1192,8 @@ $(built_26.0_plat_sepolicy): $(26.0_plat_policy.conf) $(HOST_OUT_EXECUTABLES)/ch
# targeting the 26.0 SELinux release. This ensures that our policy will build # targeting the 26.0 SELinux release. This ensures that our policy will build
# when used on a device that has non-platform policy targetting the 26.0 release. # when used on a device that has non-platform policy targetting the 26.0 release.
26.0_compat := $(intermediates)/26.0_compat 26.0_compat := $(intermediates)/26.0_compat
26.0_mapping.cil := $(LOCAL_PATH)/prebuilts/api/26.0/26.0.cil 26.0_mapping.cil := $(LOCAL_PATH)/private/compat/26.0/26.0.cil
26.0_mapping.ignore.cil := $(LOCAL_PATH)/prebuilts/api/26.0/26.0.ignore.cil 26.0_mapping.ignore.cil := $(LOCAL_PATH)/private/compat/26.0/26.0.ignore.cil
26.0_nonplat := $(LOCAL_PATH)/prebuilts/api/26.0/nonplat_sepolicy.cil 26.0_nonplat := $(LOCAL_PATH)/prebuilts/api/26.0/nonplat_sepolicy.cil
$(26.0_compat): PRIVATE_CIL_FILES := \ $(26.0_compat): PRIVATE_CIL_FILES := \
$(built_plat_cil) $(26.0_mapping.cil) $(26.0_nonplat) $(built_plat_cil) $(26.0_mapping.cil) $(26.0_nonplat)
......
File moved
...@@ -223,7 +223,8 @@ def TestNoUnmappedNewTypes(): ...@@ -223,7 +223,8 @@ def TestNoUnmappedNewTypes():
if len(violators) > 0: if len(violators) > 0:
ret += "SELinux: The following types were found added to the policy " ret += "SELinux: The following types were found added to the policy "
ret += "without an entry into the compatibility mapping file(s) found " ret += "without an entry into the compatibility mapping file(s) found "
ret += "in prebuilts/api/" + compatMapping.apiLevel + "/\n" ret += "in private/compat/" + compatMapping.apiLevel + "/"
ret += compatMapping.apiLevel + "[.ignore].cil/n"
ret += " ".join(str(x) for x in sorted(violators)) + "\n" ret += " ".join(str(x) for x in sorted(violators)) + "\n"
return ret return ret
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment