From: Darshaka Pathirana Date: Sat, 25 Feb 2012 02:24:56 +0000 (+0100) Subject: detect architecture before checkconfiguration X-Git-Tag: v0.52~3 X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=commitdiff_plain;h=344f0e99017fdc780208fc661621522f579a6ba4;ds=sidebyside detect architecture before checkconfiguration --- diff --git a/grml-debootstrap b/grml-debootstrap index 1a71c16..89b5adc 100755 --- a/grml-debootstrap +++ b/grml-debootstrap @@ -774,6 +774,17 @@ if [ -z "$TARGET" -o -n "$INTERACTIVE" ] ; then fi # }}} +# architecture setup {{{ +if [ -n "$ARCH" ] ; then + ARCHCMD="--arch $ARCH" + ARCHINFO=" (${ARCH})" +else + ARCH="$(dpkg --print-architecture)" + ARCHCMD="--arch $ARCH" + ARCHINFO=" (${ARCH})" +fi +# }}} + checkconfiguration # finally make sure at least $TARGET is set [the partition for the new system] {{{ @@ -825,17 +836,6 @@ else fi # }}} -# architecture setup {{{ -if [ -n "$ARCH" ] ; then - ARCHCMD="--arch $ARCH" - ARCHINFO=" (${ARCH})" -else - ARCH="$(dpkg --print-architecture)" - ARCHCMD="--arch $ARCH" - ARCHINFO=" (${ARCH})" -fi -# }}} - # make sure we have the right syntax when using an iso image {{{ if [ -n "$ISO" ] ; then case $ISO in