summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2019-03-16 21:54:52 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-03-16 21:54:55 -0700
commit3d193c7fdb6d29cb94a50e2169d0361a2fde087e (patch)
treef1ac4f7b5988bcea5cf4a049d0c0bed7c896cab4 /scripts
parent0a25b32ca07c996c7fccc4cecfa50c58081de345 (diff)
downloadsubsurface-3d193c7fdb6d29cb94a50e2169d0361a2fde087e.tar.gz
build-system: add script to build only libdivecomputer
This is used on LGTM (and initially got lost when I merged those changes). Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/build-libdivecomputer.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/scripts/build-libdivecomputer.sh b/scripts/build-libdivecomputer.sh
new file mode 100755
index 000000000..e3f50b2ca
--- /dev/null
+++ b/scripts/build-libdivecomputer.sh
@@ -0,0 +1,25 @@
+#!/bin/bash
+#
+# this should be run from the subsurface directory
+
+if [ ! -d libdivecomputer/src ] ; then
+ git submodule init
+ git submodule update --recursive
+fi
+
+mkdir -p libdivecomputer/build
+cd libdivecomputer/build
+
+if [ ! -f ../configure ] ; then
+ # this is not a typo
+ # in some scenarios it appears that autoreconf doesn't copy the
+ # ltmain.sh file; running it twice, however, fixes that problem
+ autoreconf --install ..
+ autoreconf --install ..
+fi
+
+../configure --disable-examples --prefix=$INSTALL_ROOT
+
+
+make -j4
+make install