summaryrefslogtreecommitdiffstats
path: root/contrib/jenkins_amd64.sh
blob: 9b83793060ae96db29f4d615439f117d5deffc5a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh
# jenkins build helper script for libosmocore. This is how we build on jenkins.osmocom.org

. $(dirname "$0")/jenkins_common.sh

ENABLE_SANITIZE="--enable-sanitize"

if [ "x$label" = "xFreeBSD_amd64" ]; then
        ENABLE_SANITIZE=""
fi

src_dir="$PWD"
build() {
    build_dir="$1"

    prep_build "$src_dir" "$build_dir"

    "$src_dir"/configure  --disable-silent-rules --enable-static $ENABLE_SANITIZE --enable-werror \
        --enable-external-tests

    run_make
}

# verify build in dir other than source tree
build builddir
# verify build in source tree
build .

# do distcheck only once, which is fine from built source tree, since distcheck
# is well separated from the source tree state.
DISTCHECK_CONFIGURE_FLAGS=--enable-external-tests \
    $MAKE distcheck \
    || cat-testlogs.sh

osmo-clean-workspace.sh