From 38da25370bbbee38c02a7d937dd55423563d90bf Mon Sep 17 00:00:00 2001 From: "Andrew J. Hesford" Date: Wed, 5 Aug 2020 12:13:09 -0400 Subject: [PATCH] refind: improve consistency of relative paths in kernel hooks --- srcpkgs/refind/files/kernel.post-install | 10 +++------- srcpkgs/refind/files/kernel.post-remove | 4 +++- srcpkgs/refind/template | 2 +- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/srcpkgs/refind/files/kernel.post-install b/srcpkgs/refind/files/kernel.post-install index 88b261aaac..fd18f9c45f 100755 --- a/srcpkgs/refind/files/kernel.post-install +++ b/srcpkgs/refind/files/kernel.post-install @@ -12,22 +12,18 @@ if [ "z$UPDATE_REFIND_CONF" != "z1" ]; then exit 0; fi -# Default refind.conf -: "${REFIND_CONF:=/boot/EFI/refind/refind.conf}" +: ${REFIND_CONF:=boot/EFI/refind/refind.conf} +REFIND_CONF="${REFIND_CONF#/}" -zrefind_dir="${REFIND_CONF%/*}" -mkdir -p "$zrefind_dir" +mkdir -p "${REFIND_CONF%/*}" touch "$REFIND_CONF" tmpfile=$(mktemp /tmp/refind.XXXXXXX) -zefi_mountpoint=$(df -P "$REFIND_CONF" | awk 'NR==2{print $6}') -zicon="${zrefind_dir#$zefi_mountpoint}/icons/os_void.png" zversion=$(echo "$VERSION" | sed 's/[.]/[.]/g') zentry=$(cat <