summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO36
-rw-r--r--.gitignore1
-rw-r--r--0001-00_header-add-GRUB_COLOR_-variables.patch (renamed from 0004-add-GRUB_COLOR_variables.patch)17
-rw-r--r--0002-10_linux-detect-archlinux-initramfs.patch (renamed from 0003-10_linux-detect-archlinux-initramfs.patch)39
-rw-r--r--0003-support-dropins-for-default-configuration.patch28
-rw-r--r--PKGBUILD99
-rw-r--r--grub-libzfs.install17
-rw-r--r--grub.default17
-rw-r--r--grub.install38
-rw-r--r--sbat.csv3
10 files changed, 215 insertions, 80 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 42f08490dd69..ea01613d7909 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,12 +1,12 @@
pkgbase = grub-libzfs
pkgdesc = GNU GRand Unified Bootloader (2) - libzfs support
- pkgver = 2.04
+ pkgver = 2.12
pkgrel = 1
epoch = 2
url = https://www.gnu.org/software/grub/
install = grub-libzfs.install
arch = x86_64
- license = GPL3
+ license = GPL-3.0-or-later
makedepends = git
makedepends = rsync
makedepends = xz
@@ -18,15 +18,16 @@ pkgbase = grub-libzfs
makedepends = help2man
makedepends = gettext
makedepends = device-mapper
- makedepends = fuse2
+ makedepends = fuse3
depends = sh
depends = xz
depends = gettext
depends = device-mapper
depends = zfs-utils
optdepends = freetype2: For grub-mkfont usage
- optdepends = fuse2: For grub-mount usage
+ optdepends = fuse3: For grub-mount usage
optdepends = dosfstools: For grub-mkrescue FAT FS and EFI support
+ optdepends = lzop: For grub-mkrescue LZO support
optdepends = efibootmgr: For grub-install EFI support
optdepends = libisoburn: Provides xorriso for generating grub rescue iso using grub-mkrescue
optdepends = os-prober: To detect other OSes when generating grub.cfg in BIOS systems
@@ -50,25 +51,26 @@ pkgbase = grub-libzfs
options = !makeflags
backup = etc/default/grub
backup = etc/grub.d/40_custom
- source = git+https://git.savannah.gnu.org/git/grub.git#tag=grub-2.04?signed
- source = git+https://git.savannah.gnu.org/git/grub-extras.git#commit=136763a4cc9ca3a4f59d05b79eede2159d6f441e
- source = git+https://git.savannah.gnu.org/git/gnulib.git#commit=9ce9be2ef0cb1180e35dfe9dfbbe90d774b374bd
- source = https://ftp.gnu.org/gnu/unifont/unifont-12.1.02/unifont-12.1.02.bdf.gz
- source = https://ftp.gnu.org/gnu/unifont/unifont-12.1.02/unifont-12.1.02.bdf.gz.sig
- source = 0003-10_linux-detect-archlinux-initramfs.patch
- source = 0004-add-GRUB_COLOR_variables.patch
+ source = git+https://git.savannah.gnu.org/git/grub.git#tag=03e6ea18f6f834f177cad017279bedbb0a3de594?signed
+ source = git+https://git.savannah.gnu.org/git/gnulib.git
+ source = https://ftp.gnu.org/gnu/unifont/unifont-15.1.05/unifont-15.1.05.bdf.gz
+ source = https://ftp.gnu.org/gnu/unifont/unifont-15.1.05/unifont-15.1.05.bdf.gz.sig
+ source = 0001-00_header-add-GRUB_COLOR_-variables.patch
+ source = 0002-10_linux-detect-archlinux-initramfs.patch
+ source = 0003-support-dropins-for-default-configuration.patch
source = grub.default
+ source = sbat.csv
validpgpkeys = E53D497F3FA42AD8C9B4D1E835A93B74E82E4209
validpgpkeys = BE5C23209ACDDACEB20DB0A28C8189F1988C2166
validpgpkeys = 95D2E9AB8740D8046387FD151A09227B1F435A33
sha256sums = SKIP
sha256sums = SKIP
+ sha256sums = 8ea5b5a14d71e3353d1fea373f5d88d198ad1e285cedd8294655926ee11fd91d
sha256sums = SKIP
- sha256sums = 04d652be1e28a6d464965c75c71ac84633085cd0960c2687466651c34c94bd89
- sha256sums = SKIP
- sha256sums = 171415ab075d1ac806f36c454feeb060f870416f24279b70104bba94bd6076d4
- sha256sums = a5198267ceb04dceb6d2ea7800281a42b3f91fd02da55d2cc9ea20d47273ca29
- sha256sums = fd2e5f5453f3e44a2cb640c796b85cd70da8359c703f94cd531d457ede8c77fa
+ sha256sums = 5dee6628c48eef79812bb9e86ee772068d85e7fcebbd2b2b8d1e19d24eda9dab
+ sha256sums = 8488aec30a93e8fe66c23ef8c23aefda39c38389530e9e73ba3fbcc8315d244d
+ sha256sums = b5d9fcd62ffb3c3950fdeb7089ec2dc2294ac52e9861980ad90a437dedbd3d47
+ sha256sums = 7df3f5cb5df7d2dfb17f4c9b5c5dedc9519ddce6f8d2c6cd43d1be17cecb65cb
+ sha256sums = f34c2b0aa2ed4ab9c7e7bcab5197470c30fedc6c2148f337839dd24bceae35fd
pkgname = grub-libzfs
-
diff --git a/.gitignore b/.gitignore
index 8e1ddcd40bbf..fce15edae897 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,6 +4,5 @@
*.sig
/gnulib
/grub
-/grub-extras
/src
/pkg
diff --git a/0004-add-GRUB_COLOR_variables.patch b/0001-00_header-add-GRUB_COLOR_-variables.patch
index c113a81d5754..867e8feeb7b9 100644
--- a/0004-add-GRUB_COLOR_variables.patch
+++ b/0001-00_header-add-GRUB_COLOR_-variables.patch
@@ -1,18 +1,27 @@
+From 21e5bcf22ab1a9f08c63e2a0212219d7482f77c1 Mon Sep 17 00:00:00 2001
+From: Christian Hesse <mail@eworm.de>
+Date: Wed, 10 Mar 2021 18:42:25 +0100
+Subject: [PATCH] 00_header: add GRUB_COLOR_* variables
+---
+ util/grub-mkconfig.in | 2 ++
+ util/grub.d/00_header.in | 8 ++++++++
+ 2 files changed, 10 insertions(+)
+
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
-index 3390ba9..c416489 100644
+index f8cbb8d7a..1189d95f9 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
-@@ -218,6 +218,8 @@ export GRUB_DEFAULT \
+@@ -246,6 +246,8 @@ export GRUB_DEFAULT \
+ GRUB_BACKGROUND \
GRUB_THEME \
GRUB_GFXPAYLOAD_LINUX \
- GRUB_DISABLE_OS_PROBER \
+ GRUB_COLOR_NORMAL \
+ GRUB_COLOR_HIGHLIGHT \
GRUB_INIT_TUNE \
GRUB_SAVEDEFAULT \
GRUB_ENABLE_CRYPTODISK \
diff --git a/util/grub.d/00_header.in b/util/grub.d/00_header.in
-index d2e7252..8259f45 100644
+index 93a90233e..c5955df00 100644
--- a/util/grub.d/00_header.in
+++ b/util/grub.d/00_header.in
@@ -125,6 +125,14 @@ cat <<EOF
diff --git a/0003-10_linux-detect-archlinux-initramfs.patch b/0002-10_linux-detect-archlinux-initramfs.patch
index 512fa0451504..5abb5e63dc88 100644
--- a/0003-10_linux-detect-archlinux-initramfs.patch
+++ b/0002-10_linux-detect-archlinux-initramfs.patch
@@ -1,17 +1,27 @@
+From dbc289f59a2b204af19ef7212f3b6b07d3060452 Mon Sep 17 00:00:00 2001
+From: Christian Hesse <mail@eworm.de>
+Date: Mon, 26 Apr 2021 11:10:01 +0200
+Subject: [PATCH 1/1] 10_linux: detect archlinux initramfs
+---
+ util/grub.d/10_linux.in | 29 ++++++++++++++++++++++++++++-
+ 1 file changed, 28 insertions(+), 1 deletion(-)
+
diff --git a/util/grub.d/10_linux.in b/util/grub.d/10_linux.in
-index f5d3e78..ef59c8c 100644
+index e8b01c0d0..9b60af944 100644
--- a/util/grub.d/10_linux.in
+++ b/util/grub.d/10_linux.in
-@@ -83,6 +83,8 @@ linux_entry ()
+@@ -91,6 +91,10 @@ linux_entry ()
+ fi
+ if [ x$type != xsimple ] ; then
case $type in
- recovery)
- title="$(gettext_printf "%s, with Linux %s (recovery mode)" "${os}" "${version}")" ;;
++ booster)
++ title="$(gettext_printf "%s, with Linux %s (booster initramfs)" "${os}" "${version}")" ;;
+ fallback)
+ title="$(gettext_printf "%s, with Linux %s (fallback initramfs)" "${os}" "${version}")" ;;
+ recovery)
+ title="$(gettext_printf "%s, with Linux %s (recovery mode)" "${os}" "${version}")" ;;
*)
- title="$(gettext_printf "%s, with Linux %s" "${os}" "${version}")" ;;
- esac
-@@ -186,7 +188,7 @@ while [ "x$list" != "x" ] ; do
+@@ -198,7 +202,7 @@ while [ "x$list" != "x" ] ; do
basename=`basename $linux`
dirname=`dirname $linux`
rel_dirname=`make_system_path_relative_to_its_root $dirname`
@@ -20,13 +30,13 @@ index f5d3e78..ef59c8c 100644
alt_version=`echo $version | sed -e "s,\.old$,,g"`
linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
-@@ -248,6 +250,18 @@ while [ "x$list" != "x" ] ; do
+@@ -285,6 +289,29 @@ while [ "x$list" != "x" ] ; do
linux_entry "${OS}" "${version}" advanced \
"${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
+
+ if test -e "${dirname}/initramfs-${version}-fallback.img" ; then
-+ initrd="initramfs-${version}-fallback.img"
++ initrd="${initrd_early} initramfs-${version}-fallback.img"
+
+ if test -n "${initrd}" ; then
+ gettext_printf "Found fallback initrd image(s) in %s:%s\n" "${dirname}" "${initrd_extra} ${initrd}" >&2
@@ -36,6 +46,17 @@ index f5d3e78..ef59c8c 100644
+ "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
+ fi
+
++ if test -e "${dirname}/booster-${version}.img" ; then
++ initrd="${initrd_early} booster-${version}.img"
++
++ if test -n "${initrd}" ; then
++ gettext_printf "Found booster initrd image(s) in %s:%s\n" "${dirname}" "${initrd_extra} ${initrd}" >&2
++ fi
++
++ linux_entry "${OS}" "${version}" booster \
++ "${GRUB_CMDLINE_LINUX} ${GRUB_CMDLINE_LINUX_DEFAULT}"
++ fi
++
if [ "x${GRUB_DISABLE_RECOVERY}" != "xtrue" ]; then
linux_entry "${OS}" "${version}" recovery \
"single ${GRUB_CMDLINE_LINUX}"
diff --git a/0003-support-dropins-for-default-configuration.patch b/0003-support-dropins-for-default-configuration.patch
new file mode 100644
index 000000000000..4840487a1f1d
--- /dev/null
+++ b/0003-support-dropins-for-default-configuration.patch
@@ -0,0 +1,28 @@
+From ac560966d09295663fa9516d8d137e0c0fd04c06 Mon Sep 17 00:00:00 2001
+From: Christian Hesse <mail@eworm.de>
+Date: Mon, 12 Jun 2023 07:42:01 +0200
+Subject: [PATCH 1/1] support dropins for default configuration
+
+---
+ util/grub-mkconfig.in | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
+index 1a945085c..4338dceef 100644
+--- a/util/grub-mkconfig.in
++++ b/util/grub-mkconfig.in
+@@ -160,6 +160,11 @@ fi
+ if test -f ${sysconfdir}/default/grub ; then
+ . ${sysconfdir}/default/grub
+ fi
++for dropin in ${sysconfdir}/default/grub.d/*.cfg ; do
++ if test -f "${dropin}" ; then
++ . "${dropin}"
++ fi
++done
+
+ if [ "x${GRUB_DISABLE_UUID}" = "xtrue" ]; then
+ if [ -z "${GRUB_DISABLE_LINUX_UUID}" ]; then
+--
+2.41.0
+
diff --git a/PKGBUILD b/PKGBUILD
index d69fee77d670..64c3c9529675 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer : Christian Hesse <mail@eworm.de>
-# Maintainer : Ronald van Haren <ronald.archlinux.org>
-# Contributor: Tobias Powalowski <tpowa@archlinux.org>
+# Maintainer : Tobias Powalowski <tpowa@archlinux.org>
+# Contributor: Ronald van Haren <ronald.archlinux.org>
# Contributor: Keshav Amburay <(the ddoott ridikulus ddoott rat) (aatt) (gemmaeiil) (ddoott) (ccoomm)>
## "1" to enable IA32-EFI build in Arch x86_64, "0" to disable
@@ -9,25 +9,23 @@ _IA32_EFI_IN_ARCH_X64="1"
## "1" to enable EMU build, "0" to disable
_GRUB_EMU_BUILD="0"
-_GRUB_EXTRAS_COMMIT="136763a4cc9ca3a4f59d05b79eede2159d6f441e"
-_GNULIB_COMMIT="9ce9be2ef0cb1180e35dfe9dfbbe90d774b374bd"
-_UNIFONT_VER="12.1.02"
+[[ "${CARCH}" == 'x86_64' ]] && _EFI_ARCH='x86_64'
+[[ "${CARCH}" == 'i686' ]] && _EFI_ARCH='i386'
-[[ "${CARCH}" == "x86_64" ]] && _EFI_ARCH="x86_64"
-[[ "${CARCH}" == "i686" ]] && _EFI_ARCH="i386"
-
-[[ "${CARCH}" == "x86_64" ]] && _EMU_ARCH="x86_64"
-[[ "${CARCH}" == "i686" ]] && _EMU_ARCH="i386"
+[[ "${CARCH}" == 'x86_64' ]] && _EMU_ARCH='x86_64'
+[[ "${CARCH}" == 'i686' ]] && _EMU_ARCH='i386'
pkgname='grub-libzfs'
pkgdesc='GNU GRand Unified Bootloader (2) - libzfs support'
-_pkgver=2.04
-pkgver=${_pkgver/-/}
-pkgrel=2
epoch=2
+_tag='03e6ea18f6f834f177cad017279bedbb0a3de594' # git rev-parse grub-${_pkgver}
+_pkgver=2.12
+_unifont_ver='15.1.05'
+pkgver=${_pkgver/-/}
+pkgrel=1
url='https://www.gnu.org/software/grub/'
arch=('x86_64')
-license=('GPL3')
+license=('GPL-3.0-or-later')
backup=('etc/default/grub'
'etc/grub.d/40_custom')
install="${pkgname}.install"
@@ -38,11 +36,12 @@ replaces=('grub-common' 'grub-bios' 'grub-emu' "grub-efi-${_EFI_ARCH}" 'grub')
provides=('grub-common' 'grub-bios' 'grub-emu' "grub-efi-${_EFI_ARCH}" 'grub')
makedepends=('git' 'rsync' 'xz' 'freetype2' 'ttf-dejavu' 'python' 'autogen'
- 'texinfo' 'help2man' 'gettext' 'device-mapper' 'fuse2')
+ 'texinfo' 'help2man' 'gettext' 'device-mapper' 'fuse3')
depends=('sh' 'xz' 'gettext' 'device-mapper' 'zfs-utils')
optdepends=('freetype2: For grub-mkfont usage'
- 'fuse2: For grub-mount usage'
+ 'fuse3: For grub-mount usage'
'dosfstools: For grub-mkrescue FAT FS and EFI support'
+ 'lzop: For grub-mkrescue LZO support'
'efibootmgr: For grub-install EFI support'
'libisoburn: Provides xorriso for generating grub rescue iso using grub-mkrescue'
'os-prober: To detect other OSes when generating grub.cfg in BIOS systems'
@@ -58,30 +57,35 @@ validpgpkeys=('E53D497F3FA42AD8C9B4D1E835A93B74E82E4209' # Vladimir 'phcoder' S
'BE5C23209ACDDACEB20DB0A28C8189F1988C2166' # Daniel Kiper <dkiper@net-space.pl>
'95D2E9AB8740D8046387FD151A09227B1F435A33') # Paul Hardy <unifoundry@unifoundry.com>
-source=("git+https://git.savannah.gnu.org/git/grub.git#tag=grub-${_pkgver}?signed"
- "git+https://git.savannah.gnu.org/git/grub-extras.git#commit=${_GRUB_EXTRAS_COMMIT}"
- "git+https://git.savannah.gnu.org/git/gnulib.git#commit=${_GNULIB_COMMIT}"
- "https://ftp.gnu.org/gnu/unifont/unifont-${_UNIFONT_VER}/unifont-${_UNIFONT_VER}.bdf.gz"{,.sig}
- '0003-10_linux-detect-archlinux-initramfs.patch'
- '0004-add-GRUB_COLOR_variables.patch'
- 'grub.default')
+source=("git+https://git.savannah.gnu.org/git/grub.git#tag=${_tag}?signed"
+ 'git+https://git.savannah.gnu.org/git/gnulib.git'
+ "https://ftp.gnu.org/gnu/unifont/unifont-${_unifont_ver}/unifont-${_unifont_ver}.bdf.gz"{,.sig}
+ '0001-00_header-add-GRUB_COLOR_-variables.patch'
+ '0002-10_linux-detect-archlinux-initramfs.patch'
+ '0003-support-dropins-for-default-configuration.patch'
+ 'grub.default'
+ 'sbat.csv')
sha256sums=('SKIP'
'SKIP'
+ '8ea5b5a14d71e3353d1fea373f5d88d198ad1e285cedd8294655926ee11fd91d'
'SKIP'
- '04d652be1e28a6d464965c75c71ac84633085cd0960c2687466651c34c94bd89'
- 'SKIP'
- '171415ab075d1ac806f36c454feeb060f870416f24279b70104bba94bd6076d4'
- 'a5198267ceb04dceb6d2ea7800281a42b3f91fd02da55d2cc9ea20d47273ca29'
- 'b8fe532668cb12c34d2a26221298f2459fac7c5578a14476a2af8c20aed5c101')
+ '5dee6628c48eef79812bb9e86ee772068d85e7fcebbd2b2b8d1e19d24eda9dab'
+ '8488aec30a93e8fe66c23ef8c23aefda39c38389530e9e73ba3fbcc8315d244d'
+ 'b5d9fcd62ffb3c3950fdeb7089ec2dc2294ac52e9861980ad90a437dedbd3d47'
+ '7df3f5cb5df7d2dfb17f4c9b5c5dedc9519ddce6f8d2c6cd43d1be17cecb65cb'
+ 'f34c2b0aa2ed4ab9c7e7bcab5197470c30fedc6c2148f337839dd24bceae35fd')
_backports=(
)
+_reverts=(
+)
+
_configure_options=(
+ PACKAGE_VERSION="${epoch}:${pkgver}-${pkgrel}"
FREETYPE="pkg-config freetype2"
BUILD_FREETYPE="pkg-config freetype2"
- --enable-mm-debug
--enable-nls
--enable-device-mapper
--enable-cache-stats
@@ -112,12 +116,22 @@ prepare() {
git cherry-pick -n "${_c}"
done
- echo "Patch to detect of Arch Linux initramfs images by grub-mkconfig..."
- patch -Np1 -i "${srcdir}/0003-10_linux-detect-archlinux-initramfs.patch"
+ echo "Apply reverts..."
+ local _c
+ for _c in "${_reverts[@]}"; do
+ git log --oneline -1 "${_c}"
+ git revert -n "${_c}"
+ done
echo "Patch to enable GRUB_COLOR_* variables in grub-mkconfig..."
## Based on http://lists.gnu.org/archive/html/grub-devel/2012-02/msg00021.html
- patch -Np1 -i "${srcdir}/0004-add-GRUB_COLOR_variables.patch"
+ patch -Np1 -i "${srcdir}/0001-00_header-add-GRUB_COLOR_-variables.patch"
+
+ echo "Patch to detect of Arch Linux initramfs images by grub-mkconfig..."
+ patch -Np1 -i "${srcdir}/0002-10_linux-detect-archlinux-initramfs.patch"
+
+ echo "Patch to support dropins for default configuration..."
+ patch -Np1 -i "${srcdir}/0003-support-dropins-for-default-configuration.patch"
echo "Fix DejaVuSans.ttf location so that grub-mkfont can create *.pf2 files for starfield theme..."
sed 's|/usr/share/fonts/dejavu|/usr/share/fonts/dejavu /usr/share/fonts/TTF|g' -i "configure.ac"
@@ -131,17 +145,17 @@ prepare() {
echo "Pull in latest language files..."
./linguas.sh
- echo "Remove not working langs which need LC_ALL=C.UTF-8..."
- sed -e 's#en@cyrillic en@greek##g' -i "po/LINGUAS"
-
echo "Avoid problem with unifont during compile of grub..."
# http://savannah.gnu.org/bugs/?40330 and https://bugs.archlinux.org/task/37847
- gzip -cd "${srcdir}/unifont-${_UNIFONT_VER}.bdf.gz" > "unifont.bdf"
+ gzip -cd "${srcdir}/unifont-${_unifont_ver}.bdf.gz" > "unifont.bdf"
echo "Run bootstrap..."
./bootstrap \
--gnulib-srcdir="${srcdir}/gnulib/" \
--no-git
+
+ echo "Make translations reproducible..."
+ sed -i '1i /^PO-Revision-Date:/ d' po/*.sed
}
_build_grub-common_and_bios() {
@@ -156,12 +170,6 @@ _build_grub-common_and_bios() {
cp -r "${srcdir}/grub/" "${srcdir}/grub-bios/"
cd "${srcdir}/grub-bios/"
- echo "Add the grub-extra sources for bios build..."
- install -d "${srcdir}/grub-bios/grub-extras"
- cp -r "${srcdir}/grub-extras/915resolution" \
- "${srcdir}/grub-bios/grub-extras/915resolution"
- export GRUB_CONTRIB="${srcdir}/grub-bios/grub-extras/"
-
echo "Unset all compiler FLAGS for bios build..."
unset CFLAGS
unset CPPFLAGS
@@ -177,6 +185,11 @@ _build_grub-common_and_bios() {
--enable-boot-time \
"${_configure_options[@]}"
+ if [ ! -z "${SOURCE_DATE_EPOCH}" ]; then
+ echo "Make info pages reproducible..."
+ touch -d "@${SOURCE_DATE_EPOCH}" $(find -name '*.texi')
+ fi
+
echo "Run make for bios build..."
make
}
@@ -275,6 +288,8 @@ _package_grub-efi() {
rm -f "${pkgdir}/usr/lib/grub/${_EFI_ARCH}-efi"/*.module || true
rm -f "${pkgdir}/usr/lib/grub/${_EFI_ARCH}-efi"/*.image || true
rm -f "${pkgdir}/usr/lib/grub/${_EFI_ARCH}-efi"/{kernel.exec,gdb_grub,gmodule.pl} || true
+
+ sed -e "s/%PKGVER%/${epoch}:${pkgver}-${pkgrel}/" < "${srcdir}/sbat.csv" > "${pkgdir}/usr/share/grub/sbat.csv"
}
_package_grub-emu() {
diff --git a/grub-libzfs.install b/grub-libzfs.install
index c13ef99c77c5..c268996d1e57 100644
--- a/grub-libzfs.install
+++ b/grub-libzfs.install
@@ -6,12 +6,23 @@ post_upgrade() {
if [ ! -f /boot/grub/grub.cfg -a -f /boot/grub/grub.cfg.pacsave ]; then
mv /boot/grub/grub.cfg.pacsave /boot/grub/grub.cfg
fi
+
+ # return if old package version greater 2:2.06-0...
+ (( $(vercmp $2 '2:2.06-0') > 0 )) && return
+
+ if [[ -e /sys/firmware/efi/efivars ]]; then
+ cat <<EOM
+:: Grub does no longer support side-loading modules when secure boot is
+ enabled. Thus booting will fail, unless you have an efi executable
+ 'grubx64.efi' with bundled modules.
+EOM
+ fi
}
post_install() {
- cat << 'EOM'
-Generate your bootloader configuration with:
- grub-mkconfig -o /boot/grub/grub.cfg
+ cat <<EOM
+:: Generate your bootloader configuration with:
+ grub-mkconfig -o /boot/grub/grub.cfg
EOM
}
diff --git a/grub.default b/grub.default
index 251dfae01594..5af66e3ca829 100644
--- a/grub.default
+++ b/grub.default
@@ -24,7 +24,7 @@ GRUB_TERMINAL_INPUT=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
-# you can see them in real GRUB with the command `vbeinfo'
+# you can see them in real GRUB with the command `videoinfo'
GRUB_GFXMODE=auto
# Uncomment to allow the kernel use the same resolution used by grub
@@ -49,6 +49,15 @@ GRUB_DISABLE_RECOVERY=true
# Uncomment to get a beep at GRUB start
#GRUB_INIT_TUNE="480 440 1"
-# Uncomment to make GRUB remember the last selection. This requires to
-# set 'GRUB_DEFAULT=saved' above.
-#GRUB_SAVEDEFAULT="true"
+# Uncomment to make GRUB remember the last selection. This requires
+# setting 'GRUB_DEFAULT=saved' above.
+#GRUB_SAVEDEFAULT=true
+
+# Uncomment to disable submenus in boot menu
+#GRUB_DISABLE_SUBMENU=y
+
+# Probing for other operating systems is disabled for security reasons. Read
+# documentation on GRUB_DISABLE_OS_PROBER, if still want to enable this
+# functionality install os-prober and uncomment to detect and include other
+# operating systems.
+#GRUB_DISABLE_OS_PROBER=false
diff --git a/grub.install b/grub.install
new file mode 100644
index 000000000000..79693428ee8b
--- /dev/null
+++ b/grub.install
@@ -0,0 +1,38 @@
+#!/bin/sh
+
+post_upgrade() {
+ # We used to package /boot/grub/grub.cfg, but there is no reason to.
+ # Remove the file from package, but move real file back in place.
+ if [ ! -f /boot/grub/grub.cfg -a -f /boot/grub/grub.cfg.pacsave ]; then
+ mv /boot/grub/grub.cfg.pacsave /boot/grub/grub.cfg
+ fi
+
+ # Give a hint to update installation and configuration one after another.
+ cat <<EOM
+:: To use the new features provided in this GRUB update, it is recommended
+ to install it to the MBR or UEFI. Due to potential configuration
+ incompatibilities, it is advised to run both, installation and generation
+ of configuration:
+ # grub-install ...
+ # grub-mkconfig -o /boot/grub/grub.cfg
+EOM
+
+ # return if old package version greater 2:2.06-0...
+ (( $(vercmp $2 '2:2.06-0') > 0 )) && return
+
+ if [[ -e /sys/firmware/efi/efivars ]]; then
+ cat <<EOM
+:: Grub does no longer support side-loading modules when secure boot is
+ enabled. Thus booting will fail, unless you have an efi executable
+ 'grubx64.efi' with bundled modules.
+EOM
+ fi
+}
+
+post_install() {
+ cat <<EOM
+:: Install your bootloader and generate configuration with:
+ # grub-install ...
+ # grub-mkconfig -o /boot/grub/grub.cfg
+EOM
+}
diff --git a/sbat.csv b/sbat.csv
new file mode 100644
index 000000000000..66ce2882b0c0
--- /dev/null
+++ b/sbat.csv
@@ -0,0 +1,3 @@
+sbat,1,SBAT Version,sbat,1,https://github.com/rhboot/shim/blob/main/SBAT.md
+grub,3,Free Software Foundation,grub,%PKGVER%,https//www.gnu.org/software/grub/
+grub.arch,1,Arch Linux,grub,%PKGVER%,https://archlinux.org/packages/core/x86_64/grub/