Project

General

Profile

Statistics
| Branch: | Revision:

cool / makestatic.sh @ 4caf8f04

History | View | Annotate | Download (987 Bytes)

1 02491e96 Thorsten Wißmann
#!/bin/bash -e
2 9066f726 Thorsten Wißmann
3
4
::() { echo ":: $*" ; "$@" ; }
5
die() { echo "$*" ; exit 1 ; }
6
7
[ -d .git ] || die "$0 only works in the git-repository!"
8
9 3e5fbf7e Thorsten Wißmann
dir=cool-$(uname -m)-$(date +%Y-%m-%d-%H-%M)
10 9066f726 Thorsten Wißmann
:: mkdir -p $dir
11
:: pushd $dir
12
:: git --git-dir=.git pull || :: git clone .. .
13
14
make clean
15
oasis setup
16
ocaml setup.ml -configure --enable-static
17
ocaml setup.ml -build
18
19
files=(
20
)
21
22
binary() {
23
    files+=( "$1" )
24
    cp $1.native $1
25
}
26
27
binary coalg
28
binary cool-testsuite
29
binary coalgcompare
30
binary cool-owl
31
32
files+=(
33
    *.sh
34
    BUGS
35
    INSTALL
36
    VERSION
37
    _oasis
38
    testbench/
39
    cool2tatl
40
    setup.ml
41
    src/
42 4caf8f04 Hans-Peter Deifel
    benchmarks/aconjunctive_mu/
43 9066f726 Thorsten Wißmann
)
44
45
cat >VERSION <<EOF
46
COOL Static Linux-Binaries
47
==========================
48
This version of COOL was...
49
  - build on $(date).
50
  - build for the architecture $(uname -m).
51 4caf8f04 Hans-Peter Deifel
  - distributed with a subset of all benchmarks (to reduce file size)
52 9066f726 Thorsten Wißmann
53
54
Last commit
55
-----------
56
$(git log HEAD~1..)
57
58
EOF
59
60
popd
61
62
zip -r "$dir.zip" $(printf "$dir/%s\n" "${files[@]}")