From 330844dc60c8648d8df038a031f9ea117ba106ab Mon Sep 17 00:00:00 2001 From: Edgar Velazquez-Armendariz Date: Sat, 25 Jan 2014 23:31:53 -0500 Subject: [PATCH] Set some specific build options for gcc and clang. --- data/cmake/MitsubaBuildOptions.cmake | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/data/cmake/MitsubaBuildOptions.cmake b/data/cmake/MitsubaBuildOptions.cmake index 7aae4210..a53e56f1 100644 --- a/data/cmake/MitsubaBuildOptions.cmake +++ b/data/cmake/MitsubaBuildOptions.cmake @@ -10,7 +10,13 @@ endif() if (MTS_CMAKE_INIT) set(MTS_CXX_FLAGS "${CMAKE_CXX_FLAGS}") if (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang") - set(MTS_CXX_FLAGS "-fvisibility=hidden -pipe -march=nocona -mfpmath=sse -ffast-math -Wall -Winvalid-pch") + set(MTS_CXX_FLAGS "-fvisibility=hidden -pipe -march=nocona -ffast-math -Wall -Winvalid-pch") + endif() + if (CMAKE_CXX_COMPILER_ID MATCHES "GNU") + set(MTS_CXX_FLAGS "${MTS_CXX_FLAGS} -mfpmath=sse") + endif() + if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") + set(MTS_CXX_FLAGS "${MTS_CXX_FLAGS} -ftemplate-depth=512") endif() if (MTS_CXX_FLAGS) set(CMAKE_CXX_FLAGS "${MTS_CXX_FLAGS} ${CMAKE_CXX_FLAGS}" CACHE