initrd Makefile target
Subsystems (2)
PATCH 1/1 initrd Makefile target
Please consider this patch for inclusion into the new api policy. It creates a initrd target in the policy Makefile. By default it creates /boot/initrd-$(KV) where KV defaults to uname -r. However a user may be creating an initrd for a newly installed kernel, so that obviously could be overridden on the commandline:
make initrd KV=2.6.0-test3
Makefile | 12 ++++++++++++ 1 files changed, 12 insertions(+)
Signature · 7 lines
Chris PeBenito <[email protected]> Developer, SELinux Hardened Gentoo Linux Public Key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xE6AF9243 Key fingerprint = B0E6 877A 883F A57A 8E6A CB00 BC8E E42D E6AF 9243
Makefile +12 -0
@@ -3,6 +3,7 @@ # # Targets: # +# initrd - compile and install the policy configuration, and create a policy initrd. # install - compile and install the policy configuration. # load - compile, install, and load the policy configuration. # reload - compile, install, and load/reload the policy configuration.
@@ -12,6 +13,14 @@ # The default target is 'install'. # +# initrd options +MKINITRD = /sbin/mkinitrd +# kernel version, defaults to current running kernel +KV = $(shell uname -r) +INITRD = /boot/initrd-$(KV) +# extra options +EXTRAOPT = + # Set to y if MLS is enabled in the module. MLS=n
@@ -63,6 +72,9 @@ load: tmp/load +initrd: $(LOADPATH) + $(MKINITRD) $(EXTRAOPT) $(INITRD) $(KV) + policy.conf: $(POLICYFILES) mkdir -p tmp cat $^ > $@
Quoted 5 lines · Chris PeBenito
Please consider this patch for inclusion into the new api policy. It creates a initrd target in the policy
Makefile. By default it creates /boot/initrd-$(KV) where KV defaults touname -r. However a user may be creating an initrd for a newly installed kernel, so that obviously could be overridden on the commandline:
There are at least two different "mkinitrd" programs in common use, the Red Hat one and the Debian one.
This sort of patch is probably best left as a distribution patch, otherwise those of us who use different mkinitrd programs will just have to patch out your changes.
Signature · 10 lines
http://www.coker.com.au/selinux/ My NSA Security Enhanced Linux packages http://www.coker.com.au/bonnie++/ Bonnie++ hard drive benchmark http://www.coker.com.au/postal/ Postal SMTP/POP benchmark http://www.coker.com.au/~russell/ My home page -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.