• Fridolin Pokorny's avatar
    mountlist: use /proc/self/mountinfo when available · 3ea43e02
    Fridolin Pokorny authored
    Use libmount to propagate device IDs provided by Linux in
    /proc/self/mountinfo.  This will give more accurate output when
    using df in chroot'ed environments as the device IDs are not
    determined by stat() which may be inaccurate within the chroot.
    
    * lib/mountlist.c (read_file_system_list): Use the libmount routines
    from util-linux to parse "/proc/self/mountinfo" or fall back to
    standard getmntent() processing.
    * m4/ls-mntd-fs.m4: Check for libmount only when 1-argument
    getmntent() is used, as is the case on GNU/Linux.
    * DEPENDENCIES: Mention the optional util-linux dependency.
    3ea43e02
DEPENDENCIES 5.32 KB