[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Explicitly pass grub to install, install-grub*, install-grub
From: |
Danny Milosavljevic |
Subject: |
Re: [PATCH] Explicitly pass grub to install, install-grub*, install-grub, initialize-hard-disk and qemu-image. |
Date: |
Fri, 11 Nov 2016 16:12:51 +0100 |
Hi Ludo,
> I prefer that setting PATH to point to the right GRUB, rather than
> having to carry the directory name of GRUB in 10 different places.
I much prefer not having a magical non-Guile variable influence which
bootloader (!) is installed. Of all things this is the most sensitive part of
the installation process - if the bootloader doesn't work you can't even
emergency-boot - and it depends on PATH being set correctly at some remote
place.
I think it's much better not to have spooky action at a distance.
> This is the approach taken in several places, such as (gnu system vm):
> we set PATH, and then we can happily call functions that in turn expect
> commands in $PATH.
>
> Danny, what led you to this patch? :-)
When I read the source I couldn't find which grub-install executable it invokes
(and how that even works) and neither could anyone on the list for months (I
asked). I think for maintenance it's much better not to use PATH but rather be
explicit about which package it is.
This is part of the u-boot and grub-efi effort. Of course it's optional to do
it - grub, u-boot and grub-efi can work with PATH as well. But should they?
However if we aren't explicit about it then the next person will have to search
around just like I did.
Also it would keep being a Damocles' sword over our heads - if someone modifies
PATH (in the Guix source code, by accident) it will just pick up a random grub
(maybe Debian's if it's installed on a foreign distro - who knows?).