Package: fakeroot
Version: 1.23-1
Severity: normal


we noticed a problem when building rakudo (seed #935290), which turns
out to be a combination of a newer version of libuv, which replaces many
stat() calls with statx() ones, and building under fakeroot. fakeroot
does wrap the stat() calls, so that files of unknown users are treated
as root:root, amongth them /build where the package is being put for
building by pbuilder etc. the rakudo build, a handful of turtles down,
tries to determine whether a directory is writable, which it does
through perl6 and therefore libuv1. Since this is now using statx(), and
since statx() is not wrapped by fakeroot, this returns the actual owner
of these files outside the chroot (uid 1234 in my case), so that check

It would be great if fakeroot would also wrap statx() to support these
cases. I guess it is only a matter of time until some other tool starts
using statx() instead of stat(), sio this would not only benfit our own

The bug report report mentioned above has a small statx() wrapper
program (compile with g++ even though it looks like C, it was late),
which shows the problem easily when run under fakeroot:

    mkdir foodir
    sudo chown 1234:1234 foodir
    fakeroot work/statx/st foodir
    > statx test against foodir...
    > returned 0
    > uid is 1234      <- uid as reported by statx()
    > stat returned 0
    > stat uid is 0    <- uid as reported by stat()

thanks  robert

-- System Information:
Debian Release: 10.0
  APT prefers testing
  APT policy: (500, 'testing'), (500, 'oldstable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.19.0-5-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_GB:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages fakeroot depends on:
ii  libc6        2.28-10
ii  libfakeroot  1.23-1

fakeroot recommends no packages.

fakeroot suggests no packages.

-- no debconf information

Reply via email to