[Bf-blender-cvs] [92d1ebc] fluid-mantaflow: fix for CMakeLists
Sebastián Barschkis
noreply at git.blender.org
Thu Oct 20 17:44:56 CEST 2016
Commit: 92d1ebc7d21cd3675e7283c9dca9ef758df02b16
Author: Sebastián Barschkis
Date: Mon Oct 10 22:39:12 2016 +0200
Branches: fluid-mantaflow
https://developer.blender.org/rB92d1ebc7d21cd3675e7283c9dca9ef758df02b16
fix for CMakeLists
===================================================================
M CMakeLists.txt
===================================================================
diff --git a/CMakeLists.txt b/CMakeLists.txt
index fbf256e..a51c69b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -610,7 +610,7 @@ if(APPLE)
if(${XCODE_VERSION} VERSION_LESS 4.3)
# use guaranteed existing sdk
- set(CMAKE_OSX_SYSROOT /Developer/SDKs/MacOSX10.10.sdk CACHE PATH "" FORCE)
+ set(CMAKE_OSX_SYSROOT /Developer/SDKs/MacOSX${OSX_SYSTEM}.sdk CACHE PATH "" FORCE)
else()
# note: xcode-select path could be ambigous,
# cause /Applications/Xcode.app/Contents/Developer or /Applications/Xcode.app would be allowed
@@ -630,9 +630,21 @@ if(APPLE)
set(CMAKE_FIND_ROOT_PATH ${CMAKE_OSX_SYSROOT})
endif()
- if(NOT CMAKE_OSX_DEPLOYMENT_TARGET)
- # 10.6 is our min. target, if you use higher sdk, weak linking happens
- set(CMAKE_OSX_DEPLOYMENT_TARGET "10.6" CACHE STRING "" FORCE)
+ if(WITH_CXX11)
+ # 10.9 is our min. target, if you use higher sdk, weak linking happens
+ if(CMAKE_OSX_DEPLOYMENT_TARGET)
+ if(${CMAKE_OSX_DEPLOYMENT_TARGET} VERSION_LESS 10.9)
+ message(STATUS "Setting deployment target to 10.9, lower versions are incompatible with WITH_CXX11")
+ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.9" CACHE STRING "" FORCE)
+ endif()
+ else()
+ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.9" CACHE STRING "" FORCE)
+ endif()
+ else()
+ if(NOT CMAKE_OSX_DEPLOYMENT_TARGET)
+ # 10.6 is our min. target, if you use higher sdk, weak linking happens
+ set(CMAKE_OSX_DEPLOYMENT_TARGET "10.6" CACHE STRING "" FORCE)
+ endif()
endif()
if(NOT ${CMAKE_GENERATOR} MATCHES "Xcode")
More information about the Bf-blender-cvs
mailing list