start with simple honoring of few options
This commit is contained in:
parent
961e6c4859
commit
59a8eed523
@ -1,22 +1,32 @@
|
|||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
DIR=${1}
|
if [ ! "${3}" ]; then
|
||||||
IMG=${2}
|
printf "$0 xorriso_cmd dir_in image_out [--clean]\n"
|
||||||
|
exit 1;
|
||||||
|
fi
|
||||||
|
|
||||||
|
XOR=${1}
|
||||||
|
DIR=${2}
|
||||||
|
IMG=${3}
|
||||||
|
RES="${IMG}.iso ${IMG}.new ${IMG}.md5 ${IMG}.jigdo ${IMG}.template"
|
||||||
|
|
||||||
|
# remove cruft from previous runs
|
||||||
|
# rm -f ${RES}
|
||||||
|
|
||||||
jigdo-gen-md5-list ${DIR} > ${IMG}.md5
|
jigdo-gen-md5-list ${DIR} > ${IMG}.md5
|
||||||
|
|
||||||
xorriso \
|
${XOR} \
|
||||||
-as mkisofs \
|
-as mkisofs \
|
||||||
-o ${IMG}.iso \
|
-o ${IMG}.iso \
|
||||||
-R -V 'TEST_1' \
|
-R -V 'ISO_JIGDO' \
|
||||||
-partition_offset 16 \
|
-partition_offset 16 \
|
||||||
-J -joliet-long \
|
-J -joliet-long \
|
||||||
\
|
\
|
||||||
-jigdo-template-compress gzip \
|
-jigdo-template-compress gzip \
|
||||||
-checksum_algorithm_iso md5,sha512 \
|
-checksum_algorithm_iso md5,sha1,sha256,sha512 \
|
||||||
-checksum_algorithm_template md5,sha512 \
|
-checksum_algorithm_template md5,sha1,sha256,sha512 \
|
||||||
-jigdo-jigdo ${IMG}.jigdo \
|
-jigdo-jigdo ${IMG}.jigdo \
|
||||||
-jigdo-template ${IMG}.template \
|
-jigdo-template ${IMG}.template \
|
||||||
-jigdo-map Debian=${DIR} \
|
-jigdo-map Debian=${DIR} \
|
||||||
@ -29,6 +39,14 @@ jigit-mkimage \
|
|||||||
-t ${IMG}.template \
|
-t ${IMG}.template \
|
||||||
-j ${IMG}.jigdo \
|
-j ${IMG}.jigdo \
|
||||||
-m Debian=${DIR} \
|
-m Debian=${DIR} \
|
||||||
-o ${IMG}.bak
|
-o ${IMG}.new
|
||||||
|
|
||||||
diff ${IMG}.iso ${IMG}.bak
|
diff ${IMG}.iso ${IMG}.new
|
||||||
|
|
||||||
|
# sort out the cruft
|
||||||
|
if [ "${4}" == "--clean" ]; then
|
||||||
|
rm -f ${RES}
|
||||||
|
printf "removed: %s\n" ${RES}
|
||||||
|
else
|
||||||
|
printf "left: %s\n" ${RES}
|
||||||
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user