Source: util-linux
Version: 2.35.1-1
Severity: serious
Justification: FTBFS
Tags: patch

Dear Maintainer,

Thanks for packaging the new version of util-linux.

Unfortunately the testsuite fails when building in a pbuilder/cowbuilder
chroot. In particular misc/fallocate and misc/mountpoint.

The issues appear to be:

 misc/fallocate: the expected failure case has not been migrated to the new test
                 framework with clear separation of stdout and stderr.

 misc/mountpoint: This assumes / is a mountpoint which is not the case in a
                  chroot.

Patches addressing both of these failures are below. However, I am aware that
using /proc as the test mountpoint is a linux only solution, so you may well
prefer another approach.

Thanks.

Mark
--- a/tests/ts/misc/fallocate
+++ b/tests/ts/misc/fallocate
@@ -30,7 +30,7 @@
        # fs type of $TS_OUTDIR, could be used to skip this test early
        fs_type=$(${TS_CMD_FINDMNT} -n -o FSTYPE -T ${TS_OUTDIR})
 
-       grep -qi "fallocate: fallocate failed:.*not supported" $TS_OUTPUT \
+       grep -qi "fallocate: fallocate failed:.*not supported" $TS_ERRLOG \
                && ts_skip "'${fs_type}' not supported"
 fi
 
--- a/tests/ts/misc/mountpoint
+++ b/tests/ts/misc/mountpoint
@@ -8,15 +8,16 @@
 
 ts_check_test_command "$TS_CMD_MOUNTPOINT"
 
-ln -s / ./symlink-to-root
+# Use /proc: / is not a mountpoint in a build chroot.
+ln -s /proc ./symlink-to-proc
 
 ts_init_subtest "default"
-$TS_CMD_MOUNTPOINT ./symlink-to-root >> $TS_OUTPUT 2>> $TS_ERRLOG
+$TS_CMD_MOUNTPOINT ./symlink-to-proc >> $TS_OUTPUT 2>> $TS_ERRLOG
 echo $? >> $TS_OUTPUT 2>> $TS_ERRLOG
 ts_finalize_subtest
 
 ts_init_subtest "nofollow"
-$TS_CMD_MOUNTPOINT --nofollow ./symlink-to-root >> $TS_OUTPUT 2>> $TS_ERRLOG
+$TS_CMD_MOUNTPOINT --nofollow ./symlink-to-proc >> $TS_OUTPUT 2>> $TS_ERRLOG
 echo $? >> $TS_OUTPUT 2>> $TS_ERRLOG
 ts_finalize_subtest
 
@@ -25,5 +26,5 @@
 echo $? >> $TS_OUTPUT 2>> $TS_ERRLOG
 ts_finalize_subtest
 
-rm -f ./symlink-to-root
+rm -f ./symlink-to-proc
 ts_finalize
--- a/tests/expected/misc/mountpoint-default
+++ b/tests/expected/misc/mountpoint-default
@@ -1,2 +1,2 @@
-./symlink-to-root is a mountpoint
+./symlink-to-proc is a mountpoint
 0
--- a/tests/expected/misc/mountpoint-nofollow
+++ b/tests/expected/misc/mountpoint-nofollow
@@ -1,2 +1,2 @@
-./symlink-to-root is not a mountpoint
+./symlink-to-proc is not a mountpoint
 1

Reply via email to