On 10/13/2011 02:26 PM, Daniel Dekkers wrote: > Hi, > > How can I separate settings for different configurations in Xcode. > > As an example... > > SET_TARGET_PROPERTIES( ${APP_NAME} PROPERTIES > XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS ${IOS_CODE_SIGN_ENTITLEMENTS} ) > > ... sets the same entitlement file for all four configurations (Debug, > Release, MinSizeRel, RelWithDebInfo) to ${IOS_CODE_SIGN_ENTITLEMENTS}. > > But now i would like to use different different files for different > configurations, something like this: > > SET_TARGET_PROPERTIES( ${APP_NAME} PROPERTIES LINK_FLAG_DEBUG > XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS ${IOS_CODE_SIGN_ENTITLEMENTS_DEBUG} ) > SET_TARGET_PROPERTIES( ${APP_NAME} PROPERTIES LINK_FLAG_RELEASE > XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS ${IOS_CODE_SIGN_ENTITLEMENTS_ADHOC} ) > SET_TARGET_PROPERTIES( ${APP_NAME} PROPERTIES > LINK_FLAG_MINSIZEREL XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS > ${IOS_CODE_SIGN_ENTITLEMENTS_DISTRIBUTION} ) > SET_TARGET_PROPERTIES( ${APP_NAME} PROPERTIES > LINK_FLAG_RELWITHDEBINFO XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS > ${IOS_CODE_SIGN_ENTITLEMENTS_DEBUG} ) > > But this syntax is not recognized. > > Kind Regards, > > Daniel Dekkers
You can use XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS[variant=Debug] etc. See http://stackoverflow.com/questions/1354542/how-to-set-an-xcode-attribute-in-cmake-for-a-specific-configuration. Wonder why this didn't make it into the documentation. But then, googling XCODE_ATTRIBUTE returned this find pretty high up in the search results... Michael -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake