[PATCH 0/2] Allow editenv to follow symlinks to find/make grubenv

2014-09-04 Thread Peter Jones
Hi, This is a patch series to allow grub-editenv and related utilities to follow symbolic links when finding its config file. This allows, for example, the ability to have two builds of grub for different platforms that have different prefixes set, but still use the same userland grub utilities.

[PATCH 1/2] Add grub_util_readlink()

2014-09-04 Thread Peter Jones
Add grub_util_readlink(). This requires pulling in stat and readlink from gnulib, which pulls in stat and related headers, but after that the implementation is straightforward. Signed-off-by: Peter Jones Reviewed-by: Adam Jackson --- grub-core/gnulib/Makefile.am | 177 +++- grub-c

[PATCH 2/2] Make editenv chase symlinks including those across devices.

2014-09-04 Thread Peter Jones
This lets us make /boot/grub2/grubenv a symlink to /boot/efi/EFI/fedora/grubenv even though they're different mount points, which allows /usr/bin/grub2-editenv to be the same across platforms (i.e. UEFI vs BIOS). Signed-off-by: Peter Jones Reviewed-by: Adam Jackson --- Makefile.util.def | 9 ++