[PATCH] osmo-bts[master]: Move common steps into common jenkins helper

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Max gerrit-no-reply at lists.osmocom.org
Tue Jun 13 17:06:55 UTC 2017


Hello Neels Hofmeyr, Jenkins Builder,

I'd like you to reexamine a change.  Please visit

    https://gerrit.osmocom.org/2894

to look at the new patch set (#7).

Move common steps into common jenkins helper

Move value_string termination check and OpenBSC headers checkout into
shared jenkins helper from BTS' model-specific helpers to get rid of
copy-pasted code. While at it - also remove unnecessary bash
dependency.

Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408
---
M contrib/jenkins_bts_trx.sh
M contrib/jenkins_oct.sh
M contrib/jenkins_oct_and_bts_trx.sh
M contrib/jenkins_sysmobts.sh
4 files changed, 12 insertions(+), 80 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/7

diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh
index dbd41ca..3524b41 100755
--- a/contrib/jenkins_bts_trx.sh
+++ b/contrib/jenkins_bts_trx.sh
@@ -1,33 +1,14 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
-set -ex
-
-base="$PWD"
-deps="$base/deps"
-inst="$deps/install"
-export deps inst
-
-mkdir "$deps" || true
-rm -rf "$inst"
+# shellcheck source=contrib/jenkins_common_prefix.sh
+. $(dirname "$0")/jenkins_common_prefix.sh
 
 export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
 export LD_LIBRARY_PATH="$inst/lib"
 
 osmo-build-dep.sh libosmocore
 
-"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
-
 osmo-build-dep.sh libosmo-abis
-
-cd "$deps"
-
-# Get osmo-pcu for pcuif_proto.h
-osmo-deps.sh osmo-pcu
-
-# Get openbsc for gsm_data_shared.*
-osmo-deps.sh openbsc
-
-cd "$base"
 
 set +x
 echo
diff --git a/contrib/jenkins_oct.sh b/contrib/jenkins_oct.sh
index 9f06888..7606839 100755
--- a/contrib/jenkins_oct.sh
+++ b/contrib/jenkins_oct.sh
@@ -1,25 +1,9 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
-set -ex
-
-base="$PWD"
-deps="$base/deps"
-inst="$deps/install"
-export deps inst
-
-mkdir "$deps" || true
-rm -rf "$inst"
-
-# Get the headers..
-cd "$deps"
-git clone git://git.osmocom.org/openbsc || true
-cd openbsc
-git pull --rebase
-cd "$base"
+# shellcheck source=contrib/jenkins_common_prefix.sh
+. $(dirname "$0")/jenkins_common_prefix.sh
 
 osmo-build-dep.sh libosmocore
-
-"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
 
 export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
 export LD_LIBRARY_PATH="$inst/lib"
diff --git a/contrib/jenkins_oct_and_bts_trx.sh b/contrib/jenkins_oct_and_bts_trx.sh
index 93aa47a..97c0049 100755
--- a/contrib/jenkins_oct_and_bts_trx.sh
+++ b/contrib/jenkins_oct_and_bts_trx.sh
@@ -1,31 +1,14 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
-set -ex
-
-base="$PWD"
-deps="$base/deps"
-inst="$deps/install"
-export deps inst
-
-mkdir "$deps" || true
-rm -rf "$inst"
+# shellcheck source=contrib/jenkins_common_prefix.sh
+. $(dirname "$0")/jenkins_common_prefix.sh
 
 export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
 export LD_LIBRARY_PATH="$inst/lib"
 
 osmo-build-dep.sh libosmocore
 
-"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
-
 osmo-build-dep.sh libosmo-abis
-
-cd "$deps"
-
-# Get osmo-pcu for pcuif_proto.h
-osmo-deps.sh osmo-pcu
-
-# Get openbsc for gsm_data_shared.*
-osmo-deps.sh openbsc
 
 cd "$deps"
 if ! test -d layer1-api;
diff --git a/contrib/jenkins_sysmobts.sh b/contrib/jenkins_sysmobts.sh
index c6f109d..86c3e7f 100755
--- a/contrib/jenkins_sysmobts.sh
+++ b/contrib/jenkins_sysmobts.sh
@@ -1,25 +1,9 @@
-#!/usr/bin/env bash
+#!/bin/sh
 
-set -ex
-
-base="$PWD"
-deps="$base/deps"
-inst="$deps/install"
-export deps inst
-
-mkdir "$deps" || true
-rm -rf "$inst"
-
-# Get the headers..
-cd "$deps"
-git clone git://git.osmocom.org/openbsc || true
-cd openbsc
-git pull --rebase
-cd "$base"
+# shellcheck source=contrib/jenkins_common_prefix.sh
+. $(dirname "$0")/jenkins_common_prefix.sh
 
 osmo-build-dep.sh libosmocore
-
-"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
 
 export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH"
 export LD_LIBRARY_PATH="$inst/lib"

-- 
To view, visit https://gerrit.osmocom.org/2894
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408
Gerrit-PatchSet: 7
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Max <msuraev at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de>



More information about the gerrit-log mailing list