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

Bug#1021577: libc-bin.postinst: please create /var/cache/ldconfig with DPKG_ROOT



On 2022-10-11 22:06, Johannes Schauer Marin Rodrigues wrote:
> Hi,
> 
> Quoting Aurelien Jarno (2022-10-11 21:55:47)
> > Ok, thanks for the details, I'll look at the patch.
> 
> thank you!
> 
> > Anyway that makes me wonder if we should ship that directory in the libc6

Note that it should be the libc-bin package, not the libc6 one.

> > package, just like apt ships /var/cache/apt and debconf ships
> > /var/cache/debconf.
> 
> In our DPKG_ROOT CI we compare a chroot tarball created the normal way with a
> tarball created with dpkg run with --force-script-chrootless. We added an
> additional mode that tries out if this whole thing also works when run without
> being the root user but run as the normal user under fakeroot and then we found
> the missing /var/cache/ldconfig directory.
> 
> So if libc6 would ship that directory, I think my patch would still be needed.
> Because if `ldconfig -r` doesn't use the directory, then the last modification
> timestamps will differ between a chroot created the normal way and a chroot
> created without actually ever running chroot() (the DPKG_ROOT way).

From what I have understood from your explanation, if the directory
exists chroot_canon() will work, so `ldconfig -r` will be able to create
the aux-cache file in it.

I still think that the bug should be fixed on the glibc upstream side,
but that would allow to easy fix it on the package side, and it's
probably better to have a closer match of the dpkg database and the file
system.

Regards
Aurelien

-- 
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
aurelien@aurel32.net                 http://www.aurel32.net

Attachment: signature.asc
Description: PGP signature


Reply to: