diff options
author | Tristan Partin <tristan@partin.io> | 2022-08-16 07:36:48 (GMT) |
---|---|---|
committer | Tristan Partin <tristan@partin.io> | 2022-10-20 04:27:05 (GMT) |
commit | 198e532300f253ada3acac3ab5428ed991adb085 (patch) | |
tree | b5c04cd31e42772751dac47bc6a0780b581b871d /tests/test-lz4-sparse.sh | |
parent | e312412c60140b3d061526499cef22e5e99d7751 (diff) | |
download | lz4-198e532300f253ada3acac3ab5428ed991adb085.zip lz4-198e532300f253ada3acac3ab5428ed991adb085.tar.gz lz4-198e532300f253ada3acac3ab5428ed991adb085.tar.bz2 |
Update Meson build to 1.9.4
Specifically this adds support for the following options:
- LZ4_ALIGN_TEST
- LZ4_STATIC_LINKING_ONLY_DISABLE_MEMORY_ALLOCATION
- LZ4_DISTANCE_MAX
- LZ4_FAST_DEC_LOOP
- LZ4_FORCE_SW_BITCOUNT
- LZ4_FREESTANDING
- LZ4_USER_MEMORY_FUNCTIONS
- compiling ossfuzz targets
- compiling more test targets
- registering some tests
Diffstat (limited to 'tests/test-lz4-sparse.sh')
-rwxr-xr-x | tests/test-lz4-sparse.sh | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/tests/test-lz4-sparse.sh b/tests/test-lz4-sparse.sh new file mode 100755 index 0000000..99297ff --- /dev/null +++ b/tests/test-lz4-sparse.sh @@ -0,0 +1,42 @@ +#!/bin/sh + +FPREFIX="tmp-tls" + +set -e + +remove () { + rm $FPREFIX* +} + +trap remove EXIT + +set -x + +datagen -g5M -P100 > ${FPREFIX}dg5M +lz4 -B4D ${FPREFIX}dg5M -c | lz4 -dv --sparse > ${FPREFIX}cB4 +diff -s ${FPREFIX}dg5M ${FPREFIX}cB4 +lz4 -B5D ${FPREFIX}dg5M -c | lz4 -dv --sparse > ${FPREFIX}cB5 +diff -s ${FPREFIX}dg5M ${FPREFIX}cB5 +lz4 -B6D ${FPREFIX}dg5M -c | lz4 -dv --sparse > ${FPREFIX}cB6 +diff -s ${FPREFIX}dg5M ${FPREFIX}cB6 +lz4 -B7D ${FPREFIX}dg5M -c | lz4 -dv --sparse > ${FPREFIX}cB7 +diff -s ${FPREFIX}dg5M ${FPREFIX}cB7 +lz4 ${FPREFIX}dg5M -c | lz4 -dv --no-sparse > ${FPREFIX}nosparse +diff -s ${FPREFIX}dg5M ${FPREFIX}nosparse +ls -ls $FPREFIX* +datagen -s1 -g1200007 -P100 | lz4 | lz4 -dv --sparse > ${FPREFIX}odd # Odd size file (to generate non-full last block) +datagen -s1 -g1200007 -P100 | diff -s - ${FPREFIX}odd +ls -ls ${FPREFIX}odd +rm $FPREFIX* +printf "\n Compatibility with Console :" +echo "Hello World 1 !" | lz4 | lz4 -d -c +echo "Hello World 2 !" | lz4 | lz4 -d | cat +echo "Hello World 3 !" | lz4 --no-frame-crc | lz4 -d -c +printf "\n Compatibility with Append :" +datagen -P100 -g1M > ${FPREFIX}dg1M +cat ${FPREFIX}dg1M ${FPREFIX}dg1M > ${FPREFIX}2M +lz4 -B5 -v ${FPREFIX}dg1M ${FPREFIX}c +lz4 -d -v ${FPREFIX}c ${FPREFIX}r +lz4 -d -v ${FPREFIX}c -c >> ${FPREFIX}r +ls -ls $FPREFIX* +diff ${FPREFIX}2M ${FPREFIX}r |