From: Dan Mick Date: Tue, 12 Apr 2016 21:28:10 +0000 (-0700) Subject: ceph-build/build/build_*: check for librados2 package presence X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=23ed0a2ff40e1775d4c32e5c58c0f99d33098c0e;p=ceph-build.git ceph-build/build/build_*: check for librados2 package presence Assertion: if librados2 .deb of the right version etc. is present, the build doesn't need to continue, because either the entire build succeeded and published already, or none of it did. Signed-off-by: Dan Mick --- diff --git a/ceph-build/build/build_deb b/ceph-build/build/build_deb index 12c6c75c..49a7f0a4 100644 --- a/ceph-build/build/build_deb +++ b/ceph-build/build/build_deb @@ -37,7 +37,7 @@ BPTAG=`get_bptag $DIST` vers=`cat ./dist/version` distro=`python -c "exec 'import platform; print platform.linux_distribution()[0].lower()'"` debian_version=${vers}-1 -chacra_endpoint="ceph/${chacra_ref}/${distro}/${DIST}/${ARCH}" + gen_debian_version() { raw=$1 dist=$2 @@ -57,6 +57,9 @@ gen_debian_version() { bpvers=`gen_debian_version $debian_version $DIST` +# look for a specific package to tell if we can avoid the build +chacra_endpoint="ceph/${chacra_ref}/${distro}/${DIST}/${ARCH}/librados2_${vers}-${bpvers}_${ARCH}.deb" + if [ "$THROWAWAY" = false ] ; then # this exists in scripts/build_utils.sh check_binary_existence $chacra_endpoint diff --git a/ceph-build/build/build_rpm b/ceph-build/build/build_rpm index 57ce0151..9192e6a2 100644 --- a/ceph-build/build/build_rpm +++ b/ceph-build/build/build_rpm @@ -61,11 +61,11 @@ vers=`cat ./dist/version` # slap -rc to the ref if we are doing a release-candidate build [ "$RC" = true ] && chacra_ref="$BRANCH-rc" || chacra_ref="$BRANCH" [ "$TEST" = true ] && chacra_ref="test" -chacra_baseurl="ceph/${chacra_ref}/${DISTRO}/${RELEASE}" +chacra_baseurl="ceph/${chacra_ref}/${DISTRO}/${RELEASE}/${ARCH}/librados2-${vers}-0.${DIST}.${ARCH}.rpm" if [ "$THROWAWAY" = false ] ; then # this exists in scripts/build_utils.sh - check_binary_existence $chacra_baseurl/$ARCH + check_binary_existence $chacra_baseurl fi HOST=$(hostname --short)