From 937d82eee68f09981a3be44be7b7fc96f3fac56b Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Wed, 21 Oct 2026 22:36:19 +0900 Subject: [PATCH] Fix FreeBSD ARM builds selecting x86 SIMD helpers Select plain SHA, BLAKE2s and Argon2 helpers for non-x86 targets when SIMD_SUPPORTED is zero. Preserve flagged helpers for x86 NOSSE2 builds and the x86 slice of macOS universal builds, keeping SHA compilation and BLAKE2s linking valid. Normal and NOASM console tests passed on FreeBSD 15 amd64 and Linux x64. Checked 19 object-selection configurations and targeted Clang compilation/linking with SHA-256 and BLAKE2s vectors on Linux. ARM coverage is limited to makefile checks. Fixes #1934 --- src/Volume/Volume.make | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Volume/Volume.make b/src/Volume/Volume.make index 519b3667..bd0e38d5 100644 --- a/src/Volume/Volume.make +++ b/src/Volume/Volume.make @@ -95,7 +95,9 @@ else OBJS += ../Crypto/Aescrypt.o endif -ifeq "$(PLATFORM):$(LOCAL_DEVELOPMENT_BUILD):$(CPU_ARCH)" "MacOSX:true:arm64" +# Keep flagged helpers for x86 NOSSE2 builds; SIMD_SUPPORTED also covers +# the x86 slice of macOS universal builds on ARM hosts. +ifeq "$(filter x86 x64,$(CPU_ARCH)):$(SIMD_SUPPORTED)" ":0" OBJS += ../Crypto/blake2s_SSE41.o OBJS += ../Crypto/blake2s_SSSE3.o OBJS += ../Crypto/Sha2Intel.o