Verify presence of mcopy for bio key creation

This commit is contained in:
Yorick Barbanneau 2020-04-18 17:30:43 +02:00
parent 9c4931058c
commit 709677e574

View file

@ -16,15 +16,18 @@ boot_type="efi64"
repo_dir="repo" repo_dir="repo"
tmp_dir="tmp" tmp_dir="tmp"
current_dir=`pwd` current_dir=`pwd`
# In Archlinux, this is default files for syslinux... # In Archlinux, this is default files for syslinux...
conf_file="conf/archlinux.conf" conf_file="conf/archlinux.conf"
key_mountpoint="/mnt/usbstick" key_mountpoint="/mnt/usbstick"
device="" device=""
# constant # constant
APP_NAME="Debian USB Creator" APP_NAME="Debian USB Creator"
VERSION="1.99.0" VERSION="1.99.0"
SYSLINUX_EXE=$(which syslinux) SYSLINUX_EXE=$(which syslinux)
PARTED_EXE=$(which parted) PARTED_EXE=$(which parted)
MCOPY=$(which mcopy)
SYSLINUX_FILES="menu.c32 vesamenu.c32 libutil.c32 libcom32.c32" SYSLINUX_FILES="menu.c32 vesamenu.c32 libutil.c32 libcom32.c32"
SYSLINUX_BIOS_FILES="" SYSLINUX_BIOS_FILES=""
SYSLINUX_EFI_FILES="ldlinux.e64" SYSLINUX_EFI_FILES="ldlinux.e64"
@ -225,6 +228,12 @@ then
exit 1 exit 1
fi fi
if [ "$boot_type" == "bios" ] && [ -z "$MCOPY" ]
then
printf "Bios key creation need mcopy from mtools packages\n"
exit 1
fi
bootfiles_Debian="http://ftp.debian.org/debian/dists/stable/main/installer-${debian_arch}/current/images/hd-media" bootfiles_Debian="http://ftp.debian.org/debian/dists/stable/main/installer-${debian_arch}/current/images/hd-media"
if [ $archive -eq 1 ] if [ $archive -eq 1 ]
then then