[ -z "$VARIANT" ] && VARIANT="build"
[ "$CONSOLE_INFO" == "default" ] && CONSOLE_INFO=$SERIAL_CONSOLE
+ if [ -n "$NODE_CONFIGURATION_FILE" ] ; then
+ # check existence of NODE_CONFIGURATION_FILE and normalize as we will change directory
+ if [ ! -f "$NODE_CONFIGURATION_FILE" ] ; then
+ echo "Node configuration file $NODE_CONFIGURATION_FILE not found - exiting"
+ exit 1
+ fi
+ cf_dir="$(dirname $NODE_CONFIGURATION_FILE)"
+ cf_dir="$(cd $cf_dir; pwd -P)"
+ cf_file="$(basename $NODE_CONFIGURATION_FILE)"
+ NODE_CONFIGURATION_FILE="$cf_dir"/"$cf_file"
+ fi
+
# check TYPES
local matcher="XXX$(echo $ALL_TYPES | sed -e 's,\W,XXX,g')XXX"
for t in $TYPES; do
for i in "$ISOREF"/isofs/{bootcd.img,kernel}; do
ln -s "$i" "${BUILDTMP}/isofs"
done
- cp "/usr/lib/syslinux/isolinux.bin" "${BUILDTMP}/isofs"
+ # the syslinux that comes with f12 has this file in a new location
+ cp "/usr/lib/syslinux/isolinux.bin" "${BUILDTMP}/isofs" \
+ || cp "/usr/share/syslinux/isolinux.bin" "${BUILDTMP}/isofs"
ISOFS="${BUILDTMP}/isofs"
# Root of the ISO and USB images
sectors=$sectors
offset=$offset
mformat_only
+mtools_skip_check=1
EOF
# environment variable for mtools
export MTOOLSRC="${BUILDTMP}/mtools.conf"
mdel -i "$usb" z:/isolinux.cfg 2>/dev/null || :
mcopy -i "$usb" "$tmp" z:/syslinux.cfg
rm -f "$tmp"
- rm -f "${BUILDTMP}/mtools.conf"
+ rm -f "${MTOOLSRC}"
unset MTOOLSRC
echo "making USB image bootable."
rm -f "$usb"
mkfs.vfat -C "$usb" $(($(du -Lsk $ISOFS | awk '{ print $1; }') + $FREE_SPACE))
+ cat >${BUILDTMP}/mtools.conf<<EOF
+mtools_skip_check=1
+EOF
+ # environment variable for mtools
+ export MTOOLSRC="${BUILDTMP}/mtools.conf"
+
# Populate it
echo -n " populating USB image... "
mcopy -bsQ -i "$usb" "$ISOFS"/* ::/
mdel -i "$usb" ::/isolinux.cfg 2>/dev/null || :
mcopy -i "$usb" "$tmp" ::/syslinux.cfg
rm -f "$tmp"
+ rm -f "${MTOOLSRC}"
+ unset MTOOLSRC
echo "making USB image bootable."
syslinux "$usb"