From 20844de700df5a81ec115a762ae4a1624df1a29a Mon Sep 17 00:00:00 2001 From: Michael Shigorin Date: Sat, 30 Jul 2011 15:56:56 +0400 Subject: [PATCH] rough bootloader selection draft (grub/lilo) NB: needs installer-distro-altlinux-generic = 6.0-alt2 as it doesn't require alterator-grub indefinitely --- distro.mk | 2 +- features.in/bootloader/README | 9 +++++++++ features.in/bootloader/config.mk | 6 ++++++ pkg.in/lists/tagged/basesystem,alterator | 1 - sub.in/install2/image-scripts.d/10bootloader | 5 +++++ 5 files changed, 21 insertions(+), 2 deletions(-) create mode 100644 features.in/bootloader/README create mode 100644 features.in/bootloader/config.mk create mode 100755 sub.in/install2/image-scripts.d/10bootloader diff --git a/distro.mk b/distro.mk index 03c0a9e8..2c1d1a5a 100644 --- a/distro.mk +++ b/distro.mk @@ -64,7 +64,7 @@ distro/minicd: distro/server-base distro/desktop-base: distro/installer sub/main \ use/syslinux/ui-vesamenu use/x11/xorg -distro/icewm: distro/desktop-base use/lowmem use/x11/xdm use/x11/runlevel5 +distro/icewm: distro/desktop-base use/lowmem use/x11/xdm use/x11/runlevel5 use/bootloader/lilo @$(call add,BASE_LISTS,$(call tags,icewm desktop)) # NB: if there are too many screens above, it might make sense to distro.d/ diff --git a/features.in/bootloader/README b/features.in/bootloader/README new file mode 100644 index 00000000..96dd51d9 --- /dev/null +++ b/features.in/bootloader/README @@ -0,0 +1,9 @@ +Добавление установки загрузчика основной системы, затребованного +посредством указания "grub" или "lilo" в BASE_BOOTLOADER. + +Соответствующий модуль alterator добавляется в устанавливаемую +систему (он НЕ должен требоваться пакету installer-distro-*) +и требует пакет выбранного загрузчика. + +Реализация экспериментальная (нужно модуляризовать installer-steps), +завязана на installer-distro-altlinux-generic = 6.0-alt2. diff --git a/features.in/bootloader/config.mk b/features.in/bootloader/config.mk new file mode 100644 index 00000000..3ba7a794 --- /dev/null +++ b/features.in/bootloader/config.mk @@ -0,0 +1,6 @@ +# TODO: invent something prettier (think "lilo+grub" -- or error out?) +# - add,BASE_PACKAGES,alterator-$* is overly additive +# - remember .base if adding yet another *_PACKAGES +use/bootloader/grub use/bootloader/lilo: use/bootloader/%: + @$(call set,GLOBAL_BASE_BOOTLOADER,$*) + @$(call add,BASE_PACKAGES,alterator-$$(GLOBAL_BASE_BOOTLOADER)) diff --git a/pkg.in/lists/tagged/basesystem,alterator b/pkg.in/lists/tagged/basesystem,alterator index 8211701c..087d3926 100644 --- a/pkg.in/lists/tagged/basesystem,alterator +++ b/pkg.in/lists/tagged/basesystem,alterator @@ -1,4 +1,3 @@ -alterator-grub alterator-root alterator-users alterator-net-eth diff --git a/sub.in/install2/image-scripts.d/10bootloader b/sub.in/install2/image-scripts.d/10bootloader new file mode 100755 index 00000000..6755979f --- /dev/null +++ b/sub.in/install2/image-scripts.d/10bootloader @@ -0,0 +1,5 @@ +#!/bin/sh +# FIXME: test run for installer-distro-altlinux-generic 6.0-alt2 +# NB: grub is currently the default in ALT Linux + +sed -i "s/^grub$/$GLOBAL_BASE_BOOTLOADER/" /usr/share/install2/installer-steps