--- caffe2/CMakeLists.txt.orig	2026-07-08 17:44:27 UTC
+++ caffe2/CMakeLists.txt
@@ -532,7 +532,7 @@ endif()
 endif()
 
 # Enable conditional FP16 arithmetic intrinsics
-if(CPU_AARCH64 AND LINUX)
+if(CPU_AARCH64 AND CMAKE_SYSTEM_NAME MATCHES "FreeBSD")
 set_source_files_properties(${TORCH_ROOT}/aten/src/ATen/native/BlasKernel.cpp PROPERTIES COMPILE_OPTIONS -march=armv8.2-a+fp16)
 endif()
 
