aboutsummaryrefslogtreecommitdiff
path: root/files
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2022-06-12 15:30:10 -0300
committerSilvio Rhatto <rhatto@riseup.net>2022-06-12 15:30:10 -0300
commit65bc94933fb6a25be912ff040fe9f18aab31596e (patch)
tree337b27010170d93c0d5eb3a9491144bfab2ddd64 /files
parent35a502e10ddbb2f20e58b558e63439938bd0af5a (diff)
downloadbootless-65bc94933fb6a25be912ff040fe9f18aab31596e.tar.gz
bootless-65bc94933fb6a25be912ff040fe9f18aab31596e.tar.bz2
Fix: check for package dependencies
Diffstat (limited to 'files')
-rwxr-xr-xfiles/bootless10
1 files changed, 10 insertions, 0 deletions
diff --git a/files/bootless b/files/bootless
index a06c98d..0dffd6c 100755
--- a/files/bootless
+++ b/files/bootless
@@ -220,6 +220,15 @@ function bootless_check_dependencies {
exit 1
fi
done
+
+ # Some package dependencies are needed, especially grub-pc-bin which
+ # enables PC BIOS-compatible images
+ for dependency in $DEPENDENCIES_DEB; do
+ if ! dpkg -l $dependency | grep -q "^ii "; then
+ echo "$NAME: unmet package dependency $dependency, please install it"
+ exit 1
+ fi
+ done
}
# Load
@@ -231,6 +240,7 @@ BOOTLESS_VERSION="0.0.1"
BOOTLESS_ACTION="$1"
BOOTLESS_DIR="$2"
DEPENDENCIES="xorriso grub-mkrescue rsync dd"
+DEPENDENCIES_DEB="grub-pc-bin"
# Output name and version
echo "$NAME $BOOTLESS_VERSION"