From 2297a31eb432c36e91892dc3da9a8412c1867344 Mon Sep 17 00:00:00 2001 From: Alper Ak Date: Tue, 8 Jul 2025 22:56:35 +0300 Subject: [PATCH] snappy: Upgrade 1.1.10 -> 1.2.2 to to allow CMake 4+ compatibility - Dropped patch because already fixed in the newer version. Changelog: - We fixed a very old issue of data corruption when compressed size exceeds 4GB. This can happen when you compress data close to 4GB and it's incompressible, for example, random data. - Started to use minimum CMake 3.10 because older ones are not planned to be supported. - Various other small fixes - We restored old functions/symbols after reports of ABI incompatibility apache/arrow#41058 conda-forge/snappy-feedstock#35 #183 - Level API was added with level 2 support. Compresses 5-10% denser and decompresses 5-10% faster. The compression speed drop is about 20-30% - Minor fixes Fix: | CMake Error at CMakeLists.txt:29 (cmake_minimum_required): | Compatibility with CMake < 3.5 has been removed from CMake. | | Update the VERSION argument value. Or, use the ... syntax | to tell CMake that the project requires at least but has been updated | to work with policies introduced by or earlier. | | Or, add -DCMAKE_POLICY_VERSION_MINIMUM=3.5 to try configuring anyway. | | | -- Configuring incomplete, errors occurred! Signed-off-by: Alper Ak Signed-off-by: Khem Raj --- .../snappy/fix-build-on-32bit-arm.patch | 33 ------------------- .../{snappy_1.1.10.bb => snappy_1.2.2.bb} | 7 ++-- 2 files changed, 2 insertions(+), 38 deletions(-) delete mode 100644 meta-oe/recipes-extended/snappy/snappy/fix-build-on-32bit-arm.patch rename meta-oe/recipes-extended/snappy/{snappy_1.1.10.bb => snappy_1.2.2.bb} (87%) diff --git a/meta-oe/recipes-extended/snappy/snappy/fix-build-on-32bit-arm.patch b/meta-oe/recipes-extended/snappy/snappy/fix-build-on-32bit-arm.patch deleted file mode 100644 index b6ab149e19..0000000000 --- a/meta-oe/recipes-extended/snappy/snappy/fix-build-on-32bit-arm.patch +++ /dev/null @@ -1,33 +0,0 @@ -From ecb3bcc283ce740a34d6342cbcda569f3193ade9 Mon Sep 17 00:00:00 2001 -From: David Michael -Date: Mon, 1 May 2023 11:14:32 -0400 -Subject: [PATCH] Specifically check for NEON for ARMv8 CPUs. - -The actual NEON implementation uses instructions that are not -supported on 32-bit CPUs. Make the CMake test reflect this so that -ARMv7 builds succeed again. - -Upstream-Status: Submitted [https://github.com/google/snappy/pull/169] - -Signed-off-by: David Michael -Signed-off-by: Alper Ak ---- - CMakeLists.txt | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 85afe58e..e8775859 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -207,9 +207,9 @@ int main() { - check_cxx_source_compiles(" - #include - int main() { -- uint8_t val = 3, dup[8]; -+ uint8_t val = 3; - uint8x16_t v = vld1q_dup_u8(&val); -- vst1q_u8(dup, v); -+ val = vmaxvq_u8(v); - return 0; - }" SNAPPY_HAVE_NEON) - diff --git a/meta-oe/recipes-extended/snappy/snappy_1.1.10.bb b/meta-oe/recipes-extended/snappy/snappy_1.2.2.bb similarity index 87% rename from meta-oe/recipes-extended/snappy/snappy_1.1.10.bb rename to meta-oe/recipes-extended/snappy/snappy_1.2.2.bb index 2a49ba99b0..7601fdde50 100644 --- a/meta-oe/recipes-extended/snappy/snappy_1.1.10.bb +++ b/meta-oe/recipes-extended/snappy/snappy_1.2.2.bb @@ -10,11 +10,8 @@ compression ratio." LICENSE = "BSD-3-Clause" LIC_FILES_CHKSUM = "file://COPYING;md5=f62f3080324a97b3159a7a7e61812d0c" -SRC_URI = "gitsm://github.com/google/snappy.git;protocol=https;branch=main \ - file://fix-build-on-32bit-arm.patch" - -SRCREV = "dc05e026488865bc69313a68bcc03ef2e4ea8e83" - +SRC_URI = "gitsm://github.com/google/snappy.git;protocol=https;branch=main" +SRCREV = "6af9287fbdb913f0794d0148c6aa43b58e63c8e3" inherit cmake pkgconfig