abuild: use stat instead of df to figure filesystem type

Fixes the error:
  df: .: can't find mount point

When running abuild inside a chroot when the root file system
mountpoint information is not necessarily directly available.
This commit is contained in:
Timo Teräs 2020-02-08 12:48:52 +02:00
parent c9d3df08b3
commit bad781082d

View File

@ -997,7 +997,7 @@ prepare_metafiles() {
local builddate="$SOURCE_DATE_EPOCH"
# Fix package size on several filesystems
case "$(df -PT . | awk 'END {print $2}')" in
case "$(stat -f -c "%T" .)" in
btrfs|ecryptfs|zfs)
sync;;
esac