diff --git a/ChangeLog b/ChangeLog index f1790926f..aa5d3f2cd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2008-07-11 Robert Millan + + * util/grub.d/40_custom.in: New file. Example on how to add custom + entries to /etc/grub.d. + * conf/common.rmk (%, update-grub_SCRIPTS, CLEANFILES): Install + 40_custom (implicitly, by merging all the grub.d rules). + 2008-07-11 Pavel Roskin * commands/read.c (grub_getline): Fix invalid memory access. diff --git a/DISTLIST b/DISTLIST index 7b9598cde..d5eb64540 100644 --- a/DISTLIST +++ b/DISTLIST @@ -327,6 +327,7 @@ util/grub.d/00_header.in util/grub.d/10_hurd.in util/grub.d/10_linux.in util/grub.d/30_os-prober.in +util/grub.d/40_custom.in util/grub.d/README util/grub-emu.c util/grub-mkdevicemap.c diff --git a/conf/common.mk b/conf/common.mk index 0cfa37d9b..9943d6d06 100644 --- a/conf/common.mk +++ b/conf/common.mk @@ -470,29 +470,11 @@ update-grub_lib: util/update-grub_lib.in config.status lib_DATA += update-grub_lib CLEANFILES += update-grub_lib -00_header: util/grub.d/00_header.in config.status +%: util/grub.d/%.in config.status ./config.status --file=$@:$< chmod +x $@ -update-grub_SCRIPTS += 00_header -CLEANFILES += 00_header - -10_linux: util/grub.d/10_linux.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 10_linux -CLEANFILES += 10_linux - -10_hurd: util/grub.d/10_hurd.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 10_hurd -CLEANFILES += 10_hurd - -30_os-prober: util/grub.d/30_os-prober.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 30_os-prober -CLEANFILES += 30_os-prober +update-grub_SCRIPTS = 00_header 10_linux 10_hurd 30_os-prober 40_custom +CLEANFILES += $(update-grub_SCRIPTS) update-grub_DATA += util/grub.d/README diff --git a/conf/common.rmk b/conf/common.rmk index ecb8e040b..b403b0437 100644 --- a/conf/common.rmk +++ b/conf/common.rmk @@ -112,29 +112,11 @@ update-grub_lib: util/update-grub_lib.in config.status lib_DATA += update-grub_lib CLEANFILES += update-grub_lib -00_header: util/grub.d/00_header.in config.status +%: util/grub.d/%.in config.status ./config.status --file=$@:$< chmod +x $@ -update-grub_SCRIPTS += 00_header -CLEANFILES += 00_header - -10_linux: util/grub.d/10_linux.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 10_linux -CLEANFILES += 10_linux - -10_hurd: util/grub.d/10_hurd.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 10_hurd -CLEANFILES += 10_hurd - -30_os-prober: util/grub.d/30_os-prober.in config.status - ./config.status --file=$@:$< - chmod +x $@ -update-grub_SCRIPTS += 30_os-prober -CLEANFILES += 30_os-prober +update-grub_SCRIPTS = 00_header 10_linux 10_hurd 30_os-prober 40_custom +CLEANFILES += $(update-grub_SCRIPTS) update-grub_DATA += util/grub.d/README diff --git a/util/grub.d/40_custom.in b/util/grub.d/40_custom.in new file mode 100644 index 000000000..e16d6e3d6 --- /dev/null +++ b/util/grub.d/40_custom.in @@ -0,0 +1,3 @@ +#!/bin/sh +exec tail -n +3 $0 +# This file is an example on how to add custom entries