From 8cf7c6005377153930a8f0c2f87b62493d4a24a0 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Mon, 12 Nov 2012 22:14:01 +0100 Subject: check if we need to do anything --- bin/d-i_build.sh | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'bin/d-i_build.sh') diff --git a/bin/d-i_build.sh b/bin/d-i_build.sh index 759fee19..3f1ef94b 100755 --- a/bin/d-i_build.sh +++ b/bin/d-i_build.sh @@ -27,6 +27,17 @@ init_workspace() { } pdebuild_package() { + # + # check if we need to do anything + # + ARCH=$(dpkg --print-architecture) + EGREP_PATTERN="'( all| any| $ARCH)'" + if [ ! $(grep Architecture: debian/control | egrep -q $EGREP_PATTERN) ] ; then + echo "This package is not to be supposed to be build on $ARCH." + grep Architecture: debian/control + return + fi + # # prepare build # @@ -39,14 +50,7 @@ pdebuild_package() { # # build # - ARCH=$(dpkg --print-architecture) - EGREP_PATTERN="'( all| any| $ARCH)'" - if [ $(grep Architecture: debian/control | egrep -q $EGREP_PATTERN) ] ; then - pdebuild - else - echo "This package is not to be supposed to be build on $ARCH." - grep Architecture: debian/control - fi + pdebuild } init_workspace -- cgit v1.2.3-70-g09d2