Skip Menu |

This queue is for tickets about the Fuse CPAN distribution.

Report information
The Basics
Id: 23734
Status: resolved
Priority: 0/
Queue: Fuse

People
Owner: Nobody in particular
Requestors: ANDREWC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in:
  • 0.07_4
  • 0.08
Fixed in: 0.09_1



Subject: Some mknod-related tests fail in fakeroot build environment
When `make test` is run under a fakeroot[1] environment, as is the case with Debian/Ubuntu's dh-make-perl, the mknod() calls of test/mknod.t will not have any real effect on the mounted loopback filesystem. This is because only an emulated mknod() is called in such an environment. When seen inside the mounted filesystem ($_point), the call appears to have taken effect because fakeroot environments retain memories of what the emulated calls were supposed to have done. However, when viewed from the other side ($_real), no change is apparent: x_mknod() is never called during the test suite execution. Errors appear as in the included file; I'll follow up with a patch. [1] http://packages.debian.org/stable/utils/fakeroot.html
Subject: fakeroot_make_test_output.txt
cp Fuse.pm blib/lib/Fuse.pm AutoSplitting blib/lib/Fuse.pm (blib/lib/auto/Fuse) /usr/bin/perl /usr/share/perl/5.8/ExtUtils/xsubpp -typemap /usr/share/perl/5.8/ExtUtils/typemap Fuse.xs > Fuse.xsc && mv Fuse.xsc Fuse.c cc -c -DFUSE_USE_VERSION=25 -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS -DDEBIAN -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"0.08\" -DXS_VERSION=\"0.08\" -fPIC "-I/usr/lib/perl/5.8/CORE" -Wall -g -ggdb Fuse.c Running Mkbootstrap for Fuse () chmod 644 Fuse.bs rm -f blib/arch/auto/Fuse/Fuse.so cc -shared -L/usr/local/lib -lfuse -lpthread Fuse.o -lpthread -o blib/arch/auto/Fuse/Fuse.so \ \ chmod 755 blib/arch/auto/Fuse/Fuse.so cp Fuse.bs blib/arch/auto/Fuse/Fuse.bs chmod 644 blib/arch/auto/Fuse/Fuse.bs PERL_DL_NONLAZY=1 /usr/bin/perl "-Iblib/lib" "-Iblib/arch" test.pl test/s/mount.....# mounting examples/loopback_t.pl to /tmp/fusemnt-andrewc # Mounted in 0.2 secs ok test/chmod.......ok test/chown.......ok test/getattr.....ok test/getdir......ok test/link........ok test/mkdir.......ok test/mknod....... # Failed test 'chrdev is chrdev' # in test/mknod.t at line 29. # Failed test 'blkdev is blkdev' # in test/mknod.t at line 30. # Failed test 'chrdev has right major,minor' # in test/mknod.t at line 33. # got: '0' # expected: '515' # Failed test 'blkdev has right major,minor' # in test/mknod.t at line 35. # got: '0' # expected: '515' # Looks like you failed 4 tests of 24. dubious Test returned status 4 (wstat 1024, 0x400) DIED. FAILED tests 11-14 Failed 4/24 tests, 83.33% okay test/open........ok test/pod.........ok test/read........ok test/readlink....ok test/rename......ok test/rmdir.......ok test/statfs......# statfs: 1702057286, 4096, 1000000, 500000, 500000, 1000000, 500000, 0, 0, 255, 4096, 0, 0, 0, 0, 0 ok test/symlink.....ok test/truncate....ok test/unlink......ok test/utime.......ok test/write.......ok test/s/umount....ok Failed Test Stat Wstat Total Fail Failed List of Failed ------------------------------------------------------------------------------- test/mknod.t 4 1024 24 4 16.67% 11-14 Failed 1/21 test scripts, 95.24% okay. 4/164 subtests failed, 97.56% okay. make: *** [test_dynamic] Error 255
Patch to workaround this behaviour attached: no need for the --notest flag for dh-make-perl any more :)
diff -rU2 Fuse-0.08.ORIG/test/mknod.t Fuse-0.08/test/mknod.t --- Fuse-0.08.ORIG/test/mknod.t 2006-01-02 19:50:50.000000000 +0000 +++ Fuse-0.08/test/mknod.t 2006-11-30 22:02:51.000000000 +0000 @@ -27,4 +27,8 @@ ok(-e "chr" ,"chrdev exists"); ok(-e "blk" ,"blkdev exists"); + + skip('mknod() is just pretend under fakeroot(1)', 4) + if exists $ENV{FAKEROOTKEY}; + ok(-c "chr" ,"chrdev is chrdev"); ok(-b "blk" ,"blkdev is blkdev");