[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Question related to Sbuild CLEAN_SOURCE



Hi,

please keep me in CC as I'm not subscribed to debian-user@l.d.o.

Quoting quirin.gylstorff@siemens.com (2022-02-08 15:40:40)
> we are currently testing the integration of sbuild in ISAR[1] and have a
> question related to the CLEAN_SOURCE behavior.
> 
> 
> "When running sbuild from within an unpacked source tree, run the 
> 'clean' target before generating the source package. This might require 
> some of the build dependencies necessary for running the 'clean' target 
> to be installed on the host machine. Only disable if you start from a 
> clean checkout and you know what you are doing."[2]
> 
> 
> As noted in [2] we observe that we need dh-<helper name> in the host 
> environment to execute the dh clean -with <helper name>.
> 
> Our questions are:
> 
> - Is there are reason sbuild executes clean outside of the chroot?

Yes because if you don't know what you are doing (as it says in the manpage you
cite) and you run sbuild from within an unpacked dirty source tree without
running the clean target, then you might be building something that is not the
source package you expect to be built.

> - How does the buildd infrastructure deal with this behavior?

The buildd infrastructure doesn't run sbuild from within an unpacked source
tree so it will not run the clean target outside the chroot and thus doesn't
need to have the necessary dependencies for running the clean target installed.

The fact that sbuild is able to run from inside an unpacked source tree is a
convenience feature which allows you to run sbuild without having to first
create the source package. But the actual input to sbuild is the source package
(the dsc). Don't use sbuild to create a source package. The source package is
the input to sbuild. The output of sbuild are binary packages, not source
packages.

Thanks!

cheers, josch

Attachment: signature.asc
Description: signature


Reply to: