diff --git a/baselibs.conf b/baselibs.conf index a9234b9..a3d5930 100644 --- a/baselibs.conf +++ b/baselibs.conf @@ -1 +1 @@ -libclzma-suse0 +libclzma-suse1 diff --git a/lzma-sdk-shlib.patch b/lzma-sdk-shlib.patch index 9a4a199..74d077b 100644 --- a/lzma-sdk-shlib.patch +++ b/lzma-sdk-shlib.patch @@ -21,9 +21,9 @@ Index: 1/Makefile.am +pkgconfigdir = ${libdir}/pkgconfig +pkgconfig_DATA = clzma.pc +# source list: C/Util/LzmaLib/makefile -+libclzma_la_SOURCES = C/7zAlloc.c C/7zArcIn.c C/7zBuf2.c C/7zBuf.c C/7zCrc.c C/7zCrcOpt.c C/7zDec.c C/7zFile.c C/7zStream.c C/7zVersion.rc C/Aes.c C/AesOpt.c C/Alloc.c C/Bcj2.c C/Bra86.c C/Bra.c C/BraIA64.c C/CpuArch.c C/Delta.c C/DllSecur.c C/LzFind.c C/Lzma2Dec.c C/Lzma2Enc.c C/Lzma86Dec.c C/Lzma86Enc.c C/LzmaDec.c C/LzmaEnc.c C/LzmaLib.c C/Ppmd7.c C/Ppmd7Dec.c C/Ppmd7Enc.c C/Sha256.c C/Sha256Opt.c C/Sort.c C/Xz.c C/XzCrc64.c C/XzCrc64Opt.c C/XzDec.c C/XzEnc.c C/XzIn.c -+#ifWIN32#SOURCES += C/Bcj2Enc.c C/LzFindMt.c C/MtCoder.c C/Threads.c -+libclzma_la_LDFLAGS = -release suse -version-info 0:0:0 ++#lzma.dll = C/Alloc.c C/CpuArch.c C/LzFind.c C/LzFindMt.c C/LzFindOpt.c C/LzmaDec.c C/LzmaEnc.c C/LzmaLib.c C/Threads.c ++libclzma_la_SOURCES = C/7zAlloc.c C/7zArcIn.c C/7zBuf.c C/7zBuf2.c C/7zCrc.c C/7zCrcOpt.c C/7zDec.c C/7zFile.c C/7zStream.c C/Aes.c C/AesOpt.c C/Alloc.c C/Bcj2.c C/Bcj2Enc.c C/Bra.c C/Bra86.c C/BraIA64.c C/CpuArch.c C/Delta.c C/DllSecur.c C/LzFind.c C/LzFindMt.c C/LzFindOpt.c C/Lzma2Dec.c C/Lzma2DecMt.c C/Lzma2Enc.c C/Lzma86Dec.c C/Lzma86Enc.c C/LzmaDec.c C/LzmaEnc.c C/LzmaLib.c C/MtCoder.c C/MtDec.c C/Ppmd7.c C/Ppmd7Dec.c C/Ppmd7Enc.c C/Sha256.c C/Sha256Opt.c C/Sort.c C/SwapBytes.c C/Threads.c C/Xz.c C/XzCrc64.c C/XzCrc64Opt.c C/XzDec.c C/XzEnc.c C/XzIn.c ++libclzma_la_LDFLAGS = -release suse -version-info 1:0:0 +clzmadir = ${includedir}/clzma +clzma_HEADERS = C/7zAlloc.h C/7zBuf.h C/7zCrc.h C/7zFile.h C/7z.h C/7zTypes.h C/7zVersion.h C/Aes.h C/Alloc.h C/Bcj2.h C/Bra.h C/Compiler.h C/CpuArch.h C/Delta.h C/DllSecur.h C/LzFind.h C/LzFindMt.h C/LzHash.h C/Lzma2Dec.h C/Lzma2Enc.h C/Lzma86.h C/LzmaDec.h C/LzmaEnc.h C/LzmaLib.h C/MtCoder.h C/Ppmd7.h C/Ppmd.h C/Precomp.h C/RotateDefs.h C/Sha256.h C/Sort.h C/Threads.h C/XzCrc64.h C/XzEnc.h C/Xz.h +clzma.pc: ${top_builddir}/config.status diff --git a/lzma-sdk.changes b/lzma-sdk.changes index 98889b8..0b1a157 100644 --- a/lzma-sdk.changes +++ b/lzma-sdk.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Tue Apr 30 10:42:48 UTC 2024 - Jan Engelhardt + +- Update to release 23.01 + * New filter for ARM64 executables. BCJ2 filter was improved + for better compression ratio. Some bugs were fixed. +- Add lzma-simd.patch to fix compiler error on old gcc + ------------------------------------------------------------------- Wed Mar 15 14:40:12 UTC 2023 - Martin Pluskal diff --git a/lzma-sdk.spec b/lzma-sdk.spec index 4a134df..6e038f5 100644 --- a/lzma-sdk.spec +++ b/lzma-sdk.spec @@ -1,7 +1,7 @@ # # spec file for package lzma-sdk # -# Copyright (c) 2023 SUSE LLC +# 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 @@ -16,21 +16,22 @@ # -%define _sver 2201 -%define _maver 22 +%define _sver 2301 +%define _maver 23 %define _miver 01 Name: lzma-sdk -Version: 22.01 +Version: 23.01 Release: 0 Summary: An implementation of LZMA compression # Actually the site says "Public Domain". See license file. License: LGPL-2.1-only Group: Productivity/Archiving/Compression URL: https://www.7-zip.org/sdk.html -Source0: https://www.7-zip.org/a/lzma%{_sver}.7z +Source0: https://www.7-zip.org/a/lzma%_sver.7z Source1: lzma-sdk-LICENSE.fedora Source2: baselibs.conf Patch1: lzma-sdk-shlib.patch +Patch2: lzma-simd.patch BuildRequires: automake BuildRequires: dos2unix BuildRequires: fdupes @@ -52,50 +53,48 @@ LZMA yields around 20%% better compression when operating at approximately zlib's speed, and around 40%% when trading more time. %package devel -Summary: Development libraries and headers for %{name} +Summary: Development libraries and headers for %name Group: Development/Languages/C and C++ -Requires: libclzma-suse0 = %{version} +Requires: libclzma-suse1 = %version %description devel -This package contains development libraries and headers for %{name}. +This package contains development libraries and headers for %name. -%package -n libclzma-suse0 +%package -n libclzma-suse1 Summary: LZMA stream encoding/decoding library from 7-Zip Group: System/Libraries -%description -n libclzma-suse0 +%description -n libclzma-suse1 Library for encoding/decoding LZMA streams, using the 7-Zip library implementation. %prep -%setup -q -c -n lzma%{_sver} -%patch -P 1 -p1 +%autosetup -c -n lzma%_sver -p1 perl -i -pe 's{AC_INIT.*}{AC_INIT([lzma-sdk], [%version])}' configure.ac dos2unix DOC/*.txt -install -p -m 0644 %{SOURCE1} . +install -p -m 0644 %SOURCE1 . %build autoreconf -fi %configure -make %{?_smp_mflags} +%make_build %install %make_install rm -f "%buildroot/%_libdir"/*.la -%post -n libclzma-suse0 -p /sbin/ldconfig -%postun -n libclzma-suse0 -p /sbin/ldconfig +%ldconfig_scriptlets -n libclzma-suse1 -%files -n libclzma-suse0 +%files -n libclzma-suse1 %license lzma-sdk-LICENSE.fedora %doc DOC/lzma.txt DOC/lzma-history.txt -%{_libdir}/libclzma-suse.so.0* +%_libdir/libclzma-suse.so.* %files devel %license lzma-sdk-LICENSE.fedora %doc DOC/7z*.txt DOC/Methods.txt -%{_includedir}/clzma/ -%{_libdir}/libclzma.so -%{_libdir}/pkgconfig/clzma.pc +%_includedir/clzma/ +%_libdir/libclzma.so +%_libdir/pkgconfig/clzma.pc %changelog diff --git a/lzma-simd.patch b/lzma-simd.patch new file mode 100644 index 0000000..7aaa8e6 --- /dev/null +++ b/lzma-simd.patch @@ -0,0 +1,25 @@ +From: Jan Engelhardt +Date: 2024-05-01 00:14:04.625759204 +0200 +Fix build failures involving SIMD code + +Fix build failure on Leap 15.6/gcc-7 amd64: +[ 31s] C/SwapBytes.c:312:7: error: incompatible types when initializing type +'__m256i {aka const __vector(4) long long int}' using type 'int' + +--- + C/SwapBytes.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: 23/C/SwapBytes.c +=================================================================== +--- a/C/SwapBytes.c ++++ b/C/SwapBytes.c +@@ -22,7 +22,7 @@ typedef UInt32 CSwapUInt32; + // #if defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1900) + #if defined(__clang__) && (__clang_major__ >= 4) \ + || defined(Z7_GCC_VERSION) && (Z7_GCC_VERSION >= 40701) +- #define k_SwapBytes_Mode_MAX k_SwapBytes_Mode_AVX2 ++ #define k_SwapBytes_Mode_MAX k_SwapBytes_Mode_SSE2 + #define SWAP_ATTRIB_SSE2 __attribute__((__target__("sse2"))) + #define SWAP_ATTRIB_SSSE3 __attribute__((__target__("ssse3"))) + #define SWAP_ATTRIB_AVX2 __attribute__((__target__("avx2"))) diff --git a/lzma2201.7z b/lzma2201.7z deleted file mode 100644 index 130de7e..0000000 --- a/lzma2201.7z +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:35b1689169efbc7c3c147387e5495130f371b4bad8ec24f049d28e126d52d9fe -size 1261282 diff --git a/lzma2301.7z b/lzma2301.7z new file mode 100644 index 0000000..43e21e0 --- /dev/null +++ b/lzma2301.7z @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:317dd834d6bbfd95433488b832e823cd3d4d420101436422c03af88507dd1370 +size 1322733