# Author: Artem Bityutskiy
# License: GPLv2
+#
+# This is a simple script which installs gummiboot to the ESP and creates the
+# gummiboot configuration files. This script requires a number of environment
+# variables to be defined. Namely:
+#
+# 1. INSTALLERFW_PART_COUNT - count of paritions
+# 2. INSTALLERFW_PARTX_MOUNTPOINT - mount point of partition number X
+# (0 <= x < $INSTALLERFW_PART_COUNT)
+# 3. INSTALLERFW_PARTX_PARTUUID - GPT GUID (AKA PARTUUID) of partition number X
+# 4. INSTALLERFW_PARTX_FSTYPE - which file-system format partition number X has
+# 5. INSTALLERFW_MOUNT_PREFIX - where the target partitions are mounted (the
+# "root" directory of the file-system we install gummiboot to)
+
PROG="setup-efi-ivi"
# This is a helper function which prints an error message and exits
}
# Make sure the installer framework variables are defined
-[ "${INSTALLERFW_INSTALLER_NAME:+x}" == "x" ] ||
+[ "${INSTALLERFW_PART_COUNT:+x}" == "x" ] ||
fatal "installer framework environment variables not found"
# Find the root and boot paritions
# Find out all the required data for the root and boot partition
if [ "$mountpoint" == "/" ]; then
- root_partuuid=INSTALLERFW_PART${pnum}_PARTUUID
+ root_partuuid="INSTALLERFW_PART${pnum}_PARTUUID"
root_partuuid="$(eval printf "%s" '$'$root_partuuid)"
# The boot parition has to be at "/boot"
elif [ "$mountpoint" == "/boot" ]; then
- boot_fstype=INSTALLERFW_PART${pnum}_FSTYPE
+ boot_fstype="INSTALLERFW_PART${pnum}_FSTYPE"
boot_fstype="$(eval printf "%s" '$'$boot_fstype)"
fi
mkdir -p "$boot_mountpoint/loader"
cat > "$boot_mountpoint/loader/loader.conf" <<-EOF
-timeout 0
+timeo ut 0
default vmlinuz-$vmlinuz_version.conf
EOF