From: Björn Ketelaars Date: Sat, 30 Jun 2018 11:22:14 +0000 (+0200) Subject: xz/lzma warning causes test to fail X-Git-Tag: v0.0.29~75^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F1222%2Fhead;p=thirdparty%2Fzstd.git xz/lzma warning causes test to fail OpenBSD's port building infrastructure is able to build in a privilege separated mode. It uses a privilege drop model. Regression tests fail in this mode as xz/lzma is unable to set file group and errors out with: xz: tmp.xz: Cannot set the file group: Operation not permitted gmake[1]: *** [Makefile:307: zstd-playTests] Error 2 Actually it is not a xz/lzma error but a warning causing zstd's regression test to fail. Proposed fix is to have xz/lzma not set the exit status to 2 even if a condition worth a warning was detected (-Q flag). --- diff --git a/tests/playTests.sh b/tests/playTests.sh index d167cc289..c4b1489b7 100755 --- a/tests/playTests.sh +++ b/tests/playTests.sh @@ -548,16 +548,16 @@ $ZSTD --format=xz -V || LZMAMODE=0 if [ $LZMAMODE -eq 1 ]; then $ECHO "xz support detected" XZEXE=1 - xz -V && lzma -V || XZEXE=0 + xz -Q -V && lzma -Q -V || XZEXE=0 if [ $XZEXE -eq 1 ]; then $ECHO "Testing zstd xz and lzma support" ./datagen > tmp $ZSTD --format=lzma -f tmp $ZSTD --format=xz -f tmp - xz -t -v tmp.xz - xz -t -v tmp.lzma - xz -f -k tmp - lzma -f -k --lzma1 tmp + xz -Q -t -v tmp.xz + xz -Q -t -v tmp.lzma + xz -Q -f -k tmp + lzma -Q -f -k --lzma1 tmp $ZSTD -d -f -v tmp.xz $ZSTD -d -f -v tmp.lzma rm tmp* @@ -569,13 +569,13 @@ if [ $LZMAMODE -eq 1 ]; then $ECHO "Testing xz and lzma symlinks" ./datagen > tmp ./xz tmp - xz -d tmp.xz + xz -Q -d tmp.xz ./lzma tmp - lzma -d tmp.lzma + lzma -Q -d tmp.lzma $ECHO "Testing unxz and unlzma symlinks" - xz tmp + xz -Q tmp ./xz -d tmp.xz - lzma tmp + lzma -Q tmp ./lzma -d tmp.lzma rm xz unxz lzma unlzma rm tmp*