From c8eafc252f80474fa4b7bd2454ca07f134883f97 Mon Sep 17 00:00:00 2001 From: George Danchev Date: Thu, 23 Jun 2011 11:01:39 +0000 Subject: [PATCH] check for config file and jigdo-gen-md5-list existance --- libisoburn/trunk/releng/releng_build_jigdo | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/libisoburn/trunk/releng/releng_build_jigdo b/libisoburn/trunk/releng/releng_build_jigdo index dcf67b11..24a33afc 100755 --- a/libisoburn/trunk/releng/releng_build_jigdo +++ b/libisoburn/trunk/releng/releng_build_jigdo @@ -9,7 +9,7 @@ IMG="" # optional ISOLINUX_BIN="" BOOT_CAT="" -CONFFILE=$HOME/releng_build_jigdo.conf +CONFFILE=$HOME/releng_build_isojigdo.conf CLEAN=0 print_help() { @@ -34,7 +34,7 @@ if [ ! "${1}" -o "${1}" == "-help" ]; then print_help && exit 0; fi # config file if [ "${1}" == "-rc" ]; then if [ -e ${CONFFILE} ]; then . ${CONFFILE} - else echo -e "$0: can not find config file: ${CONFFILE}\n" + else echo -e "$0: Config file ${CONFFILE} not found.\n" && exit 1 fi if [ "${2}" == "-clean" ]; then CLEAN=1; fi # command line args @@ -66,7 +66,14 @@ main() { # /sbin/mkfs.msdos -n Bla -C fatpart.fat 8192 # create MD5 list in base64 format -jigdo-gen-md5-list ${DIR} > ${IMG}.md5 +if which jigdo-gen-md5-list >/dev/null 2>&1; then + printf "$0: Creating MD5 list in hex format..." + jigdo-gen-md5-list ${DIR} > ${IMG}.md5 + printf "Done.\n" +else + printf "$0: Not found: jigdo-gen-md5-list. Install jigit.\n" + exit 1 +fi # build the command - general section CMD="${XOR} \ @@ -103,7 +110,7 @@ CMD+="\ CMD+="${DIR}" # run it -echo -e "$0: creating iso & jigdo representations:\n$CMD\n" +echo -e "$0: Creating ISO and jigdo representations:\n$CMD\n" ${CMD} # create another one from jigdo files