bootstrap: Allow ./configure options on the commandline for dev mode

Change-Id: I11812d5aa19d4a293282ab776663bdfe6154069a
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
diff --git a/bootstrap.sh b/bootstrap.sh
index 9daba3b..d6c337a 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -4,7 +4,15 @@
         config.guess config.h.in config.sub configure depcomp install-sh \
         ltmain.sh missing *libtool test-driver"
 
-case $1 in
+BOOTSTRAP_MODE=""
+
+if [ $# -gt 0 ];
+then
+    BOOTSTRAP_MODE="${1}"
+    shift 1
+fi
+
+case "${BOOTSTRAP_MODE}" in
     clean)
         test -f Makefile && make maintainer-clean
         test -d linux && find linux -type d -empty | xargs -r rm -rf
@@ -13,16 +21,18 @@
         done
         exit 0
         ;;
+    *)  ;;
 esac
 
 autoreconf -i
 
-case $1 in
+case "${BOOTSTRAP_MODE}" in
     dev)
         ./configure \
             CPPFLAGS="-UNDEBUG" \
             CFLAGS="-fsanitize=address -fsanitize=leak -fsanitize=undefined -Wall -Werror" \
-            --enable-code-coverage
+            --enable-code-coverage \
+            "$@"
         ;;
     *)
         echo 'Run "./configure ${CONFIGURE_FLAGS} && make"'