pbuilder forces use of fakeroot

Bug #1206215 reported by Jim Wright
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pbuilder (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

The file /usr/lib/pbuilder/pbuilder-buildpackage parses options and builds the command line for debuild. It includes the line:

    DEBBUILDOPTS="${DEBBUILDOPTS:+$DEBBUILDOPTS }-rfakeroot"

Note that it unequivocally appends "-rfakeroot" to the debuild command line. In turn, debuild parses the command line such that the last instance of the -r option is used. So even if you set DEBBUILDOPTS to have an alternative -r option, it will have no effect.

This can be worked around by making "-rfakeroot" appear at the beginning, so any user-supplied -r option appears last and will take effect. But this depends on behavior coded into debuild. A better solution would be to check of DEBBUILDOPTS contains a -r or --rootcmd option, and only force the inclusion of -rfakeroot if not provided.

Description: Ubuntu 12.04.2 LTS
Release: 12.04

pbuilder:
  Installed: 0.208ubuntu1
  Candidate: 0.208ubuntu1
  Version table:
 *** 0.208ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages
        100 /var/lib/dpkg/status

Mattia Rizzolo (mapreri)
tags: removed: debuild fakeroot pbuilder
Changed in pbuilder (Debian):
status: Unknown → New
Revision history for this message
Mattia Rizzolo (mapreri) wrote :

commit the relevant change to pbuilder's git, just removing the option.

If needed dpkg-buildpackage uses it by default anyway.

no longer affects: pbuilder (Debian)
Changed in pbuilder (Ubuntu):
status: New → Fix Committed
Revision history for this message
Mattia Rizzolo (mapreri) wrote :
Revision history for this message
Mattia Rizzolo (mapreri) wrote : Re: Accepted pbuilder 0.230 (source) into unstable

On Fri, Nov 09, 2018 at 09:27:25PM +0000, Thorsten Glaser wrote:
> Mattia Rizzolo dixit:
> > + Add a --no-source-only-chnages option to override a configured
>
> chnages? I hope it’s not typo’d in the code.

uops, yes!
luckily I typoed only in the commit message (and hence the changelog),
code and manpages are fine.

changelog fixed locally, thank you!

> > + Don't explicitly pass -rfakeroot to dpkg-buildpackage.
> > dpkg-buildpackage uses it by default if present since v1.14.7, so no
> > need to tell it to. LP: #1206215
>
> Please keep passing -rfakeroot for chroots in which etch or older run.
> (Apparently, hardy and lenny have version > 1.14.7 so “should” work.
> If not, you can bet I’m gonna complain :D)

uhhh....
Guess I'll add a check based on the dpkg version, similar to the R-R-R
one.

> Hm, that being said, thanks to #854725 I have to temporarily downgrade
> pbuilder to 0.227 in order to build for these, anyway ☹ (This still
> kinda sucks as I don’t get all the other recent improvements there, like…

Umh, I somehow completely ignored that bug.... sorry!
Guess that one could be also taken care of by a check on dpkg's version,
disabling support for the (willingly undocumented) BUILDSUBDIR option.

--
regards,
                        Mattia Rizzolo

GPG Key: 66AE 2B4A FCCF 3F52 DA18 4D18 4B04 3FCD B944 4540 .''`.
more about me: https://mapreri.org : :' :
Launchpad user: https://launchpad.net/~mapreri `. `'`
Debian QA page: https://qa.debian.org/developer.php?login=mattia `-

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

This bug was fixed in the package pbuilder - 0.230

---------------
pbuilder (0.230) unstable; urgency=medium

  [ Mattia Rizzolo ]
  * d/control:
    + Bump Standards-Version to 4.2.1, no changes needed.
    + Use the new debhelper-compat(=11) notation and drop d/compat.
  * d/rules: Change Ubuntu default DISTRIBUTION to "devel".
  * t: Add regression tests for 54e072c5ebb7d353e674873c96e5d837e52f345c.
  * checkparams:
    + Add a --no-source-only-chnages option to override a configured
      SOURCE_ONLY_CHANGES=yes. Closes: #904716
    + Add more information in the slice name and scope description
      to ease the life of those running many pbuilder instances.
  * buildpackage:
    + Don't explicitly pass -rfakeroot to dpkg-buildpackage.
      dpkg-buildpackage uses it by default if present since v1.14.7, so no
      need to tell it to. LP: #1206215
    + Unless specified, look for .changes file of the architecture of the
      chroot, not of the host's system. LP: #1762890
  * modules:
    + Shut down some extra translators in umountproc. Closes: #912636
      Thanks to Samuel Thibault for the patch.

  [ Thorsten Glaser ]
  * buildpackage:
    + Create consistent /etc/hosts in build chroots with USENETWORK=no.
      Policy 4.2.0 §4.9 explicitly allows loopback access, which is already
      allowed, and we also already clean resolv.con.
      Add a clean hosts file which ships 127.0.0.1 as localhost and ::1 as
      localhost6 to avoid trouble. See also the policy bug #904248.
      Closes: #905307

  [ Daniel Schepler ]
  * Wrap the chroot calls inside a systemd slice when running on Linux systems
    with systemd. Closes: #905550
    This allows proper cleanup of stray processes left behind, among easier
    resource control by the system administrator.

  [ James Clarke ]
  * modules: Mount fdescfs under /dev/fd on kFreeBSD.
  * pbuilderrc.5: Update link to the user manual.
  * t/test_pbuilder-apt-config:
    + Fix Ubuntu-related tests on non-Ubuntu architectures.

 -- Mattia Rizzolo <email address hidden> Fri, 09 Nov 2018 13:51:04 +0100

Changed in pbuilder (Ubuntu):
status: Fix Committed → 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.