From b6e1a2cb3b07a263e2cf270f35893f46cb5c0e2b Mon Sep 17 00:00:00 2001 From: Yonghee Han Date: Mon, 3 Apr 2017 13:50:12 +0900 Subject: [PATCH] Feature : create new 'rpmbuildstage:' option on OBS. Use : add 'rpmbuildstage: bb' option at the OBS Project config. Modify : build -> send BUILD_RPM_BUILD_STAGE option to VM build.data build.pm -> precheck the rpmbuildstage: option. Related package: bs_worker of the obs-server package. Change-Id: I0c7199f0f9eeda835755e854e764eb871d558b6e --- build-vm | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/build-vm b/build-vm index f9a5ffc..e88721c 100644 --- a/build-vm +++ b/build-vm @@ -686,9 +686,13 @@ vm_first_stage() { echo "BUILDENGINE='$BUILDENGINE'" >> $BUILD_ROOT/.build/build.data echo "CCACHE='$CCACHE'" >> $BUILD_ROOT/.build/build.data echo "ABUILD_TARGET='$ABUILD_TARGET'" >> $BUILD_ROOT/.build/build.data - # use the rpmbuild --stage option 689 - if [ ! -z $BUILD_RPM_BUILD_STAGE ]; then 690 - echo "BUILD_RPM_BUILD_STAGE='-$BUILD_RPM_BUILD_STAGE'" >> $BUILD_ROOT/.build/build.data 691 + # use the rpmbuild --stage option + if [ ! -z $BUILD_RPM_BUILD_STAGE ]; then + if [[ "$BUILD_RPM_BUILD_STAGE" =~ ^- ]]; then + echo "BUILD_RPM_BUILD_STAGE='$BUILD_RPM_BUILD_STAGE'" >> $BUILD_ROOT/.build/build.data + else + echo "BUILD_RPM_BUILD_STAGE='-$BUILD_RPM_BUILD_STAGE'" >> $BUILD_ROOT/.build/build.data + fi fi # fallback time for broken hosts date '+@%s' > $BUILD_ROOT/.build/.date -- 2.7.4