Skip to content

Commit

Permalink
Merge pull request #193 from mthz/master
Browse files Browse the repository at this point in the history
fixed non-arm optimization flags
  • Loading branch information
RainerKuemmerle authored Jul 26, 2017
2 parents 472b98e + cd85949 commit 17fce87
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ IF(CMAKE_COMPILER_IS_GNUCXX)
OPTION (BUILD_WITH_MARCH_NATIVE "Build with \"-march native\"" ON)
MESSAGE(STATUS "Compiling with GCC")

IF(NOT ${ARCH} MATCHES arm)
IF(NOT "${ARCH}" MATCHES "arm")
# Generic settings for optimisation
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O3 -msse4.2")
SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -O3 -msse4.2")
Expand All @@ -209,7 +209,7 @@ IF(CMAKE_COMPILER_IS_GNUCXX)
#SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
#ENDIF(${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
# Linux
IF(BUILD_WITH_MARCH_NATIVE AND NOT ${ARCH} MATCHES arm AND ${CMAKE_SYSTEM_NAME} MATCHES "Linux")
IF(BUILD_WITH_MARCH_NATIVE AND NOT "${ARCH}" MATCHES "arm" AND "${CMAKE_SYSTEM_NAME}" MATCHES "Linux")
SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -march=native")
SET(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -march=native")
ENDIF()
Expand Down

0 comments on commit 17fce87

Please sign in to comment.