Hi, Do you have handy testcases I could try?
At Wed, 8 Jul 2009 15:35:01 -0400, Andres Mejia wrote: > > diff --git a/pbuilder-buildpackage b/pbuilder-buildpackage > index 0fbaf2e..cde3551 100755 > --- a/pbuilder-buildpackage > +++ b/pbuilder-buildpackage > @@ -31,6 +31,9 @@ if [ ! -f "$PACKAGENAME" ]; then > exit 1; > fi; > > +# check if this package should be built at all > +checkarchitecture "$PACKAGENAME" > + > if [ -n "$BUILDUSERNAME" -a -n "$BUILDUSERID" ]; then > SUTOUSER="env LOGNAME=$BUILDUSERNAME su -p $BUILDUSERNAME" > DEBBUILDOPTS="$DEBBUILDOPTS -rfakeroot" > diff --git a/pbuilder-buildpackage-funcs b/pbuilder-buildpackage-funcs > index 370c799..d573dbf 100644 > --- a/pbuilder-buildpackage-funcs > +++ b/pbuilder-buildpackage-funcs > @@ -30,6 +30,25 @@ function copydsc () { > done > } > > +function checkarchitecture () { > + local DSCFILE="$1" > + local ARCHES="$(cat $DSCFILE | grep Architecture | sed > 's/^[^:]\+:\s*//')" > + local ARCH=$(dpkg-architecture -qDEB_HOST_ARCH) > + local VALID_ARCH > + for d in $ARCHES; do > + if dpkg-architecture -a$ARCH -i$d; then > + VALID_ARCH="yes" > + break > + fi > + done > + if [ ! $VALID_ARCH ] && [ ! "$ARCHES" = "all" ]; then > + local msg="E: $ARCH not in arch list or does not match any " > + msg="$msg arch wildcards: $ARCHES" > + log $msg > + exit 2 > + fi > +} > + > function checkbuilddep () { > # call satisfydepends > local BUILDOPT="--binary-all" -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org