blob: 4437541a7e6956faff3dd04f6313aa8a52fb53c1 [file] [log] [blame]
Harald Weltee57cbe22017-09-05 22:35:10 +02001#!/usr/bin/env bash
2# jenkins build helper script for openbsc. 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
Holger Hans Peter Freytherb29ff1d2016-04-13 19:02:13 -04009
10set -ex
11
Harald Weltee57cbe22017-09-05 22:35:10 +020012base="$PWD"
13deps="$base/deps"
14inst="$deps/install"
15export deps inst
16
Neels Hofmeyr29caaab2017-10-27 22:54:29 +020017osmo-clean-workspace.sh
18
Harald Weltee57cbe22017-09-05 22:35:10 +020019mkdir "$deps" || true
Harald Weltee57cbe22017-09-05 22:35:10 +020020
21osmo-build-dep.sh libosmocore "" ac_cv_path_DOXYGEN=false
22
Maxb87da752017-08-25 17:37:36 +020023verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
24
Harald Weltee57cbe22017-09-05 22:35:10 +020025export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
26export LD_LIBRARY_PATH="$inst/lib"
Holger Hans Peter Freytherb29ff1d2016-04-13 19:02:13 -040027
Harald Weltee57cbe22017-09-05 22:35:10 +020028set +x
29echo
30echo
31echo
Maxea70f362017-09-15 12:16:53 +020032echo " =============================== OsmoGGSN ==============================="
Harald Weltee57cbe22017-09-05 22:35:10 +020033echo
34set -x
35
36cd "$base"
Holger Hans Peter Freytherb29ff1d2016-04-13 19:02:13 -040037autoreconf --install --force
Pau Espin Pedrola00e7922017-11-16 17:08:36 +010038./configure CFLAGS="-Werror" CPPFLAGS="-Werror" $GTP
Harald Weltee57cbe22017-09-05 22:35:10 +020039$MAKE $PARALLEL_MAKE
40$MAKE distcheck
Neels Hofmeyr29caaab2017-10-27 22:54:29 +020041
42osmo-clean-workspace.sh