From: Mike Gelfand Date: Wed, 2 Aug 2017 04:12:31 +0000 (+0300) Subject: Enable ARC when configuring the project via CMake X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=55edcf22e59faa49f17d17afbed90738f7c49062;p=transmission Enable ARC when configuring the project via CMake --- diff --git a/macosx/CMakeLists.txt b/macosx/CMakeLists.txt index 1cf1b137b..bbc5997d6 100644 --- a/macosx/CMakeLists.txt +++ b/macosx/CMakeLists.txt @@ -1,5 +1,11 @@ project(trmac) +if(CMAKE_GENERATOR STREQUAL "Xcode") + set(CMAKE_XCODE_ATTRIBUTE_CLANG_ENABLE_OBJC_ARC ON) +else() + add_definitions(-fobjc-arc) +endif() + find_program(IBTOOL_EXECUTABLE ibtool REQUIRED) find_program(TIFFUTIL_EXECUTABLE tiffutil REQUIRED) find_program(INSTALL_NAME_TOOL_EXECUTABLE install_name_tool REQUIRED)