Bug#755371: devscripts: [PATCH] Better error reporting for mk-build-deps.pl

Dima Kogan dima at secretsauce.net
Sun Jul 20 00:50:54 UTC 2014


Package: devscripts
Version: 2.14.2
Severity: normal

Hi.

'mk-build-deps -i' attempts to install the build-deps package this tool
builds. It does this by running

 dpkg --unpack
 apt-get --no-install-recommends just_built.deb

mk-build-deps then looks at the return code of apt-get to determine if
the command succeeded. This apt-get command is interactive, and will ask
the user to confirm. If the user says no, mk-build-deps knows that
apt-get failed. This is fine.

I want to run this non-interactively, so I invoke mk-build-deps with '-t
"apt-get -y --no-install-recommend". With this command, if it's
impossible to install the new package, apt-get will automatically remove
it, and return a SUCCESSFULL error code, even though the action that
mk-build-deps was asked to perform failed.

I'm attaching a patch that explicitly checks if the packages we were
asked to install actually did get installed. If they were not, it
outputs a very explicit error message.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: mk-build-deps.pl.patch
Type: text/x-diff
Size: 1175 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/devscripts-devel/attachments/20140719/3a4c022f/attachment.patch>


More information about the devscripts-devel mailing list