Re: [tarlz] testsuite failure on Alpine (edge)

2024-04-25 Thread Antonio Diaz Diaz

jd...@ube.sent.com wrote:

so it seems that we are on the right track with the unsupported 'T'
separator. will just patch out the section as before and put tarlz to
work around the office.


Thanks again for the feedback. I'll modify the test to skip the dates that 
the system's 'touch' can't manage because that seems to mean that the system 
itself (mktime) is unable to manage them.



thanks for the lzip suite of utilities: they saved us from a ton of
recovery work over the years.


You are welcome. :-)

Best regards,
Antonio.



Re: [tarlz] testsuite failure on Alpine (edge)

2024-04-24 Thread Antonio Diaz Diaz

hello J Dean,

Thank you very much for reporting this.

J Dean wrote:

testing --create...touch: invalid date '2022-01-05T12:22:13'
[...]
could this be a busybox touch quirk? only by patching the --create --mtime test 
section out does the build complete with all other tests passing.


This seems to be the case; the touch command you are using probably does not 
understand the 'T' separator in '2022-01-05T12:22:13' and requires a space 
instead.


You may try to work around this limitation of touch by changing line 749 of 
testsuite/check.sh to something like the following:


touch -d 2022-01-05T12:22:13 bar >/dev/null 2>&1 || touch -d '2022-01-05 
12:22:13' bar || framework_failure



would like to package this for Alpine (lzip/lzlib/plzip are already in the 
official repos). is there a workaround, perhaps an alternative test? or can the 
test be patched out as above and the resultant binary be used in production, 
despite the check failure?


If the workaround above does not work, you may remove the test and use the 
binary until I release a version that skips the test in this case. This is 
not a bug in tarlz, but a limitation of this particular touch.


Best regards,
Antonio.



[tarlz] testsuite failure on Alpine (edge)

2024-04-24 Thread J Dean
0.25 against lzlib 1.14 and/or 1.15-pre1. dynamic and static builds all fail at 
the same point: 

g++ -march=native -O2 -fstack-protector-strong -fstack-clash-protection 
-ftrivial-auto-var-init=zero -fcf-protection=full -mshstk -Wformat 
-Werror=format-security -fomit-frame-pointer -flto=auto -ffat-lto-objects -pipe 
-D_GLIBCXX_ASSERTIONS=1 -D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS=1 
-D_LIBCPP_ENABLE_HARDENED_MODE=1 -static-pie 
-Wl,-z,relro,-z,now,-z,pack-relative-relocs -o tarlz arg_parser.o lzip_index.o 
archive_reader.o common.o common_decode.o common_mutex.o compress.o create.o 
create_lz.o decode.o decode_lz.o delete.o delete_lz.o exclude.o extended.o 
main.o -llz -lpthread
testing tarlz-0.25...
testing --list and --extract...
testing --concatenate...
testing --create...touch: invalid date '2022-01-05T12:22:13'
failure in testing framework
make: *** [Makefile:95: check] Error 1
>>> ERROR: tarlz: check failed

could this be a busybox touch quirk? only by patching the --create --mtime test 
section out does the build complete with all other tests passing. 

--- /dev/null
+++ b/testsuite/check.sh
@@ -731,35 +731,6 @@
 [ ! -e baz ] || test_failed $LINENO
 rm -f out.tar foo bar baz || framework_failure
 
-# test --create --mtime
-dates='@-9223372036854775808 @-9223372036854775807
-   -2147481748-12-31T23:59:59 -1970-01-01T00:00:00
-   -01-01T00:00:00 -01-01T00:00:01 -01-02T00:00:00
-   1697-10-17T11:03:27 1697-10-17T11:03:28 1697-10-17T11:03:29
-   1833-11-24T17:31:43 1833-11-24T17:31:44 1833-11-24T17:31:45
-   1901-12-13T20:45:51 1901-12-13T20:45:52 1901-12-13T20:45:53
-   1901-12-14T20:45:51
-   1969-12-31T23:59:58 1969-12-31T23:59:59
-   1970-01-01T00:00:00 1970-01-01T00:00:01 @0
-   2038-01-18T03:14:07 2038-01-19T03:14:07 2038-01-19T03:14:08
-   2106-02-07T06:28:15 2106-02-07T06:28:16
-   2242-03-16T12:56:31 2242-03-16T12:56:32 @8589934591 @8589934592
-   -12-31T23:59:58 -12-31T23:59:59
-   2147483647-12-31T23:59:59 @9223372036854775807'
-touch -d 2022-01-05T12:22:13 bar || framework_failure
-for i in ${dates} @-8Ei '2017-10-01 09:00:00' '2017-10-1 9:0:0' \
- '2017-10-01 09:00' '2017-10-01 09' 2017-10-01 ./bar ; do
-  touch foo || framework_failure
-  "${TARLZ}" -cf out.tar --mtime="$i" foo || test_failed $LINENO "$i"
-  is_uncompressed out.tar || test_failed $LINENO "$i"
-  "${TARLZ}" -q -df out.tar && test_failed $LINENO "$i"
-  "${TARLZ}" -xf out.tar || test_failed $LINENO "$i"
-  if [ "${d_works}" = yes ] ; then
-"${TARLZ}" -df out.tar --ignore-overflow || test_failed $LINENO "$i"
-  fi
-done
-rm -f out.tar foo bar || framework_failure
-
 mkdir dir || framework_failure
 for i in ${dates} ; do
   # Skip a time stamp $i if it's out of range for this platform,

would like to package this for Alpine (lzip/lzlib/plzip are already in the 
official repos). is there a workaround, perhaps an alternative test? or can the 
test be patched out as above and the resultant binary be used in production, 
despite the check failure?