编译时的报错为:
See ./tests/test-suite.log Please report to bug-coreutils@gnu.org ============================================================================ make[4]: Leaving directory `/builddir/build/BUILD/coreutils-8.22' make[3]: Leaving directory `/builddir/build/BUILD/coreutils-8.22' make[2]: Leaving directory `/builddir/build/BUILD/coreutils-8.22' make[1]: Leaving directory `/builddir/build/BUILD/coreutils-8.22' RPM build errors: make[4]: *** [tests/test-suite.log] Error 1 make[3]: *** [check-TESTS] Error 2 make[2]: *** [check-am] Error 2 make[1]: *** [check-recursive] Error 1 make: *** [check] Error 2 error: Bad exit status from /var/tmp/rpm-tmp.GWApW9 (%check) Bad exit status from /var/tmp/rpm-tmp.GWApW9 (%check) Child return code was: 1 EXCEPTION: Command failed. See logs for output.
问题主要表现在:dd 测试dd if=file.in of=file.out bs=1M conv=sparse没有notrunc不截输出文件上
[root@localhost coreutils]# cat dd-sparse-qfong.patch --- coreutils-8.22/tests/dd/sparse.sh 2014-07-28 14:36:49.919025875 +0800 +++ coreutils-patch-8.22/tests/dd/sparse.sh 2014-07-28 14:37:20.871025455 +0800 @@ -60,9 +60,11 @@ if test $(kb_alloc file.in) -gt 3000; th # Here, with a 2MiB block size, dd's conv=sparse must *not* introduce a hole. dd if=file.in of=file.out bs=2M conv=sparse test 2500 -lt $(kb_alloc file.out) || fail=1 + rm file.out + truncate --size=3M file.out # Ensure that this 1MiB string of NULs *is* converted to a hole. - dd if=file.in of=file.out bs=1M conv=sparse + dd if=file.in of=file.out bs=1M conv=sparse,notrunc test $(kb_alloc file.out) -lt 2500 || fail=1 fi