From aca1710c5f67c410f341a3702525aa8ba15bb99f Mon Sep 17 00:00:00 2001 From: Christophe Riccio Date: Mon, 2 May 2016 23:32:19 +0200 Subject: [PATCH] Fixed ignoring unknown option '/arch:SSE2' warning while compiling with Visual C++ in 64 bits with SSE3 enabled --- CMakeLists.txt | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 12d8abbd..a11c561c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -120,7 +120,7 @@ elseif(GLM_TEST_ENABLE_SIMD_SSE3) add_definitions(-msse3) elseif(GLM_USE_INTEL) add_definitions(/QxSSE3) - elseif(MSVC) + elseif(MSVC AND NOT CMAKE_CL_64) add_definitions(/arch:SSE2) # VC doesn't support /arch:SSE3 endif() elseif(GLM_TEST_ENABLE_SIMD_SSE2) @@ -128,10 +128,8 @@ elseif(GLM_TEST_ENABLE_SIMD_SSE2) add_definitions(-msse2) elseif(GLM_USE_INTEL) add_definitions(/QxSSE2) - elseif(MSVC) - if(NOT CMAKE_CL_64) - add_definitions(/arch:SSE2) - endif() + elseif(MSVC AND NOT CMAKE_CL_64) + add_definitions(/arch:SSE2) endif() endif()