blob: 1a7d06efaa00a2c30463a640f8ec73df117c7c20 [file] [log] [blame]
Dan Cashman36ee91d2017-07-07 14:59:51 -07001# Command to turn collection of policy files into a policy.conf file to be
2# processed by checkpolicy
3define transform-policy-to-conf
4@mkdir -p $(dir $@)
Dan Willemsen3c3e59b2019-06-19 10:52:50 -07005$(hide) $(M4) --fatal-warnings $(PRIVATE_ADDITIONAL_M4DEFS) \
Dan Cashman36ee91d2017-07-07 14:59:51 -07006 -D mls_num_sens=$(PRIVATE_MLS_SENS) -D mls_num_cats=$(PRIVATE_MLS_CATS) \
Joel Galenson8c72eea2018-03-07 15:36:29 -08007 -D target_build_variant=$(PRIVATE_TARGET_BUILD_VARIANT) \
Dan Cashman36ee91d2017-07-07 14:59:51 -07008 -D target_with_dexpreopt=$(WITH_DEXPREOPT) \
9 -D target_arch=$(PRIVATE_TGT_ARCH) \
10 -D target_with_asan=$(PRIVATE_TGT_WITH_ASAN) \
Pirama Arumuga Nainarce9c0c52019-06-13 15:05:15 -070011 -D target_with_native_coverage=$(PRIVATE_TGT_WITH_NATIVE_COVERAGE) \
Steven Moreland763697d2017-11-09 11:24:56 -080012 -D target_full_treble=$(PRIVATE_SEPOLICY_SPLIT) \
Jaekyun Seoke4971452017-10-19 16:54:49 +090013 -D target_compatible_property=$(PRIVATE_COMPATIBLE_PROPERTY) \
Tri Vo77c44fc2018-06-05 14:11:08 -070014 -D target_exclude_build_test=$(PRIVATE_EXCLUDE_BUILD_TEST) \
Dan Cashman36ee91d2017-07-07 14:59:51 -070015 $(PRIVATE_TGT_RECOVERY) \
Dan Willemsen3c3e59b2019-06-19 10:52:50 -070016 -s $(PRIVATE_POLICY_FILES) > $@
Dan Cashman36ee91d2017-07-07 14:59:51 -070017endef
18.KATI_READONLY := transform-policy-to-conf