Gentoo Archives: gentoo-dev

From: Tom H <tomh0665@×××××.com>
To: Gentoo Devel <gentoo-dev@l.g.o>
Subject: Re: [gentoo-dev] grub-2 configuration
Date: Wed, 19 Oct 2016 19:22:06
Message-Id: CAOdo=SxBDkO74FUjg9T554fCV+STs1XaLXnP2shenasRRNZ7BA@mail.gmail.com
In Reply to: Re: [gentoo-dev] grub-2 configuration by Joakim Tjernlund
1 On Tue, Oct 18, 2016 at 1:20 PM, Joakim Tjernlund
2 <Joakim.Tjernlund@××××××××.com> wrote:
3 > On Tue, 2016-10-18 at 12:45 -0400, Tom H wrote:
4 >> On Tue, Oct 11, 2016 at 10:54 AM, M. J. Everitt <m.j.everitt@×××.org> wrote:
5 >>> On 11/10/16 15:42, Tom H wrote:
6 >>>>
7 >>>> You can use exactly the same text in 40_grub that you'd use in
8 >>>> grub.cfg and have the latter generated.
9 >>>
10 >>> That's a useful tit-bit .. thanks!
11 >>
12 >> You're welcome.
13 >>
14 >> I doubt that the grub developers intended 40_custom to be the only
15 >> "/etc/grub.d/" file to be executed but it's practical for generating a
16 >> simple grub.cfg. This is what I use in a Debian VM:
17 >
18 > We still use grub-1 and I really like the automatic generation of new
19 > grub menu entries using genkernel --bootloader=grub, does this work
20 > with grub2 as well?
21
22 It looks ike you can pass "--bootloader=grub2" but it's not documented
23 in the man page because gen_bootloader.sh has:
24
25 set_bootloader() {
26 case "${BOOTLOADER}" in
27 grub)
28 set_bootloader_grub
29 ;;
30 grub2)
31 set_bootloader_grub2
32 ;;
33 *)
34 print_warning "Bootloader ${BOOTLOADER} is not currently supported"
35 ;;
36 esac
37 }
38
39 but it looks like, unlike for grub-legacy, you need a grub config file
40 ("/boot/grub{,2}/grub.cfg") to exist.

Replies

Subject Author
Re: [gentoo-dev] grub-2 configuration Joakim Tjernlund <Joakim.Tjernlund@××××××××.com>