[mk-sbuild] mk-sbuild creates schroots with install-recommends enabled

Bug #1268684 reported by Steve Beattie
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
ubuntu-dev-tools (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

mk-sbuild by default for ubuntu and debian schroots runs debootstrap with the --no-install-recommends to keep the generated chroots as minimally installed as possible. However, for ubuntu schroots, the resulting chroot is still configured with install-recommends enabled in its apt configuration:

  $ schroot -c trusty-amd64 apt-config dump APT::Install-Recommends
  APT::Install-Recommends "1";

This results in a schroot that differs in build dependency resolution behavior from the buildds, which has install-recommends disabled by default. I noticed this difference when a local sbuild succeeded because a (recently split out) recommended package got pulled into the chroot, but failed when built in a buildd.

As long as the buildds don't use sbuild from the archive, there's always going to be (the possibility of) some differences in dependency resolution; however, it seems wise to try to minimize those differences so as to give developers an environment that matches the buildds as close as possible.

Tags: patch
Revision history for this message
Steve Beattie (sbeattie) wrote :

Here's a patch that addresses the issue for me:

  $ schroot -c test-recommends-trusty-amd64 apt-config dump APT::Install-Recommends
  APT::Install-Recommends "0";

 I didn't expose it as a command line argument, though I could add it if it's desired; mk-sbuild already has a non-trivial amount of possible arguments, so my initial instinct was to resist the urge to add another to the pile.

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "mk-sbuild-disable_recommends_within_schroot.patch" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in ubuntu-dev-tools (Ubuntu):
status: New → Confirmed
Revision history for this message
Jeremy Bícha (jbicha) wrote :

Does this work with Ubuntu 16.10?

Also, for Ubuntu schroots, there's sbuild-launchpad-chroot which I think is supposed to more closely resemble how the Launchpad builders work.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-dev-tools - 0.166

---------------
ubuntu-dev-tools (0.166) unstable; urgency=medium

  * Team upload.

  [ Felipe Reyes ]
  * pbuilder-dist:
    + Fix handling of --othermirror when a local archive found. LP: #1314076

  [ Jelmer Vernooij ]
  * Recommend Bazaar (brz) or Breezy (brz); the latter provides a
    command-line compatible interface.

  [ Mathieu Trudel-Lapierre ]
  * Add a new tool "ubuntu-archive-assistant" tool for
    proposed-migration / mir review. More information on:
    https://lists.ubuntu.com/archives/ubuntu-devel/2018-September/040492.html
    The tool is not currently installed, see the launchpad bug #1799568.

  [ Benjamin Drung ]
  * ubuntutools/test: Introduce get_source_files helper function.
  * Update pylint and flake8 unittests.
  * Fix invalid escape sequences '\(' or '\)'. Closes: #911689

  [ Mattia Rizzolo ]
  * Add missing dependencies on sensible-utils (thanks lintian!).
  * wrap-and-sort -ast.
  * Bump Standards-Version to 4.2.1, no changes needed.
  * Use the new debhelper-compat(=11) notation and drop d/compat.
  * Clarify package descriptions for Python libraries.
    Thanks to Ben Finney for the patch. Closes: #804198, #804199
  * Add a recommends on ubuntu-keyring | ubuntu-archive-keyring.
    Closes: #838254
  * mk-sbuild: disable recommends also within the chroot.
    Thanks to Steve Beattie for the patch. LP: #1268684

 -- Mattia Rizzolo <email address hidden> Tue, 23 Oct 2018 22:08:04 +0200

Changed in ubuntu-dev-tools (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.