blob: ac02a3006b6a36d01d5039a3c9b0508b8da08369 [file] [log] [blame]
Jeremy Kerrb2ef62b2019-05-28 09:38:25 +08001#!/bin/sh
Andrew Jeffery95a8a442020-03-10 22:09:02 +10302
3set -eu
4
5autoreconf -f -i
6
7
8BOOTSTRAP_MODE=""
9
10if [ $# -gt 0 ];
11then
12 BOOTSTRAP_MODE="${1}"
13 shift 1
14fi
15
16case "${BOOTSTRAP_MODE}" in
17 dev)
18 FLAGS="-fsanitize=address,leak,undefined -Wformat -Werror=format-security -Werror=array-bounds -ggdb"
19 ./configure \
20 CFLAGS="${FLAGS}" \
21 CXXFLAGS="${FLAGS}" \
22 --enable-code-coverage \
23 "$@"
24 ;;
25 *)
26 echo 'Run "./configure ${CONFIGURE_FLAGS} && make"'
27 ;;
28esac