add a template script to start with - template_new_releng

This commit is contained in:
George Danchev
2011-06-26 23:44:51 +00:00
parent 8f4c0e82ef
commit 54e65fa11e
3 changed files with 44 additions and 15 deletions

View File

@ -14,25 +14,22 @@ BOOT_CAT=""
CONFFILE=$HOME/releng_build_isojigdo.conf
CLEAN=0
RES=""
print_help() {
cat << HLP
Usage:
$0 -help
# using a config file ${CONFFILE}
$0 -rc [-clean]
config file content:
XOR=/path/to/xorriso
DIR=/path/to/input_dir
IMG=/path/to/out_image
ISOLINUX_BIN=/path/to/isolinux.bin
BOOT_CAT=/path/to/boot.cat
# without using a config file
$0 xorriso_cmd IN_dir OUT_image [IN_isolinux] [OUT_bootcat] [-clean]
HLP
}
#####################################################################
# help
if [ ! "${1}" -o "${1}" == "-help" ]; then print_help && exit 10; fi
if [ ! "${1}" ]; then print_help && exit 10; fi
# config file
if [ "${1}" == "-rc" ]; then
if [ -e ${CONFFILE} ]; then
@ -72,9 +69,8 @@ printf "$0: Config items:"
printf "\n\txorriso_cmd=${XOR}\n\tIN_dir=${DIR}\n\tOUT_image=${IMG}.iso"
printf "\n\tIN_isolinux=${ISOLINUX_BIN}\n\tOUT_bootcat=${BOOT_CAT}\n"
RES="${IMG}.iso ${IMG}.new ${IMG}.md5 ${IMG}.jigdo ${IMG}.template"
############################################################
main() {
# version details, incl. underlying libraries
# xorriso version details, incl. underlying libraries
"${XOR}" -version
if ! "${XOR}" -version | grep libjte >/dev/null 2>&1; then
printf "\n$0: JTE not supported with this xorriso build. Install jigit and rebuild."
@ -188,8 +184,3 @@ printf " * xorriso -indev ${IMG}.iso -pvd_info\n"
printf " * fdisk -lu ${IMG}.iso\n"
exit 0
}
#
main