Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2013-07-07 22:29:57 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2013-07-07 22:29:57 +0400
commit7d2030d23378cd4a6f0f0be0997324d67b3e642a (patch)
tree57c95a0e385f6d7e9b40806dbd74e93a8fb45187 /intern
parent22f26b2ce4c75a562ce31d6633b7343acfd7f94a (diff)
Arrempt to fix Cycles compilation with Clang
Issue is caused by missing sse flags for Clang compilers, this flags only was set for GNU C compilers. Added if branch for Clang now, which contains the same flags apart from -mfpmath=sse, This is because Clang was claiming it's unused argument. Probably OSX would need some further checks since it's also using Clang. I've got no idea why it could have worked for OSX before..
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/intern/cycles/CMakeLists.txt b/intern/cycles/CMakeLists.txt
index cc132a2c3b2..82029e3a7af 100644
--- a/intern/cycles/CMakeLists.txt
+++ b/intern/cycles/CMakeLists.txt
@@ -25,6 +25,10 @@ elseif(CMAKE_COMPILER_IS_GNUCC)
set(CYCLES_SSE2_KERNEL_FLAGS "-ffast-math -msse -msse2 -mfpmath=sse")
set(CYCLES_SSE3_KERNEL_FLAGS "-ffast-math -msse -msse2 -msse3 -mssse3 -mfpmath=sse")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ffast-math")
+elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
+ set(CYCLES_SSE2_KERNEL_FLAGS "-ffast-math -msse -msse2")
+ set(CYCLES_SSE3_KERNEL_FLAGS "-ffast-math -msse -msse2 -msse3 -mssse3")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ffast-math")
endif()
# for OSL