Skip to content

Commit

Permalink
tested again with clang
Browse files Browse the repository at this point in the history
  • Loading branch information
Armin Biere committed Mar 30, 2020
1 parent 3d9ca53 commit 3ce7dc3
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions configure
Original file line number Diff line number Diff line change
@@ -1,15 +1,27 @@
#!/bin/sh
debug=no
usage () {
cat <<EOF
usage: configure [ -g | CC=<compiler> ]
-g compile for debugging (assertion checking and symbols)
CC=<compiler> force C compiler (default 'gcc', tested also with 'clang')
You can also choose the compiler through the environment variable 'CC'.
EOF
}
while [ $# -gt 0 ]
do
case $1 in
-h) echo "usage: configure [ -g ]"; exit 0;;
-h) usage; exit 0;;
-g) debug=yes;;
CC=*) CC=`echo "$1" | sed -e s,^CC=,,`;;
-*) echo "configure: error: invalid option '$1' (try '-h')"; exit 1;;
esac
shift
done
COMPILE="gcc -Wall"
[ x"$CC" = x ] && CC=gcc
COMPILE="$CC -Wall"
if [ $debug = yes ]
then
COMPILE="$COMPILE -g3"
Expand Down

0 comments on commit 3ce7dc3

Please sign in to comment.