Max | 1ac277d | 2018-01-18 19:15:40 +0100 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | # jenkins build helper script for libosmocore. This is how we build on jenkins.osmocom.org |
| 3 | |
| 4 | . $(dirname "$0")/jenkins_common.sh |
| 5 | |
Max | 1ac277d | 2018-01-18 19:15:40 +0100 | [diff] [blame] | 6 | src_dir="$PWD" |
| 7 | build() { |
| 8 | build_dir="$1" |
| 9 | |
| 10 | prep_build "$src_dir" "$build_dir" |
| 11 | |
Vadim Yanitskiy | 381dc61 | 2022-03-13 17:32:29 +0300 | [diff] [blame] | 12 | "$src_dir"/configure --disable-silent-rules --enable-static --enable-sanitize --enable-werror \ |
Neels Hofmeyr | d79f01e | 2018-09-12 02:53:54 +0200 | [diff] [blame] | 13 | --enable-external-tests |
Max | e41ad4d | 2018-01-18 17:37:18 +0100 | [diff] [blame] | 14 | |
| 15 | run_make |
Max | 1ac277d | 2018-01-18 19:15:40 +0100 | [diff] [blame] | 16 | } |
| 17 | |
| 18 | # verify build in dir other than source tree |
| 19 | build builddir |
| 20 | # verify build in source tree |
| 21 | build . |
| 22 | |
| 23 | # do distcheck only once, which is fine from built source tree, since distcheck |
| 24 | # is well separated from the source tree state. |
Neels Hofmeyr | 4ff41d9 | 2019-01-28 19:11:05 +0100 | [diff] [blame] | 25 | DISTCHECK_CONFIGURE_FLAGS=--enable-external-tests \ |
Pau Espin Pedrol | 3c5fa2d | 2020-10-12 17:40:00 +0200 | [diff] [blame] | 26 | $MAKE $PARALLEL_MAKE distcheck \ |
Max | 1ac277d | 2018-01-18 19:15:40 +0100 | [diff] [blame] | 27 | || cat-testlogs.sh |
Oliver Smith | a3dec04 | 2019-07-10 12:01:50 +0200 | [diff] [blame] | 28 | $MAKE maintainer-clean |
Max | 1ac277d | 2018-01-18 19:15:40 +0100 | [diff] [blame] | 29 | |
| 30 | osmo-clean-workspace.sh |