From c56b822cbae1c8904bd50961e17f06c4f04330a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADtor=20Santos=20Costa?= Date: Tue, 5 Jan 2016 03:33:34 +0000 Subject: [PATCH] clang does not like -freorder-blocks --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 70d39abf5..64ae907a9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -239,7 +239,11 @@ endif() # Model Specific if (HAVE_GCC) set_property( DIRECTORY APPEND PROPERTY COMPILE_OPTIONS -Wall ) +if ( ${C_COMPILER} MATCHES "GNU") set_property( DIRECTORY APPEND PROPERTY COMPILE_OPTIONS $<$:-O3;-fomit-frame-pointer;-fstrict-aliasing;-freorder-blocks;-fsched-interblock> ) +else() + set_property( DIRECTORY APPEND PROPERTY COMPILE_OPTIONS $<$:-O3;-fstrict-aliasing;-freorder-blocks;-fsched-interblock> ) +endif() set_property( DIRECTORY APPEND PROPERTY COMPILE_OPTIONS -fexceptions ) endif()