blob: 769d5a71393535f885cb984c1bdcb26106d69d63 [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 Hofmeyrfdcb9612016-10-06 23:23:24 +020016mkdir "$deps" || true
17rm -rf "$inst"
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -040018
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020019osmo-build-dep.sh libosmocore
20
Neels Hofmeyr3fdb2872017-03-01 15:36:24 +010021"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
22
Neels Hofmeyrfdcb9612016-10-06 23:23:24 +020023export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
24export LD_LIBRARY_PATH="$inst/lib"
25
26set +x
27echo
28echo
29echo
30echo " =============================== libosmo-abis ==============================="
31echo
32set -x
33
Holger Hans Peter Freyther7c9337b2016-04-13 18:52:43 -040034autoreconf --install --force
Pau Espin Pedrol35003ec2017-07-05 22:04:43 +020035./configure --enable-sanitize CFLAGS="-Werror" CPPFLAGS="-Werror"
Neels Hofmeyr04c73cb2016-10-06 23:19:41 +020036$MAKE $PARALLEL_MAKE
Neels Hofmeyr017752f2016-10-06 23:24:38 +020037$MAKE distcheck \
38 || cat-testlogs.sh