diff --git a/lz4-1.9.3.tar.gz b/lz4-1.9.3.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..c26129a58b87b9a00b2889701abb76de2af5199d Binary files /dev/null and b/lz4-1.9.3.tar.gz differ diff --git a/lz4.spec b/lz4.spec new file mode 100644 index 0000000000000000000000000000000000000000..d0b900a8dcfbeb0185bf1e6711920fcf83c17632 --- /dev/null +++ b/lz4.spec @@ -0,0 +1,89 @@ +%define anolis_release 1 + +# relative to the RPM build directory +%global _vpath_srcdir contrib/meson +Name: lz4 +Version: 1.9.3 +Release: %{anolis_release}%{?dist} +Summary: Extremely fast compression algorithm + +License: GPLv2+ and BSD +URL: https://lz4.github.io/lz4/ +Source0: https://github.com/lz4/lz4/archive/v%{version}/%{name}-%{version}.tar.gz + +Obsoletes: %{name} < 1.7.5-3 + +BuildRequires: make +BuildRequires: gcc +BuildRequires: meson >= 0.43 + +%description +LZ4 is an extremely fast loss-less compression algorithm, providing compression +speed at 400 MB/s per core, scalable with multi-core CPU. It also features +an extremely fast decoder, with speed in multiple GB/s per core, typically +reaching RAM speed limits on multi-core systems. + +%package libs +Summary: Libaries for lz4 +Obsoletes: %{name} < 1.7.5-3 + +%description libs +This package contains the libaries for lz4. + +%package devel +Summary: Development files for lz4 +Requires: %{name}-libs%{?_isa} = %{version}-%{release} + +%description devel +This package contains the header(.h) and library(.so) files required to build +applications using liblz4 library. + +%package static +Summary: Static library for lz4 + +%description static +LZ4 is an extremely fast loss-less compression algorithm. This package +contains static libraries for static linking of applications. + +%prep +%autosetup + +%build +%meson \ + -Dbin_programs=true \ + -Ddefault_library=both \ + %{nil} +%meson_build + +%install +%meson_install + +%files +%license programs/COPYING +%doc NEWS +%{_bindir}/lz4 +%{_bindir}/lz4c +%{_bindir}/lz4cat +%{_bindir}/unlz4 +%{_mandir}/man1/lz4.1* +%{_mandir}/man1/lz4c.1* +%{_mandir}/man1/lz4cat.1* +%{_mandir}/man1/unlz4.1* + +%files libs +%doc lib/LICENSE +%{_libdir}/liblz4.so.* + +%files devel +%{_includedir}/lz4*.h +%{_libdir}/liblz4.so +%{_libdir}/pkgconfig/liblz4.pc + +%files static +%doc lib/LICENSE +%{_libdir}/liblz4.a + +%changelog +* Thu Mar 03 2022 Hongwei Qin - 1.9.3-1 +- Update to 1.9.3 and switch to Meson +- Init for Anolis OS 23