Hi! On Sat, 2018-11-24 at 10:24:09 +0100, Johannes 'josch' Schauer wrote: > Package: dpkg > Version: 1.19.2 > Severity: wishlist
> lintian recently tagged mmdebstrap with uses-dpkg-database-directly > because mmdebstrap contains the string "/var/lib/dpkg" in several > places. Instead of overwriting the lintian tag in mmdebstrap, dpkg could > also gain an interface which avoids mmdebstrap having to do anything > with /var/lib/dpkg inside the chroot. Specifically, what mmdebstrap does > is the following: > > - create /var/lib/dpkg, /var/lib/dpkg/triggers, /var/lib/dpkg/info, > /var/lib/dpkg/alternatives and /var/lib/dpkg/updates because dpkg > throws an error if these directories are not present Right, will handle those. > - an empty /var/lib/dpkg/status because dpkg refuses to work without > the file being present I've fixed this one now in a local next/bootstrap branch which I'll push out tomorrow- > - adds architectures to /var/lib/dpkg/arch because $(dpkg > --add-architecture) doesn't work without any packages inside the > chroot This sould already work when passing --root= or --admindir=, it should even work w/o being root. :) > - cleans up leftover /var/lib/dpkg/lock-frontend and /var/lib/dpkg/lock As mentioned on IRC, this should not be necessary, these are range-locks, and they work not based on their presence, but whether they process has acquired locks within them. Thanks, Guillem