forked from opprop/units-inference
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcompile.sh
executable file
·53 lines (41 loc) · 900 Bytes
/
compile.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
#!/bin/bash
# Fail the whole script if any command fails
set -e
myDir="`dirname $0`"
case `uname -s` in
CYGWIN*)
myDir=`cygpath -m $mydir`
;;
esac
if [ "$myDir" = "" ];
then
myDir="."
fi
ROOT=$(cd ${myDir} && pwd)
# use system installed coqc if available
# if version dependent: && [[ $(coqc -v | grep 8.8.0) ]]
if [[ $(command -v coqc) ]] ; then
COQC=$(command -v coqc)
fi
if [ -z "$COQC" ] && [ -e $ROOT/coq-source/bin/coqc ] ; then
COQC="$ROOT/coq-source/bin/coqc"
fi
echo "Using coqc at $COQC"
$COQC -v
# Compile options
COQC="$COQC -opt"
$COQC TacticalLemmas.v
$COQC IDDefs.v
$COQC MapsDefs.v
$COQC UnitsDefs.v
$COQC ValueDefs.v
$COQC GammaDefs.v
$COQC HeapDefs.v
$COQC SubtypingDefs.v
$COQC GammaHeapCorrespondence.v
$COQC UnitsArithmetics.v
$COQC FieldDefs.v
$COQC ExpressionDefs.v
$COQC StatementDefs.v
$COQC ProgramDefs.v
echo "Compilation complete."