hwservice_contexts.mk 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. include $(CLEAR_VARS)
  2. LOCAL_MODULE := plat_hwservice_contexts
  3. LOCAL_MODULE_CLASS := ETC
  4. LOCAL_MODULE_TAGS := optional
  5. LOCAL_MODULE_PATH := $(TARGET_OUT)/etc/selinux
  6. include $(BUILD_SYSTEM)/base_rules.mk
  7. plat_hwsvcfiles := $(call build_policy, hwservice_contexts, $(PLAT_PRIVATE_POLICY))
  8. plat_hwservice_contexts.tmp := $(intermediates)/plat_hwservice_contexts.tmp
  9. $(plat_hwservice_contexts.tmp): PRIVATE_SVC_FILES := $(plat_hwsvcfiles)
  10. $(plat_hwservice_contexts.tmp): PRIVATE_ADDITIONAL_M4DEFS := $(LOCAL_ADDITIONAL_M4DEFS)
  11. $(plat_hwservice_contexts.tmp): $(plat_hwsvcfiles)
  12. @mkdir -p $(dir $@)
  13. $(hide) m4 --fatal-warnings -s $(PRIVATE_ADDITIONAL_M4DEFS) $(PRIVATE_SVC_FILES) > $@
  14. $(LOCAL_BUILT_MODULE): PRIVATE_SEPOLICY := $(built_sepolicy)
  15. $(LOCAL_BUILT_MODULE): $(plat_hwservice_contexts.tmp) $(built_sepolicy) $(HOST_OUT_EXECUTABLES)/checkfc $(ACP)
  16. @mkdir -p $(dir $@)
  17. sed -e 's/#.*$$//' -e '/^$$/d' $< > $@
  18. $(HOST_OUT_EXECUTABLES)/checkfc -e -l $(PRIVATE_SEPOLICY) $@
  19. plat_hwsvcfiles :=
  20. plat_hwservice_contexts.tmp :=
  21. ##################################
  22. include $(CLEAR_VARS)
  23. LOCAL_MODULE := product_hwservice_contexts
  24. LOCAL_MODULE_CLASS := ETC
  25. LOCAL_MODULE_TAGS := optional
  26. LOCAL_MODULE_PATH := $(TARGET_OUT_PRODUCT)/etc/selinux
  27. include $(BUILD_SYSTEM)/base_rules.mk
  28. product_hwsvcfiles := $(call build_policy, hwservice_contexts, $(PRODUCT_PRIVATE_POLICY))
  29. product_hwservice_contexts.tmp := $(intermediates)/product_hwservice_contexts.tmp
  30. $(product_hwservice_contexts.tmp): PRIVATE_SVC_FILES := $(product_hwsvcfiles)
  31. $(product_hwservice_contexts.tmp): PRIVATE_ADDITIONAL_M4DEFS := $(LOCAL_ADDITIONAL_M4DEFS)
  32. $(product_hwservice_contexts.tmp): $(product_hwsvcfiles)
  33. @mkdir -p $(dir $@)
  34. $(hide) m4 --fatal-warnings -s $(PRIVATE_ADDITIONAL_M4DEFS) $(PRIVATE_SVC_FILES) > $@
  35. $(LOCAL_BUILT_MODULE): PRIVATE_SEPOLICY := $(built_sepolicy)
  36. $(LOCAL_BUILT_MODULE): $(product_hwservice_contexts.tmp) $(built_sepolicy) $(HOST_OUT_EXECUTABLES)/checkfc
  37. @mkdir -p $(dir $@)
  38. sed -e 's/#.*$$//' -e '/^$$/d' $< > $@
  39. $(hide) $(HOST_OUT_EXECUTABLES)/checkfc -e -l $(PRIVATE_SEPOLICY) $@
  40. product_hwsvcfiles :=
  41. product_hwservice_contexts.tmp :=
  42. ##################################
  43. include $(CLEAR_VARS)
  44. LOCAL_MODULE := vendor_hwservice_contexts
  45. LOCAL_MODULE_CLASS := ETC
  46. LOCAL_MODULE_TAGS := optional
  47. LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR)/etc/selinux
  48. include $(BUILD_SYSTEM)/base_rules.mk
  49. vendor_hwsvcfiles := $(call build_policy, hwservice_contexts, $(PLAT_VENDOR_POLICY) $(BOARD_VENDOR_SEPOLICY_DIRS) $(REQD_MASK_POLICY))
  50. vendor_hwservice_contexts.tmp := $(intermediates)/vendor_hwservice_contexts.tmp
  51. $(vendor_hwservice_contexts.tmp): PRIVATE_SVC_FILES := $(vendor_hwsvcfiles)
  52. $(vendor_hwservice_contexts.tmp): PRIVATE_ADDITIONAL_M4DEFS := $(LOCAL_ADDITIONAL_M4DEFS)
  53. $(vendor_hwservice_contexts.tmp): $(vendor_hwsvcfiles)
  54. @mkdir -p $(dir $@)
  55. $(hide) m4 --fatal-warnings -s $(PRIVATE_ADDITIONAL_M4DEFS) $(PRIVATE_SVC_FILES) > $@
  56. $(LOCAL_BUILT_MODULE): PRIVATE_SEPOLICY := $(built_sepolicy)
  57. $(LOCAL_BUILT_MODULE): $(vendor_hwservice_contexts.tmp) $(built_sepolicy) $(HOST_OUT_EXECUTABLES)/checkfc $(ACP)
  58. @mkdir -p $(dir $@)
  59. sed -e 's/#.*$$//' -e '/^$$/d' $< > $@
  60. $(hide) $(HOST_OUT_EXECUTABLES)/checkfc -e -l $(PRIVATE_SEPOLICY) $@
  61. vendor_hwsvcfiles :=
  62. vendor_hwservice_contexts.tmp :=
  63. ##################################
  64. include $(CLEAR_VARS)
  65. LOCAL_MODULE := odm_hwservice_contexts
  66. LOCAL_MODULE_CLASS := ETC
  67. LOCAL_MODULE_TAGS := optional
  68. LOCAL_MODULE_PATH := $(TARGET_OUT_ODM)/etc/selinux
  69. include $(BUILD_SYSTEM)/base_rules.mk
  70. odm_hwsvcfiles := $(call build_policy, hwservice_contexts, $(BOARD_ODM_SEPOLICY_DIRS))
  71. odm_hwservice_contexts.tmp := $(intermediates)/odm_hwservice_contexts.tmp
  72. $(odm_hwservice_contexts.tmp): PRIVATE_SVC_FILES := $(odm_hwsvcfiles)
  73. $(odm_hwservice_contexts.tmp): PRIVATE_ADDITIONAL_M4DEFS := $(LOCAL_ADDITIONAL_M4DEFS)
  74. $(odm_hwservice_contexts.tmp): $(odm_hwsvcfiles)
  75. @mkdir -p $(dir $@)
  76. $(hide) m4 --fatal-warnings -s $(PRIVATE_ADDITIONAL_M4DEFS) $(PRIVATE_SVC_FILES) > $@
  77. $(LOCAL_BUILT_MODULE): PRIVATE_SEPOLICY := $(built_sepolicy)
  78. $(LOCAL_BUILT_MODULE): $(odm_hwservice_contexts.tmp) $(built_sepolicy) $(HOST_OUT_EXECUTABLES)/checkfc $(ACP)
  79. @mkdir -p $(dir $@)
  80. sed -e 's/#.*$$//' -e '/^$$/d' $< > $@
  81. $(hide) $(HOST_OUT_EXECUTABLES)/checkfc -e -l $(PRIVATE_SEPOLICY) $@
  82. odm_hwsvcfiles :=
  83. odm_hwservice_contexts.tmp :=