mirror of
https://github.com/eclipse/upm.git
synced 2025-03-15 04:57:30 +03:00
cmake: set -march=native for ARM platforms
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
parent
72b975b6cc
commit
3eda1bce16
@ -78,6 +78,11 @@ include (TargetArch)
|
|||||||
target_architecture (DETECTED_ARCH)
|
target_architecture (DETECTED_ARCH)
|
||||||
message( INFO " - Target arch is ${DETECTED_ARCH}")
|
message( INFO " - Target arch is ${DETECTED_ARCH}")
|
||||||
|
|
||||||
|
#-march=native for ARM when not defined/forced
|
||||||
|
if (DETECTED_ARCH MATCHES "arm.*" AND NOT CMAKE_CXX_FLAGS MATCHES "-march")
|
||||||
|
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=native")
|
||||||
|
endif()
|
||||||
|
|
||||||
# enable c++11 standards support
|
# enable c++11 standards support
|
||||||
if (ENABLECXX11)
|
if (ENABLECXX11)
|
||||||
include(CheckCXXCompilerFlag)
|
include(CheckCXXCompilerFlag)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user