package/libdeflate: bump version to 1.18

Removed patches included in upstream release.

Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
master
Bernd Kuhls 2023-06-07 19:18:34 +02:00 committed by Thomas Petazzoni
parent 618eb375a0
commit d2a2fb01c4
5 changed files with 2 additions and 129 deletions

View File

@ -682,8 +682,6 @@ package/libconfuse/0001-Fix-163-unterminated-username-used-with-getpwnam.patch U
package/libcorrect/0002-CMakeLists.txt-conditionally-use-fsanitize-address.patch Upstream
package/libcuefile/0001-fix-static-link.patch Upstream
package/libdaemon/0001-testd-use-unistd-h-instead-of-sys-unistd-h.patch Upstream
package/libdeflate/0001-lib-arm-crc32-use-crypto-target-when-required-due-to-gcc-bug.patch Upstream
package/libdeflate/0002-lib-arm-cpu_features-fix-build-error-due-to-PMULL-enabled-without-NEON.patch Upstream
package/libdnet/0001-python-makefile.patch Upstream
package/libdnet/0002-Correct-path-to-string-h-from-bsd.patch Upstream
package/libdrm/0001-tests-meson.build-disable-nouveau-tests-for-static-b.patch Upstream

View File

@ -1,90 +0,0 @@
From f8f022e5bc574088ae80327ea5f88a8fe09b48c8 Mon Sep 17 00:00:00 2001
From: Eric Biggers <ebiggers3@gmail.com>
Date: Sun, 25 Dec 2022 15:05:52 -0800
Subject: [PATCH] lib/arm/crc32: use crypto target when required due to gcc bug
Fixes https://github.com/ebiggers/libdeflate/issues/280
Fixes: 6db64ab7afd2 ("lib/crc32: CRC-32 optimizations and other improvements")
[Retrieved from:
https://github.com/ebiggers/libdeflate/commit/f8f022e5bc574088ae80327ea5f88a8fe09b48c8]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
lib/arm/cpu_features.h | 23 +++++++++++++++++++++++
lib/arm/crc32_impl.h | 9 +++++----
2 files changed, 28 insertions(+), 4 deletions(-)
diff --git a/lib/arm/cpu_features.h b/lib/arm/cpu_features.h
index 204c0cd5..4092eba8 100644
--- a/lib/arm/cpu_features.h
+++ b/lib/arm/cpu_features.h
@@ -116,6 +116,29 @@ static inline u32 get_arm_cpu_features(void) { return 0; }
#else
# define HAVE_PMULL_INTRIN 0
#endif
+/*
+ * Set USE_PMULL_TARGET_EVEN_IF_NATIVE if a workaround for a gcc bug that was
+ * fixed by commit 11a113d501ff ("aarch64: Simplify feature definitions") in gcc
+ * 13 is needed. A minimal program that fails to build due to this bug when
+ * compiled with -mcpu=emag, at least with gcc 10 through 12, is:
+ *
+ * static inline __attribute__((always_inline,target("+crypto"))) void f() {}
+ * void g() { f(); }
+ *
+ * The error is:
+ *
+ * error: inlining failed in call to always_inline f: target specific option mismatch
+ *
+ * The workaround is to explicitly add the crypto target to the non-inline
+ * function g(), even though this should not be required due to -mcpu=emag
+ * enabling 'crypto' natively and causing __ARM_FEATURE_CRYPTO to be defined.
+ */
+#if HAVE_PMULL_NATIVE && defined(ARCH_ARM64) && \
+ GCC_PREREQ(6, 1) && !GCC_PREREQ(13, 1)
+# define USE_PMULL_TARGET_EVEN_IF_NATIVE 1
+#else
+# define USE_PMULL_TARGET_EVEN_IF_NATIVE 0
+#endif
/* CRC32 */
#ifdef __ARM_FEATURE_CRC32
diff --git a/lib/arm/crc32_impl.h b/lib/arm/crc32_impl.h
index e426a63d..b9300e4b 100644
--- a/lib/arm/crc32_impl.h
+++ b/lib/arm/crc32_impl.h
@@ -236,7 +236,7 @@ crc32_arm_crc(u32 crc, const u8 *p, size_t len)
* for implementations that use pmull for folding the data itself.
*/
#if HAVE_CRC32_INTRIN && HAVE_PMULL_INTRIN
-# if HAVE_CRC32_NATIVE && HAVE_PMULL_NATIVE
+# if HAVE_CRC32_NATIVE && HAVE_PMULL_NATIVE && !USE_PMULL_TARGET_EVEN_IF_NATIVE
# define ATTRIBUTES
# else
# ifdef ARCH_ARM32
@@ -438,7 +438,7 @@ crc32_arm_crc_pmullcombine(u32 crc, const u8 *p, size_t len)
#if HAVE_PMULL_INTRIN
# define crc32_arm_pmullx4 crc32_arm_pmullx4
# define SUFFIX _pmullx4
-# if HAVE_PMULL_NATIVE
+# if HAVE_PMULL_NATIVE && !USE_PMULL_TARGET_EVEN_IF_NATIVE
# define ATTRIBUTES
# else
# ifdef ARCH_ARM32
@@ -558,7 +558,7 @@ crc32_arm_pmullx4(u32 crc, const u8 *p, size_t len)
#if defined(ARCH_ARM64) && HAVE_PMULL_INTRIN && HAVE_CRC32_INTRIN
# define crc32_arm_pmullx12_crc crc32_arm_pmullx12_crc
# define SUFFIX _pmullx12_crc
-# if HAVE_PMULL_NATIVE && HAVE_CRC32_NATIVE
+# if HAVE_PMULL_NATIVE && HAVE_CRC32_NATIVE && !USE_PMULL_TARGET_EVEN_IF_NATIVE
# define ATTRIBUTES
# else
# ifdef __clang__
@@ -584,7 +584,8 @@ crc32_arm_pmullx4(u32 crc, const u8 *p, size_t len)
(HAVE_SHA3_TARGET || HAVE_SHA3_NATIVE)
# define crc32_arm_pmullx12_crc_eor3 crc32_arm_pmullx12_crc_eor3
# define SUFFIX _pmullx12_crc_eor3
-# if HAVE_PMULL_NATIVE && HAVE_CRC32_NATIVE && HAVE_SHA3_NATIVE
+# if HAVE_PMULL_NATIVE && HAVE_CRC32_NATIVE && HAVE_SHA3_NATIVE && \
+ !USE_PMULL_TARGET_EVEN_IF_NATIVE
# define ATTRIBUTES
# else
# ifdef __clang__

View File

@ -1,35 +0,0 @@
From 079a6dd171583c1953017b703ec63c5367a284b4 Mon Sep 17 00:00:00 2001
From: Eric Biggers <ebiggers3@gmail.com>
Date: Mon, 26 Dec 2022 11:32:47 -0800
Subject: [PATCH] lib/arm/cpu_features: fix build error due to PMULL enabled
without NEON
When building for soft float arm32, HAVE_PMULL_INTRIN is being set when
it shouldn't be, causing a build error:
#error "NEON intrinsics not available with the soft-float ABI..."
Fix this by making HAVE_PMULL_INTRIN depend on HAVE_NEON_INTRIN, as used
to be the case, in order to get the 'defined(__ARM_FP)' dependency,
Fixes https://github.com/ebiggers/libdeflate/issues/282
Fixes: 84c76f6f2cf5 ("lib/arm: make crc32 code work with MSVC")
[Retrieved from:
https://github.com/ebiggers/libdeflate/commit/079a6dd171583c1953017b703ec63c5367a284b4]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
lib/arm/cpu_features.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/arm/cpu_features.h b/lib/arm/cpu_features.h
index 4092eba8..edcf7359 100644
--- a/lib/arm/cpu_features.h
+++ b/lib/arm/cpu_features.h
@@ -97,6 +97,7 @@ static inline u32 get_arm_cpu_features(void) { return 0; }
#endif
#if HAVE_PMULL_NATIVE || \
(HAVE_DYNAMIC_ARM_CPU_FEATURES && \
+ HAVE_NEON_INTRIN /* needed to exclude soft float arm32 case */ && \
(GCC_PREREQ(6, 1) || __has_builtin(__builtin_neon_vmull_p64) || \
defined(_MSC_VER)) && \
/*

View File

@ -1,3 +1,3 @@
# Locally computed
sha256 58b95040df7383dc0413defb700d9893c194732474283cc4c8f144b00a68154b libdeflate-1.15.tar.gz
sha256 225d982bcaf553221c76726358d2ea139bb34913180b20823c782cede060affd libdeflate-1.18.tar.gz
sha256 5d246dd2537307b80fed9ba5fdddf5d0fe7a8f023393a071182b9daed56b40fe COPYING

View File

@ -4,7 +4,7 @@
#
################################################################################
LIBDEFLATE_VERSION = 1.15
LIBDEFLATE_VERSION = 1.18
LIBDEFLATE_SITE = $(call github,ebiggers,libdeflate,v$(LIBDEFLATE_VERSION))
LIBDEFLATE_LICENSE = MIT
LIBDEFLATE_LICENSE_FILES = COPYING