OSX/cmake: enable clang compiler with xcode >= 4.3, tested o.k.now

This commit is contained in:
Jens Verwiebe 2012-03-14 23:42:46 +00:00
parent ea79c470d2
commit 23c1edb777

@ -267,9 +267,9 @@ if(APPLE)
endif()
if(${CMAKE_GENERATOR} MATCHES "Xcode")
if(${XCODE_VERSION} VERSION_EQUAL 4 OR ${XCODE_VERSION} VERSION_GREATER 4) # AND ${XCODE_VERSION} VERSION_LESS 4.3) in the works, needs collada fix for clang and gcc 4.7
if(${XCODE_VERSION} VERSION_EQUAL 4 OR ${XCODE_VERSION} VERSION_GREATER 4 AND ${XCODE_VERSION} VERSION_LESS 4.3)
# Xcode 4 defaults to the Apple LLVM Compiler.
# Override the default compiler selection because Blender only compiles with gcc
# Override the default compiler selection because Blender only compiles with gcc up to xcode 4.2
set(CMAKE_XCODE_ATTRIBUTE_GCC_VERSION "com.apple.compilers.llvmgcc42")
message(STATUS "Setting compiler to: " ${CMAKE_XCODE_ATTRIBUTE_GCC_VERSION})