* Really add support for genisoimage (thanks for the bugreport, Worf).
* Set subdirectories of $OUTPUT independent of cmdline parsing so
it is possible to set it via conffile as well.
+ * Validate whether the specified architecture class matches the
+ architecture (option), otherwise installation of kernel will fail.
- -- Michael Prokop <mika@grml.org> Tue, 04 Aug 2009 13:16:10 +0200
+ -- Michael Prokop <mika@grml.org> Tue, 04 Aug 2009 19:26:20 +0200
grml-live (0.9.19) unstable; urgency=low
done
fi
+# validate whether the specified architecture class matches the
+# architecture (option), otherwise installation of kernel will fail
+if echo $CLASSES | grep -qi i386 ; then
+ if ! [[ "$ARCH" == "i386" ]] ; then
+ eerror "You specified the I386 class but are trying to build something else (AMD64?)."
+ eerror "-> Either invoke grml-live with '-i i386' or adjust the architecture class. Exiting."
+ bailout
+ fi
+elif echo $CLASSES | grep -qi amd64 ; then
+ if ! [[ "$ARCH" == "amd64" ]] ; then
+ eerror "You specified the AMD64 class but are trying to build something else (I386?)."
+ eerror "-> Either invoke grml-live with '-i amd64' or adjust the architecture class. Exiting."
+ bailout
+ fi
+fi
+
# set $ARCH
[ -n "$ARCH" ] || ARCH="$(dpkg --print-architecture)"
if grep -q -- 'FAI_DEBOOTSTRAP_OPTS.*--arch' "$NFSROOT_CONF" ; then
# support mkisofs as well as genisoimage
if which mkisofs >/dev/null 2>&1; then
- MKISOFS=mkisofs
+ MKISOFS='mkisofs'
elif which genisoimage >/dev/null 2>&1; then
- MKISOFS=genisoimage
+ MKISOFS='genisoimage'
else
log "Sorry, neither mkisofs nor genisoimage available - can not create ISO."
eerror "Sorry, neither mkisofs nor genisoimage available - can not create ISO." ; eend 1
CURRENT_DIR=$(pwd)
if cd "$BUILD_OUTPUT" ; then
log "$MKISOFS -V '${GRML_NAME} ${VERSION}' -publisher 'grml-live | grml.org' -l -r -J -no-emul-boot -boot-load-size 4 -boot-info-table -b $BOOT_FILE -o ${ISO_OUTPUT}/${ISO_NAME} ."
- $MKISOFS -V "${GRML_NAME} ${VERSION}" -publisher 'grml-live | grml.org' \
+ "$MKISOFS" -V "${GRML_NAME} ${VERSION}" -publisher 'grml-live | grml.org' \
-l -r -J -no-emul-boot -boot-load-size 4 -boot-info-table \
-b $BOOT_FILE -no-pad \
-o "${ISO_OUTPUT}/${ISO_NAME}" . ; RC=$?