Fix incorrect declaration of FORCE_SSE2

Signed-off-by: Vladislav Shchapov <vladislav@shchapov.ru>
This commit is contained in:
Vladislav Shchapov 2025-02-25 11:42:48 +05:00 committed by Hans Kristian Rosbach
parent 85223403d9
commit 356a7976db

View File

@ -611,13 +611,6 @@ if(MSVC)
add_definitions(-D_CRT_NONSTDC_NO_DEPRECATE)
endif()
if(BASEARCH_X86_FOUND)
# FORCE_SSE2 option will only be shown if HAVE_SSE2_INTRIN is true
if("${ARCH}" MATCHES "i[3-6]86")
cmake_dependent_option(FORCE_SSE2 "Always assume CPU is SSE2 capable" OFF "HAVE_SSE2_INTRIN" OFF)
endif()
endif()
#
# Enable deflate_quick at level 1
#
@ -939,6 +932,10 @@ if(WITH_OPTIM)
endif()
if(WITH_SSE2)
check_sse2_intrinsics()
# FORCE_SSE2 option will only be shown if HAVE_SSE2_INTRIN is true
if("${ARCH}" MATCHES "i[3-6]86")
cmake_dependent_option(FORCE_SSE2 "Always assume CPU is SSE2 capable" OFF "HAVE_SSE2_INTRIN" OFF)
endif()
if(HAVE_SSE2_INTRIN)
add_definitions(-DX86_SSE2)
set(SSE2_SRCS ${ARCHDIR}/chunkset_sse2.c ${ARCHDIR}/compare256_sse2.c ${ARCHDIR}/slide_hash_sse2.c)