summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2020-04-12 12:42:55 +0200
committerSven Gothel <[email protected]>2020-04-12 12:42:55 +0200
commit6505f49b63db200d817817d1d01a14005a3d732c (patch)
tree2e1777ee808c4d1ab231eb43dc1943d587eecb91 /scripts
parent61db1fb4d0a1f918929082db67a0279647986d38 (diff)
build scripts: log outputv2.1.0
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/build-armhf.sh37
-rwxr-xr-xscripts/build-x86_64.sh36
2 files changed, 44 insertions, 29 deletions
diff --git a/scripts/build-armhf.sh b/scripts/build-armhf.sh
index 78eaee98..a2d2d05f 100755
--- a/scripts/build-armhf.sh
+++ b/scripts/build-armhf.sh
@@ -2,22 +2,29 @@
sdir=`dirname $(readlink -f $0)`
rootdir=`dirname $sdir`
-echo rootdir $rootdir
+logfile=`basename $0 .sh`.log
+rm -f $logfile
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-armhf
-cd $rootdir
-rm -rf dist-armhf
-mkdir -p dist-armhf/bin
-rm -rf build-armhf
-mkdir build-armhf
-cd build-armhf
-cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-armhf -DBUILDJAVA=ON -DBUILDEXAMPLES=ON ..
-# cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-armhf -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON ..
-cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-armhf -DBUILDEXAMPLES=ON -DDEBUG=ON -DBUILD_TESTING=ON ..
-make
-make test
-make install
-cp -a examples/* $rootdir/dist-armhf/bin
+doit() {
+ echo rootdir $rootdir
+ echo logfile $logfile
-cd $rootdir
+ cd $rootdir
+ rm -rf dist-armhf
+ mkdir -p dist-armhf/bin
+ rm -rf build-armhf
+ mkdir build-armhf
+ cd build-armhf
+ cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-armhf -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON ..
+ #cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-armhf -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON -DDEBUG=ON ..
+ make
+ make test
+ make install
+ cp -a examples/* $rootdir/dist-armhf/bin
+
+ cd $rootdir
+}
+
+doit 2>&1 | tee $logfile
diff --git a/scripts/build-x86_64.sh b/scripts/build-x86_64.sh
index 12d56130..b6de4d29 100755
--- a/scripts/build-x86_64.sh
+++ b/scripts/build-x86_64.sh
@@ -2,21 +2,29 @@
sdir=`dirname $(readlink -f $0)`
rootdir=`dirname $sdir`
-echo rootdir $rootdir
+logfile=`basename $0 .sh`.log
+rm -f $logfile
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64
-cd $rootdir
-rm -rf dist-x86_64
-mkdir -p dist-x86_64/bin
-rm -rf build-x86_64
-mkdir build-x86_64
-cd build-x86_64
-# cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-x86_64 -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON ..
-cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-x86_64 -DBUILDEXAMPLES=ON -DDEBUG=ON -DBUILD_TESTING=ON ..
-make
-make test
-make install
-cp -a examples/* $rootdir/dist-x86_64/bin
+doit() {
+ echo rootdir $rootdir
+ echo logfile $logfile
-cd $rootdir
+ cd $rootdir
+ rm -rf dist-x86_64
+ mkdir -p dist-x86_64/bin
+ rm -rf build-x86_64
+ mkdir -p build-x86_64
+ cd build-x86_64
+ cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-x86_64 -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON ..
+ #cmake -DCMAKE_INSTALL_PREFIX=$rootdir/dist-x86_64 -DBUILDJAVA=ON -DBUILDEXAMPLES=ON -DBUILD_TESTING=ON -DDEBUG=ON ..
+ make
+ make test
+ make install
+ cp -a examples/* $rootdir/dist-x86_64/bin
+
+ cd $rootdir
+}
+
+doit 2>&1 | tee $logfile