summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xtools/buildall10
-rwxr-xr-xtools/myacprep53
-rwxr-xr-xtools/prepall12
-rwxr-xr-xtools/proof9
4 files changed, 71 insertions, 13 deletions
diff --git a/tools/buildall b/tools/buildall
new file mode 100755
index 00000000..5faf66e5
--- /dev/null
+++ b/tools/buildall
@@ -0,0 +1,10 @@
+#!/bin/sh
+
+set -e
+
+(cd ~/Products/ledger && make "$@") &
+(cd ~/Products/ledger-gcov && make "$@") &
+(cd ~/Products/ledger-gprof && make "$@") &
+(cd ~/Products/ledger-opt && make "$@") &
+
+wait
diff --git a/tools/myacprep b/tools/myacprep
index 7c4e2c14..39ed4f23 100755
--- a/tools/myacprep
+++ b/tools/myacprep
@@ -1,21 +1,48 @@
#!/bin/sh
-OUT=$HOME/Products/ledger
+OUT=$HOME/Products
+SWITCHES=""
-if [ "$1" = "--local" ]; then
- OUT=""
-elif [ "$1" = "--output" ]; then
- OUT=""
-fi
+saw_opt=false
+while [ -n "$1" ]; do
+ case "$1" in
+ --local)
+ OUT=""
+ SWITCHES="$SWITCHES --local"
+ shift 1 ;;
+ --output)
+ OUT=""
+ shift 1
+ SWITCHES="$SWITCHES --output $1"
+ shift 1 ;;
+ --gprof)
+ OUT="$OUT/ledger-gprof"
+ SWITCHES="$SWITCHES $1 --release"
+ saw_opt=true
+ shift 1 ;;
+ --gcov)
+ OUT="$OUT/ledger-gcov"
+ SWITCHES="$SWITCHES $1 --debug --devel"
+ saw_opt=true
+ shift 1 ;;
+ --opt)
+ OUT="$OUT/ledger-opt"
+ SWITCHES="$SWITCHES $1 --release"
+ saw_opt=true
+ shift 1 ;;
+ esac
+done
-SWITCHES=""
-SWITCHES="$SWITCHES --pch" # build using pre-compiled headers
-SWITCHES="$SWITCHES --warn" # show full compiler warnings
-SWITCHES="$SWITCHES --debug" # enable debug code generation
-SWITCHES="$SWITCHES --devel" # use GLIBCXX_DEBUG if possible
+if [ $saw_opt = false ]; then
+ SWITCHES="$SWITCHES --pch" # build using pre-compiled headers
+ SWITCHES="$SWITCHES --warn" # show full compiler warnings
+ SWITCHES="$SWITCHES --debug" # enable debug code generation
+ SWITCHES="$SWITCHES --devel" # use GLIBCXX_DEBUG if possible
+ OUT="$OUT/ledger"
+fi
-if [ -n "$OUT" -a -d "$OUT" ]; then
- # build in another directory, if it exists and there were no
+if [ -n "$OUT" ]; then
+ [ -d "$OUT" ] || mkdir -p "$OUT"
SWITCHES="$SWITCHES --output $OUT"
fi
diff --git a/tools/prepall b/tools/prepall
new file mode 100755
index 00000000..d6eedfdd
--- /dev/null
+++ b/tools/prepall
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+set -e
+
+tools/myacprep --opt
+tools/myacprep --gprof
+tools/myacprep --gcov
+tools/myacprep
+
+touch ~/Products/ledger-gcov/config.status
+touch ~/Products/ledger-gprof/config.status
+touch ~/Products/ledger-opt/touch config.status
diff --git a/tools/proof b/tools/proof
new file mode 100755
index 00000000..d135b606
--- /dev/null
+++ b/tools/proof
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+set -e
+
+tools/prepall
+tools/buildall clean check
+
+cd ~/Products/ledger
+make release-distcheck