Sync from SUSE:SLFO:Main libdeflate revision 7d1781d3366629fd14e20da96b02b9ed

This commit is contained in:
Adrian Schröter 2024-05-03 14:51:29 +02:00
commit f7355d426f
5 changed files with 307 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

2
baselibs.conf Normal file
View File

@ -0,0 +1,2 @@
libdeflate0

BIN
libdeflate-1.19.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

173
libdeflate.changes Normal file
View File

@ -0,0 +1,173 @@
-------------------------------------------------------------------
Mon Feb 12 14:09:50 UTC 2024 - pgajdos@suse.com
- baselibs for tools and devel reportedly not needed
- modified sources
% baselibs.conf
-------------------------------------------------------------------
Thu Feb 8 09:29:36 UTC 2024 - pgajdos@suse.com
- introduce baselibs.conf for openexr
https://build.opensuse.org/request/show/1144873
- added sources
+ baselibs.conf
-------------------------------------------------------------------
Sun Sep 17 09:08:22 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 1.19:
* Added new functions `libdeflate_alloc_compressor_ex()` and
`libdeflate_alloc_decompressor_ex()`. These functions allow
specifying a custom memory allocator on a per-compressor basis.
* libdeflate now always generates Huffman codes with at least 2
codewords. This fixes a compatibility issue where Windows
Explorer's ZIP unpacker could not decompress DEFLATE streams
created by libdeflate. libdeflate's behavior was
* allowed by the DEFLATE RFC, but not all software was okay
with it. In rare cases, compression ratios can be slightly
reduced by this change.
* Disabled the use of some compiler intrinsics on MSVC versions
where they don't work correctly.
* libdeflate can now compress up to the exact size of the
output buffer.
* Slightly improved compression performance at levels 1-9.
* Improved the compression ratio of very short inputs.
-------------------------------------------------------------------
Thu Apr 27 22:43:07 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 1.18:
* Fixed a bug where the build type didn't default to "Release"
when using CMake 3.10 or earlier.
* Fixed a bug where some optimized code wasn't used when
building with Clang 15 or later (x86), or with Clang 16
or later (aarch64).
* Fixed build errors with some architecture and compiler
combos:
* aarch64 with Clang 16
* armv6kz or armv7e-m with gcc
* armhf with gcc (on Debian only)
-------------------------------------------------------------------
Tue Jan 24 07:10:52 UTC 2023 - Paolo Stivanin <info@paolostivanin.com>
- update to 1.17:
* Improved the compression ratio at levels 10-12 slightly, mainly
levels 11-12. Some inputs (such as certain PNG files) see much
improved compression ratios. As a trade-off, compressing at
levels 11-12 is now about 5-20% slower.
* For consistency with zlib, the decompressor now returns an error
on some invalid inputs that were accepted before.
* Fixed a build error on arm64 with gcc with certain target CPUs.
* Fixed a build error in programs/gzip.c with uClibc.
-------------------------------------------------------------------
Thu Dec 29 22:30:08 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.15:
* libdeflate now uses CMake instead of a plain Makefile.
-------------------------------------------------------------------
Mon Oct 3 15:20:28 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.14:
Significantly improved decompression performance on all platforms. Examples
include (measuring DEFLATE only):
| Platform | Speedup over v1.13 |
|------------------------------------|--------------------|
| x86_64 (Intel Comet Lake), gcc | 1.287x |
-------------------------------------------------------------------
Mon Aug 8 20:57:28 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.13:
* Changed the 32-bit Windows build of the library to use the default calling
convention (cdecl) instead of stdcall, reverting a change from libdeflate 1.4.
* Fixed a couple macOS compatibility issues with the gzip program.
-------------------------------------------------------------------
Tue Jul 12 15:21:57 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.12:
* Improved CRC-32 performance on short inputs on x86 and ARM.
* Improved CRC-32 performance on Apple Silicon Macs by using a 12-way pmull
implementation. Performance on large inputs on M1 is now about 67 GB/s,
compared to 8 GB/s before, or 31 GB/s with the Apple-provided zlib.
* Improved CRC-32 performance on some other ARM CPUs by reworking the code so
that multiple crc32 instructions can be issued in parallel.
* Improved CRC-32 performance on some x86 CPUs by increasing the stride length
of the pclmul implementation.
* Improved Adler-32 performance on some x86 CPUs by optimizing the AVX-2
implementation. E.g., performance on Zen 1 improved from 19 to 30 GB/s, and
on Ice Lake from 35 to 41 GB/s (if the AVX-512 implementation is excluded).
* Removed the AVX-512 implementation of Adler-32 to avoid CPU frequency
downclocking, and because the AVX-2 implementation was made faster.
* Improved Adler-32 performance on some ARM CPUs by optimizing the NEON
* Improved compression performance slightly.
* Detect arm64 CPU features on Apple platforms, which should improve
performance in some areas such as CRC-32 computation.
* The included `gzip` and `gunzip` programs now support the `-q` option.
* The included `gunzip` program now passes through non-gzip data when both
the `-f` and `-c` options are used.
-------------------------------------------------------------------
Mon Feb 14 23:14:56 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.10:
* Added an additional check to the decompressor to make it quickly detect
certain bad inputs and not try to generate an unbounded amount of output.
* Cleaned up a few things in the compression code.
-------------------------------------------------------------------
Mon Jan 24 22:39:11 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.9:
* Heuristics were implemented which significantly improve the compression
ratio on data where short matches aren't useful, such as DNA sequencing
data. This applies to all compression levels, but primarily to levels 1-9.
* Levels 1 was made much faster, though it often compresses slightly worse
than before (but still better than zlib).
* Levels 8-9 were also made faster, though they often compress slightly worse
than before (but still better than zlib). On some data, levels 8-9 are much
faster and compress much better than before; this change addressed an issue
where levels 8-9 did poorly on certain files. The algorithm used by levels
8-9 is now more similar to that of levels 6-7 than to that of levels 10-12.
* Levels 2-3, 7, and 10-12 were strengthened slightly.
* Levels 4-6 were also strengthened slightly, but some of this improvement was
traded off to speed them up slightly as well.
* Levels 1-9 had their per-compressor memory usage greatly reduced.
* `make install` will now install a pkg-config file for libdeflate.
* The Makefile now supports the `DISABLE_SHARED` parameter to disable building
the shared library.
-------------------------------------------------------------------
Tue Jan 4 22:37:30 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 1.8:
* Added `-t` (test) option to `libdeflate-gunzip`.
* Unaligned access optimizations are now enabled on WebAssembly builds.
* Fixed a build error when building with the Intel C Compiler (ICC).
* Fixed a build error when building with uClibc.
* libdeflate's CI system has switched from Travis CI to GitHub Actions.
* Made some improvements to test scripts.
-------------------------------------------------------------------
Wed Jan 13 21:46:16 UTC 2021 - andy great <andythe_great@pm.me>
- Add workaround build fail due issue in dwz by deleting
libdeflate-gunzip and replace with symlink libdeflate-gzip to
fix dwz break with hardlink.
boo#1180984
-------------------------------------------------------------------
Wed Jan 13 12:11:47 UTC 2021 - Jan Engelhardt <jengelh@inai.de>
- Quantify the description's supposed "fast" claims
- Adhere to shared library packaging guide and split tools off
into subpackage.
-------------------------------------------------------------------
Wed Jan 13 08:07:49 UTC 2021 - andy great <andythe_great@pm.me>
- Initial package release.

106
libdeflate.spec Normal file
View File

@ -0,0 +1,106 @@
#
# spec file for package libdeflate
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define major 0
%define libname %{name}%{major}
Name: libdeflate
Version: 1.19
Release: 0
Summary: Library for DEFLATE/zlib/gzip compression and decompression
License: BSD-2-Clause
URL: https://github.com/ebiggers/libdeflate
Source: https://github.com/ebiggers/libdeflate/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
Source1: baselibs.conf
BuildRequires: cmake
BuildRequires: zlib-devel
%description
libdeflate is a library for whole-buffer DEFLATE-based compression
and decompression. It supports raw, zlib-wrapped and gzip-wrapped DEFLATE.
It is significantly faster than zlib and gzip (+72-187%%).
In addition, libdeflate provides optional high compression modes
above zlib's "level 9".
%package -n %{libname}
Summary: Library for DEFLATE/zlib/gzip compression and decompression
%description -n %{libname}
libdeflate is a library for whole-buffer DEFLATE-based compression
and decompression. It supports raw, zlib-wrapped and gzip-wrapped DEFLATE.
It is significantly faster than the zlib library:
- decompression speedup over gzip-1.10 is 2.28x (generic), 2.87x (AVX2)
- compression speedup over gzip is 1.72x (generic), 2.23x (AVX2)
In addition, libdeflate provides optional high compression modes
above zlib's "level 9".
%package tools
Summary: File compression utility
%description tools
A gzip implementation that uses libdeflate which is significantly
faster than the GNU gzip implementation (+72-187%%).
%package devel
Summary: Development files for %{name}
Requires: %{libname} = %{version}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%prep
%autosetup -p1
%build
%cmake \
-DLIBDEFLATE_BUILD_STATIC_LIB=OFF \
-DLIBDEFLATE_BUILD_TESTS=ON
%cmake_build
%install
%cmake_install
# Delete libdeflate-gunzip and replace with symlink libdeflate-gzip to fix dwz break with hardlink.
# boo#1180984
rm %{buildroot}%{_bindir}/libdeflate-gunzip
ln -s ./libdeflate-gzip %{buildroot}%{_bindir}/libdeflate-gunzip
%check
%ctest
%post -n %{libname} -p /sbin/ldconfig
%postun -n %{libname} -p /sbin/ldconfig
%files tools
%{_bindir}/libdeflate-gzip
%{_bindir}/libdeflate-gunzip
%files -n %{libname}
%{_libdir}/libdeflate.so.%{major}
%files devel
%license COPYING
%doc README.md
%{_includedir}/libdeflate.h
%{_libdir}/libdeflate.so
%{_libdir}/cmake/libdeflate
%{_libdir}/pkgconfig/libdeflate.pc
%changelog