From ca04eb8071c2bbeb9eb45f4d56c4b9f230a7f719a869b8eeaa6961ee0c95c1f8 Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Mon, 28 Feb 2011 14:13:34 +0000 Subject: [PATCH] Accepting request 63010 from home:a_jaeger:branches:build-compare-test Ok OBS-URL: https://build.opensuse.org/request/show/63010 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Tools/build-compare?expand=0&rev=91 --- build-compare.changes | 11 +++++++++++ build-compare.spec | 4 ++-- functions.sh | 7 ++++++- srpm-check.sh | 1 + 4 files changed, 20 insertions(+), 3 deletions(-) diff --git a/build-compare.changes b/build-compare.changes index 6c9b86c..60a0b5d 100644 --- a/build-compare.changes +++ b/build-compare.changes @@ -1,3 +1,14 @@ +------------------------------------------------------------------- +Mon Feb 28 14:00:35 UTC 2011 - aj@suse.de + +- Increase version. + +------------------------------------------------------------------- +Mon Feb 28 13:51:29 UTC 2011 - mls@suse.de + +- Check also the first part of the release to e.g. handle rebuild of complete + distribution (bnc#674991). + ------------------------------------------------------------------- Thu Oct 28 09:49:14 UTC 2010 - aj@suse.de diff --git a/build-compare.spec b/build-compare.spec index d299061..419b4d4 100644 --- a/build-compare.spec +++ b/build-compare.spec @@ -23,8 +23,8 @@ License: GPLv2+ Group: Development/Tools/Building AutoReqProv: on Summary: Build Result Compare Script -Version: 2009.10.14 -Release: 25 +Version: 2011.02.28 +Release: 26 Source1: COPYING Source2: same-build-result.sh Source3: rpm-check.sh diff --git a/functions.sh b/functions.sh index 6d3d825..c3779a6 100644 --- a/functions.sh +++ b/functions.sh @@ -1,6 +1,6 @@ #! /bin/bash # -# Copyright (c) 2009, 2010 SUSE Linux Product GmbH, Germany. +# Copyright (c) 2009, 2010, 2011 SUSE Linux Product GmbH, Germany. # Licensed under GPL v2, see COPYING file for details. # # Written by Michael Matz and Stephan Coolo @@ -89,6 +89,11 @@ function cmp_spec () release1=`$RPM --qf "%{RELEASE}" "$oldrpm"` release2=`$RPM --qf "%{RELEASE}" "$newrpm"` + # This might happen with a forced rebuild of factory + if [ "${release1%.*}" != "${release2%.*}" ] ; then + echo "release prefix mismatch" + return 1 + fi check_provides $oldrpm $release1 > $file1 check_provides $newrpm $release2 > $file2 diff --git a/srpm-check.sh b/srpm-check.sh index 626d8f4..96abf94 100644 --- a/srpm-check.sh +++ b/srpm-check.sh @@ -39,6 +39,7 @@ case $RES in exit 0 ;; 1) + echo "RPM meta information is different" exit 1 ;; 2)