#!/usr/bin/env bash set -e # # This script creates a bootable image and should at some point in the future # be replaced by the proper NetBSD infrastructure. # : ${ARCH=i386} : ${OBJ=../obj.${ARCH}} : ${TOOLCHAIN_TRIPLET=i586-elf32-minix-} : ${BUILDSH=build.sh} : ${SETS="minix-base"} : ${IMG=minix_x86.iso} if [ ! -f ${BUILDSH} ] then echo "Please invoke me from the root source dir, where ${BUILDSH} is." exit 1 fi # set up disk creation environment . releasetools/image.defaults . releasetools/image.functions # where the kernel & boot modules will be MODDIR=${DESTDIR}/boot/minix/.temp echo "Building work directory..." build_workdir "$SETS" echo "Adding extra files..." workdir_add_sets workdir_add_cdfiles # create a fstab entry in /etc cat >${ROOT_DIR}/etc/fstab <${ROOT_DIR}/boot.cfg <