aboutsummaryrefslogtreecommitdiffstats
path: root/coverity/prepare_source_Osmocom.sh
diff options
context:
space:
mode:
Diffstat (limited to 'coverity/prepare_source_Osmocom.sh')
-rwxr-xr-xcoverity/prepare_source_Osmocom.sh21
1 files changed, 16 insertions, 5 deletions
diff --git a/coverity/prepare_source_Osmocom.sh b/coverity/prepare_source_Osmocom.sh
index 122fc1c..2c69356 100755
--- a/coverity/prepare_source_Osmocom.sh
+++ b/coverity/prepare_source_Osmocom.sh
@@ -1,6 +1,9 @@
-#!/bin/sh
+#!/bin/sh -xe
+. $(realpath common.sh)
BASEDIR=source-Osmocom
+osmo_cmd_require sdcc
+
# How to add a new project:
# * add it to the list below
# * add it to build_Osmocom.sh
@@ -39,32 +42,40 @@ PROJECTS="
osmo-hnodeb
osmo-hnbgw
osmo-bsc-nat
+ osmo-pcap
+ osmo-e1d
+ osmo-e1-recorder
+ libgtpnl
+ osmo-upf
+ osmo-isdntap
+ osmo-uecups
+ osmo-remsim
"
PROJECTS_DONT_BUILD_TEST="
asn1c
"
-[ -d $BASEDIR ] || mkdir -p $BASEDIR
+mkdir -p $BASEDIR
cd $BASEDIR
for proj in $PROJECTS $PROJECTS_DONT_BUILD_TEST; do
if [ -d $proj ]; then
if [ -z "$SRC_SKIP_FETCH" ]; then
- (cd $proj && git fetch && git checkout -f -B master origin/master)
+ (cd $proj && git fetch && git checkout -f -B master origin/master && git submodule update --recursive --remote)
fi
if [ -n "$SRC_CLEAN" ]; then
git -C "$proj" clean -ffxd
fi
else
- git clone https://git.osmocom.org/$proj
+ git clone --recursive "$(osmo_git_clone_url "$proj")"
fi
done
# We want to compile tests, but not execute them. Using 'noinst_PROGRAMS'
# instead of 'check_PROGRAMS' allows building test binaries during 'make all'.
for proj in $PROJECTS; do
- files="$(git -C $proj grep -l check_PROGRAMS)"
+ files="$(git -C $proj grep -l check_PROGRAMS)" || true
if [ -n "$files" ]; then
(cd $proj && sed -i "s/check_PROGRAMS/noinst_PROGRAMS/" $files)
fi