From ebc282ef4dfa408accac685565b8ee5f6faec119 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sun, 12 Feb 2023 09:56:54 +0000 Subject: gentoo auto-resync : 12:02:2023 - 09:56:54 --- app-misc/scrub/Manifest | 3 +- .../scrub/files/scrub-2.6.1-tests-block-size.patch | 294 +++++++++++++++++++++ app-misc/scrub/scrub-2.6.1-r1.ebuild | 3 +- 3 files changed, 298 insertions(+), 2 deletions(-) create mode 100644 app-misc/scrub/files/scrub-2.6.1-tests-block-size.patch (limited to 'app-misc/scrub') diff --git a/app-misc/scrub/Manifest b/app-misc/scrub/Manifest index 104395120cb9..e897398972e0 100644 --- a/app-misc/scrub/Manifest +++ b/app-misc/scrub/Manifest @@ -1,5 +1,6 @@ AUX scrub-2.6.1-bashism-tests.patch 2064 BLAKE2B da474dc7501fb9b7c1b93a69b938b9d4b09643e2149a355696828c84a62c364ff8fff75a18d28a8ad110bbaa12beb780a62722550d33ead7359b36230bff7370 SHA512 b5fdcf71f862c633f86fdc5f96c68c2d88f256f3a685f655919e4524705bc74ed9e96dcfdd672741fcc9252cfcc55e4fb3afaad5c246b763ff3f8ff9ba92c442 AUX scrub-2.6.1-implicit-function-declaration-test.patch 594 BLAKE2B 824a8a3d1801a22c090fea14c917e4f9eb5a662d51981d26317ca57cb90003cbc51768bdfb628483e906150d385e66ec7ee7a505c78bf11edf5771a9595fbe90 SHA512 efc0874b03c52591e24035d914093d12f8894272cb9a0bc7e212385f44a8a624f50f933db0412d64595613cfb43fbff37540cc8327ca15471aad57d264b75451 +AUX scrub-2.6.1-tests-block-size.patch 10495 BLAKE2B 4ff772fc9e71a43cce60c135e42401d23b02a41220954bfd314424db8fc6159dc8fd71d1943b9b127cd34cc54cbba963f491f335f92eed3e03b494c5262f42aa SHA512 f1bbdf6fb24782d4f24025edce20617449f6ddbc844b3291013c4d683394ff8ff4421d4c957ec04cd16e71489c79d8e8bb23b8d2c4fcfb721a53c716b00016d2 DIST scrub-2.6.1.tar.gz 362536 BLAKE2B 5342f0b6ffc361e7f581f80f5fd721cd7ed0ccab4591a0c1442476847a51182d869794e5543b06af9f834ebf87ab963c7ce771a6aceef6983c91e814ab86b4fd SHA512 6e434b9d81c5ac473188c37af790c808771204203b3f04a5ca316c6a890f872d1beb73ce4713546e14ae91287d7adaf2fbfa44a30af634c2b3af890e2a0e8640 -EBUILD scrub-2.6.1-r1.ebuild 486 BLAKE2B 1d729291939d4223bc4f7fc7e671c373661f37545b5ad51c34b47dc46f045ebac57e495ff5ec3ec0a18046842fba65383bf88dad261dfbf97d06927cdb434ac9 SHA512 df96e624b86335306d321ce2ec3404e31dabab592d703e82b7a0144dd69bf4a90236e7da0130833bde8efc02ac1a836ca56efe555635e1dcec560951ed7da13d +EBUILD scrub-2.6.1-r1.ebuild 536 BLAKE2B 432e75cd31118bdc43c24c71fb8a2505d53404ed856ef9181d69b992edb97db0f4af707771f381aecaee537c21f0ee5888a8e03d8522d0b590f848c1c233d018 SHA512 844154d6eecd237c3610d61c19d0d0b157dfd96281c2bab0b9da501456f8bd780e1b10c0c1d82bd4b88cb891ce8889ab1c4383a203d8c3884d0a6e30d2066548 MISC metadata.xml 428 BLAKE2B 3b0dafd4c5c4c5f8b1f630ae20e6a33f1858e1465e20c920487fb1ade63de415787ac2e405cc1652c21508bb012a0333e810cb58d7610f02a684fcf1794e9915 SHA512 5868d55250b339a6cf8835f95efc6dbbcad2ee323415a910d78f261964ab3968708841f5ee9a649493c7e8446560037d0516e0c109a86b89ad943c404eaf3b62 diff --git a/app-misc/scrub/files/scrub-2.6.1-tests-block-size.patch b/app-misc/scrub/files/scrub-2.6.1-tests-block-size.patch new file mode 100644 index 000000000000..d2c1c9612e67 --- /dev/null +++ b/app-misc/scrub/files/scrub-2.6.1-tests-block-size.patch @@ -0,0 +1,294 @@ +Fixes test failures on ZFS. + +https://github.com/chaos/scrub/commit/5c66fc0537f4ecb21d4c3dcdd9020a02c8a2d819 + +From 5c66fc0537f4ecb21d4c3dcdd9020a02c8a2d819 Mon Sep 17 00:00:00 2001 +From: Jim Garlick +Date: Mon, 9 Mar 2015 16:20:38 -0700 +Subject: [PATCH] test: use a power of 2 for file sizes + +Reduce the change of tests failing due to block size round-up. +Freebsd was failing that way. +--- a/test/t02 ++++ b/test/t02 +@@ -1,6 +1,6 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r $TESTFILE 2>&1 | sed -e "s!${TESTFILE}!file!" >t02.out || exit 1 + diff t02.exp t02.out >t02.diff +--- a/test/t02.exp ++++ b/test/t02.exp +@@ -1,5 +1,5 @@ + scrub: using NNSA NAP-14.1-C patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| +--- a/test/t03 ++++ b/test/t03 +@@ -1,6 +1,6 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r -p dod $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t03.out || exit 1 + diff t03.exp t03.out >t03.diff +--- a/test/t03.exp ++++ b/test/t03.exp +@@ -1,5 +1,5 @@ + scrub: using DoD 5220.22-M patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: 0xff |................................................| +--- a/test/t04 ++++ b/test/t04 +@@ -1,6 +1,6 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r -p bsi $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t04.out || exit 1 + diff t04.exp t04.out >t04.diff +--- a/test/t04.exp ++++ b/test/t04.exp +@@ -1,5 +1,5 @@ + scrub: using BSI patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: 0xff |................................................| + scrub: 0xfe |................................................| + scrub: 0xfd |................................................| +--- a/test/t05 ++++ b/test/t05 +@@ -1,6 +1,6 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r -p fastold $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t05.out || exit 1 + diff t05.exp t05.out >t05.diff +--- a/test/t05.exp ++++ b/test/t05.exp +@@ -1,5 +1,5 @@ + scrub: using pre v1.7 scrub (skip random) patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: 0x00 |................................................| + scrub: 0xff |................................................| + scrub: 0xaa |................................................| +--- a/test/t06 ++++ b/test/t06 +@@ -1,7 +1,7 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r -p old $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t06.out || exit 1 + diff t06.exp t06.out >t06.diff + rc=$? +--- a/test/t06.exp ++++ b/test/t06.exp +@@ -1,5 +1,5 @@ + scrub: using pre v1.7 scrub patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: 0x00 |................................................| + scrub: 0xff |................................................| + scrub: 0xaa |................................................| +--- a/test/t07 ++++ b/test/t07 +@@ -1,7 +1,7 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE ++./pad 512k $TESTFILE + (./tsig $TESTFILE && ./tsig $TESTFILE) >t07.out 2>&1 + diff t07.exp t07.out >t07.diff + rc=$? +--- a/test/t11 ++++ b/test/t11 +@@ -1,7 +1,7 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + $PATH_SCRUB -r -p gutmann $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t11.out || exit 1 + diff t11.exp t11.out >t11.diff + rc=$? +--- a/test/t11.exp ++++ b/test/t11.exp +@@ -1,5 +1,5 @@ + scrub: using Gutmann patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: random |................................................| +--- a/test/t12 ++++ b/test/t12 +@@ -1,14 +1,14 @@ + #!/bin/sh + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 +-$PATH_SCRUB -s 400k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t12.out ++./pad 512k $TESTFILE || exit 1 ++$PATH_SCRUB -s 512k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >t12.out + test $? = 0 || exit 1 + ./tsize $TESTFILE >>t12.out 2>&1 +-$PATH_SCRUB -f -s 300k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >>t12.out ++$PATH_SCRUB -f -s 256k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >>t12.out + test $? = 0 || exit 1 + ./tsize $TESTFILE >>t12.out 2>&1 +-$PATH_SCRUB -f -s 500k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >>t12.out ++$PATH_SCRUB -f -s 1024k $TESTFILE 2>&1 | sed -e "s!$TESTFILE!file!" >>t12.out + test $? = 0 || exit 1 + ./tsize $TESTFILE >>t12.out 2>&1 + diff t12.exp t12.out >t12.diff +--- a/test/t12.exp ++++ b/test/t12.exp +@@ -1,22 +1,22 @@ + scrub: using NNSA NAP-14.1-C patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: verify |................................................| +-409600 ++524288 + scrub: warning: -s size < file size + scrub: using NNSA NAP-14.1-C patterns +-scrub: scrubbing file 307200 bytes (~300KB) ++scrub: scrubbing file 262144 bytes (~256KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: verify |................................................| +-409600 ++524288 + scrub: using NNSA NAP-14.1-C patterns +-scrub: scrubbing file 512000 bytes (~500KB) ++scrub: scrubbing file 1048576 bytes (~1024KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: verify |................................................| +-512000 ++1048576 +--- a/test/t15 ++++ b/test/t15 +@@ -2,7 +2,7 @@ + TEST=`basename $0 | cut -d- -f1` + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + + $PATH_SCRUB -p custom="0123456789abcdef" $TESTFILE 2>&1 \ + | sed -e "s!${TESTFILE}!file!" 2>&1 >$TEST.out|| exit 1 +--- a/test/t15.exp ++++ b/test/t15.exp +@@ -1,7 +1,7 @@ + scrub: using Custom single-pass patterns +-scrub: scrubbing file 409600 bytes (~400KB) ++scrub: scrubbing file 524288 bytes (~512KB) + scrub: 0x30313233343536373839616263646566|......................| + 0000000 001 002 003 S C R U B B E D ! \0 d e f + 0000020 0 1 2 3 4 5 6 7 8 9 a b c d e f + * +-1440000 ++2000000 +--- a/test/t16 ++++ b/test/t16 +@@ -2,7 +2,7 @@ + TEST=`basename $0 | cut -d- -f1` + TESTFILE=${TMPDIR:-/tmp}/scrub-testfile.$$ + rm -f $TESTFILE +-./pad 400k $TESTFILE || exit 1 ++./pad 512k $TESTFILE || exit 1 + + od -c $TESTFILE >$TEST.out || exit 1 + +--- a/test/t16.exp ++++ b/test/t16.exp +@@ -1,10 +1,10 @@ + 0000000 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 + * +-1437760 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 x +-1440000 ++1777760 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 x ++2000000 + scrub: using Quick Fill with 0xff patterns + scrub: (dryrun) scrub reg file file + 0000000 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 + * +-1437760 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 x +-1440000 ++1777760 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 \0 x ++2000000 +--- a/test/t17 ++++ b/test/t17 +@@ -3,9 +3,9 @@ TEST=`basename $0 | cut -d- -f1` + TMPLATE="${TMPDIR:-/tmp}/tmp.XXXXXXXXXX" + TESTDIR=`mktemp -d $TMPLATE` || exit 1 + +-./pad 400k $TESTDIR/a || exit 1 +-./pad 400k $TESTDIR/b || exit 1 +-./pad 400k $TESTDIR/c || exit 1 ++./pad 512k $TESTDIR/a || exit 1 ++./pad 512k $TESTDIR/b || exit 1 ++./pad 512k $TESTDIR/c || exit 1 + + echo Created 3 files >$TEST.out + +--- a/test/t17.exp ++++ b/test/t17.exp +@@ -1,16 +1,16 @@ + Created 3 files + scrub: using NNSA NAP-14.1-C patterns +-scrub: scrubbing file/a 409600 bytes (~400KB) ++scrub: scrubbing file/a 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: verify |................................................| +-scrub: scrubbing file/b 409600 bytes (~400KB) ++scrub: scrubbing file/b 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| + scrub: verify |................................................| +-scrub: scrubbing file/c 409600 bytes (~400KB) ++scrub: scrubbing file/c 524288 bytes (~512KB) + scrub: random |................................................| + scrub: random |................................................| + scrub: 0x00 |................................................| +--- a/test/t22 ++++ b/test/t22 +@@ -3,9 +3,9 @@ TEST=`basename $0 | cut -d- -f1` + TMPLATE="${TMPDIR:-/tmp}/tmp.XXXXXXXXXX" + TESTDIR=`mktemp -d $TMPLATE` || exit 1 + +-./pad 400k $TESTDIR/a || exit 1 +-./pad 400k $TESTDIR/b || exit 1 +-./pad 400k $TESTDIR/c || exit 1 ++./pad 512k $TESTDIR/a || exit 1 ++./pad 512k $TESTDIR/b || exit 1 ++./pad 512k $TESTDIR/c || exit 1 + + echo Created 3 files >$TEST.out + + diff --git a/app-misc/scrub/scrub-2.6.1-r1.ebuild b/app-misc/scrub/scrub-2.6.1-r1.ebuild index 15bebc1034e5..a0bf914b7cb1 100644 --- a/app-misc/scrub/scrub-2.6.1-r1.ebuild +++ b/app-misc/scrub/scrub-2.6.1-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2022 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=8 @@ -14,4 +14,5 @@ KEYWORDS="amd64 ~arm arm64 ~ppc64 ~riscv ~sparc x86" PATCHES=( "${FILESDIR}"/${P}-implicit-function-declaration-test.patch "${FILESDIR}"/${PN}-2.6.1-bashism-tests.patch + "${FILESDIR}"/${PN}-2.6.1-tests-block-size.patch ) -- cgit v1.2.3