blob: b902cc606593752e9ca09853d7c600c5a79add23 [file] [log] [blame]
Max8a3be282017-02-20 18:24:03 +01001#!/bin/sh
Harald Weltea06b8772017-07-10 14:58:06 +02002# jenkins build helper script for libosmo-abis. This is how we build on jenkins.osmocom.org
3
4if ! [ -x "$(command -v osmo-build-dep.sh)" ]; then
5 echo "Error: We need to have scripts/osmo-deps.sh from http://git.osmocom.org/osmo-ci/ in PATH !"
6 exit 2
7fi
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -04008
9set -ex
10
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020011base="$PWD"
12deps="$base/deps"
13inst="$deps/install"
14export deps inst
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -040015
Neels Hofmeyrd3c81da2017-10-27 22:49:59 +020016osmo-clean-workspace.sh
17
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020018mkdir "$deps" || true
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -040019
Maxd3292912017-08-25 17:22:29 +020020verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020021
Pau Espin Pedrol61460fd2018-02-20 20:21:13 +010022osmo-build-dep.sh libosmocore "" --disable-doxygen
Neels Hofmeyr3fdb2872017-03-01 15:36:24 +010023
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020024export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
25export LD_LIBRARY_PATH="$inst/lib"
Harald Welte58538de2020-08-02 10:32:48 +020026export PATH="$inst/bin:$PATH"
27
28osmo-build-dep.sh osmo-e1d
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020029
30set +x
31echo
32echo
33echo
34echo " =============================== libosmo-abis ==============================="
35echo
36set -x
37
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -040038autoreconf --install --force
Harald Welte58538de2020-08-02 10:32:48 +020039./configure --enable-sanitize --enable-werror --enable-e1d
Neels Hofmeyr04c73cb2016-10-06 23:19:41 +020040$MAKE $PARALLEL_MAKE
Pau Espin Pedrol424e50f2020-10-12 18:24:48 +020041$MAKE $PARALLEL_MAKE distcheck \
Neels Hofmeyr017752f2016-10-06 23:24:38 +020042 || cat-testlogs.sh
Pau Espin Pedrol424e50f2020-10-12 18:24:48 +020043$MAKE $PARALLEL_MAKE maintainer-clean
Neels Hofmeyrd3c81da2017-10-27 22:49:59 +020044
45osmo-clean-workspace.sh