Bug#782150: pbuilder: pdebuild fails with --changes-option=-[AaBbFg] or just -g

Mattia Rizzolo mattia at debian.org
Mon Dec 21 02:44:48 UTC 2015


control: tag -1 patch

Hi Ondřej!

Sorry for the late reply...

On Wed, Apr 08, 2015 at 04:15:23PM +0200, Ondřej Surý wrote:
> pdebuild doesn't work with -g or with any binary option given in

the -g bit was fixed some releases ago as part of another bug.

> --changes-option, simple workaround fixes that:

--changes-option is something totally new for me, instead.  I usually
pass only -g/-b/.... without expliciting those are flags for
dpkg-genchanges, since dpkg-buildpackage seems to be is clever enough.

> echo "dpkg-buildpackage -S -us -uc -r${BUILDSOURCEROOTCMD} $DEBBUILDOPTS" | \
>     perl -pe 's/(^|\s|=)-[AbBFg](\s|$|'\'')/$1-S$2/g' | \
>     /bin/bash
> 
> Add = as a start delimiter and ' as end delimiter and -g to the list
> of stripped options.  It's probably not a complete solution, but it
> helps right now to build with --changes-option=-g that I use almost

that regex is tricky (see #802800), can you please check whether the
attached patch (which just adds '|=' in the the (^|\s)) works fine for
you?
it looks quite harmless, but you never know...

-- 
regards,
                        Mattia Rizzolo

GPG Key: 66AE 2B4A FCCF 3F52 DA18  4D18 4B04 3FCD B944 4540      .''`.
more about me:  http://mapreri.org                              : :'  :
Launchpad user: https://launchpad.net/~mapreri                  `. `'`
Debian QA page: https://qa.debian.org/developer.php?login=mattia  `-
-------------- next part --------------
diff --git a/pdebuild b/pdebuild
index fa76a9d..15522aa 100644
--- a/pdebuild
+++ b/pdebuild
@@ -80,7 +80,7 @@ else
 	log.w "Unmet build-dependency in source"
     fi
     echo "dpkg-buildpackage -S -d -us -uc -r${BUILDSOURCEROOTCMD} $DEBBUILDOPTS" | \
-	perl -pe 's/(^|\s)['\'']?-[AbBFgG]['\'']?(\s|$)/$1$2/g' | \
+	perl -pe 's/(^|\s|=)['\'']?-[AbBFgG]['\'']?(\s|$)/$1$2/g' | \
 	/bin/bash
     ${PBUILDERROOTCMD} \
 	${PDEBUILD_PBUILDER} \
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pbuilder-maint/attachments/20151221/2373e161/attachment.sig>


More information about the Pbuilder-maint mailing list