Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 1 | version := $(version_under_treble_tests) |
| 2 | |
| 3 | include $(CLEAR_VARS) |
| 4 | ################################# |
| 5 | # build this target to ensure the compat permissions files all build against the current policy |
| 6 | # |
| 7 | LOCAL_MODULE := $(version)_compat_test |
| 8 | LOCAL_REQUIRED_MODULES := $(version).compat.cil |
Jooyung Han | 749cf93 | 2019-05-30 01:05:43 +0900 | [diff] [blame] | 9 | LOCAL_MODULE_CLASS := FAKE |
| 10 | LOCAL_MODULE_TAGS := optional |
| 11 | |
| 12 | include $(BUILD_SYSTEM)/base_rules.mk |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 13 | |
| 14 | all_cil_files := \ |
| 15 | $(built_plat_cil) \ |
| 16 | $(built_plat_mapping_cil) \ |
| 17 | $(built_pub_vers_cil) \ |
| 18 | $(built_vendor_cil) \ |
| 19 | $(ALL_MODULES.$(version).compat.cil.BUILT) \ |
| 20 | |
Bowgo Tsai | 948934b | 2019-08-29 17:12:11 +0800 | [diff] [blame] | 21 | ifdef HAS_SYSTEM_EXT_SEPOLICY |
Bowgo Tsai | ac38125 | 2019-10-04 14:34:18 +0800 | [diff] [blame] | 22 | all_cil_files += $(built_system_ext_cil) |
| 23 | endif |
Bowgo Tsai | 948934b | 2019-08-29 17:12:11 +0800 | [diff] [blame] | 24 | |
Bowgo Tsai | ac38125 | 2019-10-04 14:34:18 +0800 | [diff] [blame] | 25 | ifdef HAS_SYSTEM_EXT_PUBLIC_SEPOLICY |
| 26 | all_cil_files += $(built_system_ext_mapping_cil) |
Bowgo Tsai | 948934b | 2019-08-29 17:12:11 +0800 | [diff] [blame] | 27 | endif |
| 28 | |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 29 | ifdef HAS_PRODUCT_SEPOLICY |
Bowgo Tsai | 7c4150c | 2019-10-04 15:36:05 +0800 | [diff] [blame] | 30 | all_cil_files += $(built_product_cil) |
| 31 | endif |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 32 | |
Bowgo Tsai | 7c4150c | 2019-10-04 15:36:05 +0800 | [diff] [blame] | 33 | ifdef HAS_PRODUCT_PUBLIC_SEPOLICY |
| 34 | all_cil_files += $(built_product_mapping_cil) |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 35 | endif |
| 36 | |
| 37 | ifdef BOARD_ODM_SEPOLICY_DIRS |
| 38 | all_cil_files += $(built_odm_cil) |
| 39 | endif |
| 40 | |
Jooyung Han | 749cf93 | 2019-05-30 01:05:43 +0900 | [diff] [blame] | 41 | $(LOCAL_BUILT_MODULE): PRIVATE_CIL_FILES := $(all_cil_files) |
| 42 | $(LOCAL_BUILT_MODULE): $(HOST_OUT_EXECUTABLES)/secilc $(HOST_OUT_EXECUTABLES)/sepolicy-analyze $(all_cil_files) |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 43 | @mkdir -p $(dir $@) |
Jeff Vander Stoep | 87fabf3 | 2019-05-17 12:39:41 -0700 | [diff] [blame] | 44 | $(hide) $< -m -N -M true -G -c $(POLICYVERS) $(PRIVATE_CIL_FILES) -o $@ -f /dev/null |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 45 | |
Jeff Vander Stoep | 564e292 | 2019-05-02 13:48:44 -0700 | [diff] [blame] | 46 | all_cil_files := |
| 47 | version := |
| 48 | version_under_treble_tests := |