From 238082d09eb2453a9b6e98f359fb0eed05086694 Mon Sep 17 00:00:00 2001
From: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
Date: Wed, 18 Mar 2026 16:02:08 +0200
Subject: [PATCH] cmake: Portable target only for x86 32 bit

Turns out that we can't compile the assembly versions of blake3 on
vanilla x86 32 bit. Just use the portable target.

Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
---
 CMakeLists.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4e4e01e6..209226b6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -614,7 +614,7 @@ set(TARGET_HAS_NEON FALSE)
 # Use portable implementations instead
 if(WIN32)
     message(STATUS "Windows detected: using portable SIMD implementations")
-elseif(TARGET_CPU_ANY_X86 AND NOT ENABLE_PORTABLE_TARGET)
+elseif(TARGET_CPU_X86_64 AND NOT ENABLE_PORTABLE_TARGET)
     check_c_source_compiles("
         #include <emmintrin.h>
         int main() { __m128i a = _mm_setzero_si128(); return 0; }
