Commit 21630e2d authored by Ghislain MARY's avatar Ghislain MARY

Allow setting CMAKE_OSX_DEPLOYMENT_TARGET manually for Python build.

parent 705bac23
......@@ -53,11 +53,13 @@ set(LINPHONE_BUILDER_PKG_CONFIG_LIBDIR ${CMAKE_INSTALL_PREFIX}/lib/pkgconfig) #
if (UNIX)
if(APPLE)
execute_process(COMMAND "${PYTHON_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/configs/python/mac_getplatform.py"
OUTPUT_VARIABLE MAC_PLATFORM
OUTPUT_STRIP_TRAILING_WHITESPACE
)
list(GET MAC_PLATFORM 0 CMAKE_OSX_DEPLOYMENT_TARGET)
if(NOT CMAKE_OSX_DEPLOYMENT_TARGET)
execute_process(COMMAND "${PYTHON_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/configs/python/mac_getplatform.py"
OUTPUT_VARIABLE MAC_PLATFORM
OUTPUT_STRIP_TRAILING_WHITESPACE
)
list(GET MAC_PLATFORM 0 CMAKE_OSX_DEPLOYMENT_TARGET)
endif()
set(CMAKE_OSX_ARCHITECTURES "x86_64")
set(LINPHONE_BUILDER_CPPFLAGS "-mmacosx-version-min=${CMAKE_OSX_DEPLOYMENT_TARGET} -arch ${CMAKE_OSX_ARCHITECTURES}")
......
......@@ -195,7 +195,7 @@ else()
if(CMAKE_OSX_DEPLOYMENT_TARGET)
set(DEPLOYMENT_TARGET "${CMAKE_OSX_DEPLOYMENT_TARGET}")
else()
set(DEPLOYEMENT_TARGET "10.7")
set(DEPLOYMENT_TARGET "10.7")
endif()
set(PLATFORM_OS "macosx-${DEPLOYMENT_TARGET}")
else()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment