aboutsummaryrefslogtreecommitdiff
path: root/src/liblzma/check
diff options
context:
space:
mode:
authorJia Tan <jiat0218@gmail.com>2024-02-01 16:06:29 +0800
committerJia Tan <jiat0218@gmail.com>2024-02-01 20:09:11 +0800
commitca9015f4dead2c97b48f5a6933631b0a448b65b9 (patch)
tree18424aed02fbe7de6e016d6bc262f76fee7ef371 /src/liblzma/check
parentliblzma: Only use ifunc in crcXX_fast.c if its needed. (diff)
downloadxz-ca9015f4dead2c97b48f5a6933631b0a448b65b9.tar.xz
liblzma: Check HAVE_USABLE_CLMUL before omitting CRC64 table.
If liblzma is configured with --disable-clmul-crc CFLAGS="-msse4.1 -mpclmul", then it will fail to compile because the generic version must be used but the CRC tables were not included.
Diffstat (limited to 'src/liblzma/check')
-rw-r--r--src/liblzma/check/crc64_table.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/liblzma/check/crc64_table.c b/src/liblzma/check/crc64_table.c
index 0ae9dda8..806a9ce3 100644
--- a/src/liblzma/check/crc64_table.c
+++ b/src/liblzma/check/crc64_table.c
@@ -15,9 +15,9 @@
// FIXME: Compared to crc_common.h this has to check for __x86_64__ too
// so that in 32-bit builds crc64_x86.S won't break due to a missing table.
-#if (defined(__x86_64__) && defined(__SSSE3__) \
+#if defined(HAVE_USABLE_CLMUL) && ((defined(__x86_64__) && defined(__SSSE3__) \
&& defined(__SSE4_1__) && defined(__PCLMUL__)) \
- || (defined(__e2k__) && __iset__ >= 6)
+ || (defined(__e2k__) && __iset__ >= 6))
# define X86_CLMUL_NO_TABLE 1
#endif