[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
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 (#11). 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 A contrib/jenkins_common.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 36 insertions(+), 69 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/11 diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..076a4ff 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -1,21 +1,12 @@ -#!/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.sh +. $(dirname "$0")/jenkins_common.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 @@ -23,9 +14,6 @@ # Get osmo-pcu for pcuif_proto.h osmo-deps.sh osmo-pcu - -# Get openbsc for gsm_data_shared.* -osmo-deps.sh openbsc cd "$base" diff --git a/contrib/jenkins_common.sh b/contrib/jenkins_common.sh new file mode 100644 index 000..824dd43 --- /dev/null +++ b/contrib/jenkins_common.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +set -ex + +base="$PWD" +deps="$base/deps" +inst="$deps/install" + +export deps inst + +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") diff --git a/contrib/jenkins_oct.sh b/contrib/jenkins_oct.sh index 9f06888..0f926c9 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.sh +. $(dirname "$0")/jenkins_common.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..132c2e0 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -1,21 +1,12 @@ -#!/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.sh +. $(dirname "$0")/jenkins_common.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 @@ -24,10 +15,6 @@ # 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; then git clone git://git.osmocom.org/octphy-2g-headers layer1-api diff --git a/contrib/jenkins_sysmobts.sh b/contrib/jenkins_sysmobts.sh index c6f109d..bce0690 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.sh +. $(dirname "$0")/jenkins_common.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: 11 Gerrit-Project: osmo-bts
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
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 (#10). 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 A contrib/jenkins_common.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 36 insertions(+), 74 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/10 diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..84c572c 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -1,33 +1,17 @@ -#!/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.sh +. $(dirname "$0")/jenkins_common.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_common.sh b/contrib/jenkins_common.sh new file mode 100644 index 000..824dd43 --- /dev/null +++ b/contrib/jenkins_common.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +set -ex + +base="$PWD" +deps="$base/deps" +inst="$deps/install" + +export deps inst + +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") diff --git a/contrib/jenkins_oct.sh b/contrib/jenkins_oct.sh index 9f06888..0f926c9 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.sh +. $(dirname "$0")/jenkins_common.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..d57c9eb 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -1,31 +1,17 @@ -#!/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.sh +. $(dirname "$0")/jenkins_common.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..bce0690 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.sh +. $(dirname "$0")/jenkins_common.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: 10 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: Max
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
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 (#9). 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 A contrib/jenkins_common.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 36 insertions(+), 80 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/9 diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..bde9f38 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.sh +. $(dirname "$0")/jenkins_common.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_common.sh b/contrib/jenkins_common.sh new file mode 100644 index 000..824dd43 --- /dev/null +++ b/contrib/jenkins_common.sh @@ -0,0 +1,24 @@ +#!/bin/sh + +set -ex + +base="$PWD" +deps="$base/deps" +inst="$deps/install" + +export deps inst + +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") diff --git a/contrib/jenkins_oct.sh b/contrib/jenkins_oct.sh index 9f06888..0f926c9 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.sh +. $(dirname "$0")/jenkins_common.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..ed1edbc 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.sh +. $(dirname "$0")/jenkins_common.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..bce0690 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.sh +. $(dirname "$0")/jenkins_common.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: 9 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: Max
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
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 (#8). 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/8 diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..bde9f38 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.sh +. $(dirname "$0")/jenkins_common.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..0f926c9 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.sh +. $(dirname "$0")/jenkins_common.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..ed1edbc 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.sh +. $(dirname "$0")/jenkins_common.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..bce0690 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.sh +. $(dirname "$0")/jenkins_common.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: 8 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Max Gerrit-Reviewer: Neels Hofmeyr Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
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: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Neels Hofmeyr Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/2894 to look at the new patch set (#5). Move common steps into common jenkins helper Move value_string termination check and OpenBSC/OsmoPCU headers checkout into shared jenkins helper from BTS' model-specific helpers to get rid of copy-pasted code. Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 --- M contrib/jenkins_bts_model.sh M contrib/jenkins_bts_trx.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 22 insertions(+), 52 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/5 diff --git a/contrib/jenkins_bts_model.sh b/contrib/jenkins_bts_model.sh index 58eac5b..9a012ca 100755 --- a/contrib/jenkins_bts_model.sh +++ b/contrib/jenkins_bts_model.sh @@ -1,5 +1,9 @@ #!/bin/sh + bts_model="$1" +base="$PWD" +deps="$base/deps" +inst="$deps/install" if [ ! -d "./contrib" ]; then echo "Run ./contrib/jenkins_bts_model.sh from the root of the osmo-bts tree" @@ -8,6 +12,24 @@ set -x -e +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get OsmoPCU for pcuif_proto.h +osmo-deps.sh osmo-pcu + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") + case "$bts_model" in sysmo) diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..140cfc5 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -7,27 +7,12 @@ inst="$deps/install" export deps inst -mkdir "$deps" || true -rm -rf "$inst" - 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..25f272b 100755 --- a/contrib/jenkins_oct.sh +++ b/contrib/jenkins_oct.sh @@ -7,19 +7,7 @@ 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" - 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..1ff0cfa 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -7,25 +7,12 @@ inst="$deps/install" export deps inst -mkdir "$deps" || true -rm -rf "$inst" - 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..e2f29ce 100755 --- a/contrib/jenkins_sysmobts.sh +++ b/contrib/jenkins_sysmobts.sh @@ -7,19 +7,7 @@ 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" - 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: 5 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/2894 to look at the new patch set (#4). Move common steps into common jenkins helper Move value_string termination check and OpenBSC/OsmoPCU headers checkout into shared jenkins helper from BTS' model-specific helpers to get rid of copy-pasted code. Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 --- M contrib/jenkins_bts_model.sh M contrib/jenkins_bts_trx.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 28 insertions(+), 52 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/4 diff --git a/contrib/jenkins_bts_model.sh b/contrib/jenkins_bts_model.sh index 58eac5b..06454a7 100755 --- a/contrib/jenkins_bts_model.sh +++ b/contrib/jenkins_bts_model.sh @@ -1,5 +1,11 @@ #!/bin/sh + bts_model="$1" +base="$PWD" +deps="$base/deps" +inst="$deps/install" + +export deps inst if [ ! -d "./contrib" ]; then echo "Run ./contrib/jenkins_bts_model.sh from the root of the osmo-bts tree" @@ -8,6 +14,24 @@ set -x -e +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get OsmoPCU for pcuif_proto.h +osmo-deps.sh osmo-pcu + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") + case "$bts_model" in sysmo) diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..1d7fdbc 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -5,29 +5,15 @@ base="$PWD" deps="$base/deps" inst="$deps/install" -export deps inst -mkdir "$deps" || true -rm -rf "$inst" +export deps inst 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..85e584e 100755 --- a/contrib/jenkins_oct.sh +++ b/contrib/jenkins_oct.sh @@ -5,21 +5,10 @@ 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" - 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..81101dd 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -5,27 +5,15 @@ base="$PWD" deps="$base/deps" inst="$deps/install" -export deps inst -mkdir "$deps" || true -rm -rf "$inst" +export deps inst 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..d479091 100755 --- a/contrib/jenkins_sysmobts.sh +++ b/contrib/jenkins_sysmobts.sh @@ -5,21 +5,10 @@ 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" - 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: 4 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/2894 to look at the new patch set (#3). Move common steps into common jenkins helper Move value_string termination check and OpenBSC/OsmoPCU headers checkout into shared jenkins helper from BTS' model-specific helpers to get rid of copy-pasted code. Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 --- M contrib/jenkins_bts_model.sh M contrib/jenkins_bts_trx.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 26 insertions(+), 72 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/3 diff --git a/contrib/jenkins_bts_model.sh b/contrib/jenkins_bts_model.sh index 58eac5b..3e7534b 100755 --- a/contrib/jenkins_bts_model.sh +++ b/contrib/jenkins_bts_model.sh @@ -1,5 +1,13 @@ #!/bin/sh + bts_model="$1" +base="$PWD" +deps="$base/deps" +inst="$deps/install" + +export deps inst + +rm -rf "$inst" if [ ! -d "./contrib" ]; then echo "Run ./contrib/jenkins_bts_model.sh from the root of the osmo-bts tree" @@ -8,6 +16,24 @@ set -x -e +mkdir -p "$deps" +rm -rf "$inst" + +cd "$deps" + +# Get OsmoPCU for pcuif_proto.h +osmo-deps.sh osmo-pcu + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") + case "$bts_model" in sysmo) diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..f10b21b 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -2,32 +2,12 @@ set -ex -base="$PWD" -deps="$base/deps" -inst="$deps/install" -export deps inst - -mkdir "$deps" || true -rm -rf "$inst" - 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..5da944d 100755 --- a/contrib/jenkins_oct.sh +++ b/contrib/jenkins_oct.sh @@ -2,24 +2,7 @@ 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" - 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..90a5138 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -2,30 +2,12 @@ set -ex -base="$PWD" -deps="$base/deps" -inst="$deps/install" -export deps inst - -mkdir "$deps" || true -rm -rf "$inst" - 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..724a50f 100755 --- a/contrib/jenkins_sysmobts.sh +++ b/contrib/jenkins_sysmobts.sh @@ -2,24 +2,7 @@ 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" - 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: 3 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
Hello Jenkins Builder, I'd like you to reexamine a change. Please visit https://gerrit.osmocom.org/2894 to look at the new patch set (#2). Move common steps into common jenkins helper Move value_string termination check and OpenBSC/OsmoPCU headers checkout into shared jenkins helper from BTS' model-specific helpers to get rid of copy-pasted code. Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 --- M contrib/jenkins_bts_model.sh M contrib/jenkins_bts_trx.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 19 insertions(+), 44 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/2 diff --git a/contrib/jenkins_bts_model.sh b/contrib/jenkins_bts_model.sh index 58eac5b..8f95524 100755 --- a/contrib/jenkins_bts_model.sh +++ b/contrib/jenkins_bts_model.sh @@ -1,5 +1,7 @@ #!/bin/sh bts_model="$1" +base="$PWD" +deps="$base/deps" if [ ! -d "./contrib" ]; then echo "Run ./contrib/jenkins_bts_model.sh from the root of the osmo-bts tree" @@ -8,6 +10,23 @@ set -x -e +mkdir -p "$deps" + +cd "$deps" + +# Get OsmoPCU for pcuif_proto.h +osmo-deps.sh osmo-pcu + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") + case "$bts_model" in sysmo) diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..abe7a85 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -7,7 +7,6 @@ inst="$deps/install" export deps inst -mkdir "$deps" || true rm -rf "$inst" export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH" @@ -15,19 +14,7 @@ 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..c2c988b 100755 --- a/contrib/jenkins_oct.sh +++ b/contrib/jenkins_oct.sh @@ -7,19 +7,9 @@ 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" - 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..7d41c1e 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -7,7 +7,6 @@ inst="$deps/install" export deps inst -mkdir "$deps" || true rm -rf "$inst" export PKG_CONFIG_PATH="$inst/lib/pkgconfig:$PKG_CONFIG_PATH" @@ -15,17 +14,7 @@ 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..4568e63 100755 --- a/contrib/jenkins_sysmobts.sh +++ b/contrib/jenkins_sysmobts.sh @@ -7,19 +7,9 @@ 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" - 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: 2 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: MaxGerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: neels
[PATCH] osmo-bts[master]: Move common steps into common jenkins helper
Review at https://gerrit.osmocom.org/2894 Move common steps into common jenkins helper Move value_string termination check and OpenBSC/OsmoPCU headers checkout into shared jenkins helper from BTS' model-specific helpers to get rid of copy-pasted code. Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 --- M contrib/jenkins_bts_model.sh M contrib/jenkins_bts_trx.sh M contrib/jenkins_oct.sh M contrib/jenkins_oct_and_bts_trx.sh M contrib/jenkins_sysmobts.sh 5 files changed, 17 insertions(+), 40 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/94/2894/1 diff --git a/contrib/jenkins_bts_model.sh b/contrib/jenkins_bts_model.sh index 58eac5b..bcb2d06 100755 --- a/contrib/jenkins_bts_model.sh +++ b/contrib/jenkins_bts_model.sh @@ -1,5 +1,7 @@ #!/bin/sh bts_model="$1" +base="$PWD" +deps="$base/deps" if [ ! -d "./contrib" ]; then echo "Run ./contrib/jenkins_bts_model.sh from the root of the osmo-bts tree" @@ -8,6 +10,21 @@ set -x -e +cd "$deps" + +# Get OsmoPCU for pcuif_proto.h +osmo-deps.sh osmo-pcu + +# Get OpenBSC for gsm_data_shared.* +osmo-deps.sh openbsc + +# Get libosmocore for verify_value_string_arrays_are_terminated.py +osmo-deps.sh libosmocore + +cd "$base" + +"$deps"/libosmocore/contrib/verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]") + case "$bts_model" in sysmo) diff --git a/contrib/jenkins_bts_trx.sh b/contrib/jenkins_bts_trx.sh index dbd41ca..512a29b 100755 --- a/contrib/jenkins_bts_trx.sh +++ b/contrib/jenkins_bts_trx.sh @@ -15,19 +15,7 @@ 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..df26b14 100755 --- a/contrib/jenkins_oct.sh +++ b/contrib/jenkins_oct.sh @@ -10,16 +10,7 @@ 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" - 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..f546530 100755 --- a/contrib/jenkins_oct_and_bts_trx.sh +++ b/contrib/jenkins_oct_and_bts_trx.sh @@ -15,17 +15,7 @@ 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..0f51aff 100755 --- a/contrib/jenkins_sysmobts.sh +++ b/contrib/jenkins_sysmobts.sh @@ -10,16 +10,7 @@ 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" - 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: newchange Gerrit-Change-Id: Ic48b1f75179b9008d65219dd5a47c1ab3b886408 Gerrit-PatchSet: 1 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: Max