From: Danny Milosavljevic <dannym@scratchpost.org>
To: Stefan <stefan-guix@vodafonemail.de>
Cc: 41066@debbugs.gnu.org, Mathieu Othacehe <othacehe@gnu.org>,
Efraim Flashner <efraim@flashner.co.il>,
Maxim Cournoyer <maxim.cournoyer@gmail.com>
Subject: [bug#41066] [PATCH] gnu: bootloader: Support for chain loading.
Date: Wed, 18 Nov 2020 19:05:59 +0100 [thread overview]
Message-ID: <20201118190559.1f9fed82@scratchpost.org> (raw)
In-Reply-To: <F5D06DBE-69B7-412F-A42A-7AE6B629A931@vodafonemail.de>
[-- Attachment #1: Type: text/plain, Size: 3402 bytes --]
Hi Stefan,
On Tue, 17 Nov 2020 21:27:42 +0100
Stefan <stefan-guix@vodafonemail.de> wrote:
> For example the profile contains at least these folders from the grub package, plus the collection/:
>
> /gnu/store/…-bootloader-profile/collection
> /gnu/store/…-bootloader-profile/etc
> /gnu/store/…-bootloader-profile/share
> /gnu/store/…-bootloader-profile/lib
> /gnu/store/…-bootloader-profile/bin
> /gnu/store/…-bootloader-profile/sbin
Ohhh, that's right. It actually contains the grub installer--which it got from
the grub-efi derivation. The actual boot EFI file is not in the grub-efi
derivation.
I wonder if it is possible (one day!) to have a package that actually contains
the EFI boot file that the grub installer generated. That would be a lot
nicer--though I'm not sure whether that stuff depends on the system and thus
cannot be "pre-generated".
> But the /boot/ folder finally contains something like this, with most of it being content from the collection/, where the GRUB files get installed belaw /boot/efi/:
>
> /boot/bcm2710-rpi-3-b.dtb
> /boot/bootcode.bin
> /boot/bootloader.txt
> /boot/config.txt
> /boot/custom.txt
> /boot/efi/
> /boot/fixup.dat
> /boot/gnu/
> /boot/grub/
> /boot/overlays/
> /boot/u-boot.bin
>
> Actually one could say that the profile hook is a kind of ‘pre-installer’ for everything not related to GRUB, able to prepare everything, but unable to write into the /boot folder.
>
> > If there are no good reasons to do it like that, I'd just put the
> > profile into $output directly instead--it's easier to understand, and also it's
> > how other profiles are being used.
>
> Not having the collection folder would mean that the installer would need to assume much more about the result of the profile hook, to copy the right files to /boot.
I agree. Let's leave it inside subdir "collection".
> > (2) The COPY-FILES? flag is kinda weird.
> > I would prefer if INSTALLER just defaulted to a procedure that: does copy
> > files, and then calls the final bootloader installer.
> > If the user doesn't want it then the user could still pass a INSTALLER
> > that doesn't (for example the user could pass #:installer
> > (bootloader-installer final-bootloader)).
>
> Agreed.
> Another possibility would be to remove the collection folder within a hook.
I don't like that that much because it's mutating too much and thus
composability goes down.
> > I would prefer if the user would just change the INSTALLER in the case he wants
> > to not use the profile (which is kinda weird?!) or pack it or whatever.
>
> OK, I see, in case of a custom installer we can skip the copying completely. That makes sense.
Could you send an updated patch that does it like that? Or do you rather want
the old variant ?
> > (3) Why isn't the final bootloader installed last? I would have expected
> > it to be installed last so that if it does packing of the profile contents
> > in order to quickly find it at boot, it would have to have all the files
> > of the profiles already, no?
>
> I thought about the order as well. My conclusion was that a file from the collection should be able to overwrite a file installed from final-bootloader, for example to install own device-tree files.
Yeah, that makes sense--if a little unusual (thus should be documented).
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2020-11-18 18:11 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-03 23:34 [bug#41066] [PATCH] gnu: grub: Support for chain loading Stefan
2020-05-24 11:13 ` Danny Milosavljevic
2020-05-24 13:21 ` Stefan
2020-10-04 16:31 ` [bug#41066] [PATCH] gnu: bootloader: " Stefan
2020-10-10 9:31 ` Stefan
2020-10-18 11:20 ` Stefan
2020-10-18 11:21 ` Stefan
2020-10-22 17:46 ` Danny Milosavljevic
2020-10-23 12:48 ` Ludovic Courtès
2020-10-24 1:30 ` Danny Milosavljevic
2020-10-24 16:22 ` Ludovic Courtès
2020-10-25 0:33 ` Danny Milosavljevic
2020-10-25 16:58 ` Stefan
2020-10-25 16:59 ` Stefan
2020-11-02 15:42 ` Danny Milosavljevic
2020-11-02 16:21 ` Mathieu Othacehe
2020-11-03 9:07 ` Ludovic Courtès
2020-11-03 9:32 ` Mathieu Othacehe
2020-11-07 21:14 ` Stefan
2020-11-07 21:15 ` Stefan
2020-10-26 10:37 ` Ludovic Courtès
2020-11-16 9:33 ` bug#41066: " Danny Milosavljevic
2020-11-17 14:26 ` [bug#41066] " Stefan
2020-11-17 15:47 ` Danny Milosavljevic
2020-11-17 16:17 ` Danny Milosavljevic
2020-11-17 20:27 ` Stefan
2020-11-18 18:05 ` Danny Milosavljevic [this message]
2020-11-18 18:20 ` Stefan
2020-11-28 22:14 ` [bug#41066] [PATCH] gnu: bootloader: Improve support " Stefan
2020-12-12 17:14 ` Stefan
2020-12-13 14:42 ` Danny Milosavljevic
2020-12-13 17:24 ` Stefan
2020-12-13 19:28 ` Stefan
2020-12-28 19:02 ` Stefan
2021-03-27 16:48 ` bug#41066: " Stefan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201118190559.1f9fed82@scratchpost.org \
--to=dannym@scratchpost.org \
--cc=41066@debbugs.gnu.org \
--cc=efraim@flashner.co.il \
--cc=maxim.cournoyer@gmail.com \
--cc=othacehe@gnu.org \
--cc=stefan-guix@vodafonemail.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).