Commit 3496824d authored by Gautier Pelloux-Prayer's avatar Gautier Pelloux-Prayer
Browse files

config-ios.cmake: rename SDK_VERSION to LINPHONE_IOS_DEPLOYMENT_TARGET and do...

config-ios.cmake: rename SDK_VERSION to LINPHONE_IOS_DEPLOYMENT_TARGET and do not force it to 6.0 if its already set
parent ebb7eb47
......@@ -43,9 +43,10 @@ set(DEFAULT_VALUE_ENABLE_ZRTP ON)
set(DEFAULT_VALUE_CMAKE_LINKING_TYPE "-DENABLE_STATIC=YES")
# Global configuration
set(SDK_VERSION 6.0)
if (NOT LINPHONE_IOS_DEPLOYMENT_TARGET)
set(LINPHONE_IOS_DEPLOYMENT_TARGET 6.0)
endif()
get_filename_component(COMPILER_NAME ${CMAKE_C_COMPILER} NAME)
string(REGEX REPLACE "-clang$" "" LINPHONE_BUILDER_HOST ${COMPILER_NAME})
string(REGEX REPLACE "^arm64" "aarch64" LINPHONE_BUILDER_HOST ${LINPHONE_BUILDER_HOST})
......@@ -55,13 +56,13 @@ if("${PLATFORM}" MATCHES "Simulator")
else()
set(CLANG_TARGET_SPECIFIER "iphoneos-version-min")
endif()
set(COMMON_FLAGS "-arch ${LINPHONE_BUILDER_OSX_ARCHITECTURES} -m${CLANG_TARGET_SPECIFIER}=${SDK_VERSION} -DTARGET_OS_IPHONE=1 -D__IOS -fms-extensions")
set(COMMON_FLAGS "-arch ${LINPHONE_BUILDER_OSX_ARCHITECTURES} -m${CLANG_TARGET_SPECIFIER}=${LINPHONE_IOS_DEPLOYMENT_TARGET} -DTARGET_OS_IPHONE=1 -D__IOS -fms-extensions")
set(LINPHONE_BUILDER_CPPFLAGS "${COMMON_FLAGS} -Dasm=__asm")
set(LINPHONE_BUILDER_LDFLAGS "${COMMON_FLAGS}")
set(LINPHONE_BUILDER_PKG_CONFIG_LIBDIR ${CMAKE_INSTALL_PREFIX}/lib/pkgconfig) # Restrict pkg-config to search in the install directory
unset(COMMON_FLAGS)
unset(CLANG_TARGET_SPECIFIER)
unset(SDK_VERSION)
unset(LINPHONE_IOS_DEPLOYMENT_TARGET)
#XCode7 requires Cmake 3.3.20150815 at least
if (NOT ${XCODE_VERSION} VERSION_LESS 7)
......
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