blob: d159db911192d6cc929b13cd9e1fb07d4f02159c [file] [log] [blame]
Neels Hofmeyr40d8b012016-12-11 00:27:48 +01001#!/bin/sh
Harald Welte0b1b6b12017-07-10 15:05:03 +02002# jenkins build helper script for osmo-hlr. 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
8
Neels Hofmeyr40d8b012016-12-11 00:27:48 +01009
10set -ex
11
12base="$PWD"
13deps="$base/deps"
14inst="$deps/install"
15export deps inst
16
Neels Hofmeyrc6a6d262017-10-27 22:54:31 +020017osmo-clean-workspace.sh
18
Neels Hofmeyr40d8b012016-12-11 00:27:48 +010019mkdir "$deps" || true
Neels Hofmeyr40d8b012016-12-11 00:27:48 +010020
Max05c8b462017-08-25 17:47:42 +020021verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
22
Neels Hofmeyr40d8b012016-12-11 00:27:48 +010023export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
24export LD_LIBRARY_PATH="$inst/lib"
25
26osmo-build-dep.sh libosmocore "" ac_cv_path_DOXYGEN=false
Neels Hofmeyr40d8b012016-12-11 00:27:48 +010027osmo-build-dep.sh libosmo-abis
28
29set +x
30echo
31echo
32echo
33echo " =============================== osmo-hlr ==============================="
34echo
35set -x
36
37cd "$base"
38autoreconf --install --force
Neels Hofmeyrf95ce042017-09-25 23:22:02 +020039./configure --enable-external-tests
Neels Hofmeyr40d8b012016-12-11 00:27:48 +010040$MAKE $PARALLEL_MAKE
Max886ecef2017-07-11 15:16:16 +020041if [ "x$label" != "xFreeBSD_amd64" ]; then
42 $MAKE check || cat-testlogs.sh
43 $MAKE distcheck || cat-testlogs.sh
44fi
Neels Hofmeyrc6a6d262017-10-27 22:54:31 +020045
46osmo-clean-workspace.sh