summaryrefslogtreecommitdiffstats
path: root/bootstrap.sh
diff options
context:
space:
mode:
authorAndrew Jeffery <andrew@aj.id.au>2017-05-29 16:41:30 +0930
committerPatrick Williams <patrick@stwcx.xyz>2017-05-31 13:05:47 +0000
commit58b3cc075d61c5dc10d52a142db907689b8beb80 (patch)
tree47a9b77bd4d76ee1ae8ae4fd13c61fb4f6aa44a6 /bootstrap.sh
parenta0370754482249db7d6e9c9a6de743ab65006b03 (diff)
downloadphosphor-mboxd-58b3cc075d61c5dc10d52a142db907689b8beb80.tar.gz
phosphor-mboxd-58b3cc075d61c5dc10d52a142db907689b8beb80.zip
bootstrap: Allow ./configure options on the commandline for dev mode
Change-Id: I11812d5aa19d4a293282ab776663bdfe6154069a Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Diffstat (limited to 'bootstrap.sh')
-rwxr-xr-xbootstrap.sh16
1 files changed, 13 insertions, 3 deletions
diff --git a/bootstrap.sh b/bootstrap.sh
index 9daba3b..d6c337a 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -4,7 +4,15 @@ AUTOCONF_FILES="Makefile.in aclocal.m4 ar-lib autom4te.cache compile \
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 @@ case $1 in
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"'
OpenPOWER on IntegriCloud