Dan Cashman | 36ee91d | 2017-07-07 14:59:51 -0700 | [diff] [blame] | 1 | # Command to turn collection of policy files into a policy.conf file to be |
| 2 | # processed by checkpolicy |
| 3 | define transform-policy-to-conf |
| 4 | @mkdir -p $(dir $@) |
Dan Willemsen | 3c3e59b | 2019-06-19 10:52:50 -0700 | [diff] [blame] | 5 | $(hide) $(M4) --fatal-warnings $(PRIVATE_ADDITIONAL_M4DEFS) \ |
Dan Cashman | 36ee91d | 2017-07-07 14:59:51 -0700 | [diff] [blame] | 6 | -D mls_num_sens=$(PRIVATE_MLS_SENS) -D mls_num_cats=$(PRIVATE_MLS_CATS) \ |
Joel Galenson | 8c72eea | 2018-03-07 15:36:29 -0800 | [diff] [blame] | 7 | -D target_build_variant=$(PRIVATE_TARGET_BUILD_VARIANT) \ |
Dan Cashman | 36ee91d | 2017-07-07 14:59:51 -0700 | [diff] [blame] | 8 | -D target_with_dexpreopt=$(WITH_DEXPREOPT) \ |
| 9 | -D target_arch=$(PRIVATE_TGT_ARCH) \ |
| 10 | -D target_with_asan=$(PRIVATE_TGT_WITH_ASAN) \ |
Pirama Arumuga Nainar | ce9c0c5 | 2019-06-13 15:05:15 -0700 | [diff] [blame] | 11 | -D target_with_native_coverage=$(PRIVATE_TGT_WITH_NATIVE_COVERAGE) \ |
Steven Moreland | 763697d | 2017-11-09 11:24:56 -0800 | [diff] [blame] | 12 | -D target_full_treble=$(PRIVATE_SEPOLICY_SPLIT) \ |
Jaekyun Seok | e497145 | 2017-10-19 16:54:49 +0900 | [diff] [blame] | 13 | -D target_compatible_property=$(PRIVATE_COMPATIBLE_PROPERTY) \ |
Inseob Kim | ed59c22 | 2019-09-26 15:14:55 +0900 | [diff] [blame] | 14 | -D target_treble_sysprop_neverallow=$(PRIVATE_TREBLE_SYSPROP_NEVERALLOW) \ |
Tri Vo | 77c44fc | 2018-06-05 14:11:08 -0700 | [diff] [blame] | 15 | -D target_exclude_build_test=$(PRIVATE_EXCLUDE_BUILD_TEST) \ |
Peter Collingbourne | 330ee2c | 2019-10-15 18:10:38 -0700 | [diff] [blame] | 16 | -D target_requires_insecure_execmem_for_swiftshader=$(PRODUCT_REQUIRES_INSECURE_EXECMEM_FOR_SWIFTSHADER) \ |
Dan Cashman | 36ee91d | 2017-07-07 14:59:51 -0700 | [diff] [blame] | 17 | $(PRIVATE_TGT_RECOVERY) \ |
Dan Willemsen | 3c3e59b | 2019-06-19 10:52:50 -0700 | [diff] [blame] | 18 | -s $(PRIVATE_POLICY_FILES) > $@ |
Dan Cashman | 36ee91d | 2017-07-07 14:59:51 -0700 | [diff] [blame] | 19 | endef |
| 20 | .KATI_READONLY := transform-policy-to-conf |