接前一篇文章:SELinux refpolicy详解(10)
三、refpolicy内容详解
上一回讲解完了refpolicy源码根目录下的INSTALL文件。本回继续讲解源码根目录下的其它文件。第四个来讲解refpolicy源码根目录下的Rules.monolithic文件。
4. Rules.monolithic
文件路径:refpolicy源码根目录/Rules.monolithic。
文件内容如下:
########################################
#
# Rules and Targets for building monolithic policies
## determine the policy version and current kernel version if possible
pv := $(shell $(CHECKPOLICY) -V |cut -f 1 -d ' ')
kv := $(shell $(policyvers))# dont print version warnings if we are unable to determine
# the currently running kernel's policy version
ifeq "$(kv)" ""kv := $(pv)
endif# dont print version warnings if we specified a lower version than the kernel supports
ifneq "$(OUTPUT_POLICY)"