Xcode - Support "Code Sign on Copy"
Background
I'm trying to embed a framework to an Xcode project through CMake, the framework is unsigned which means it needs "Code Sign On Copy".
The CMake command I'm using is
set_source_files_properties(${SOME_FRAMEWORK} PROPERTIES MACOSX_PACKAGE_LOCATION Frameworks)
This does the trick to put framework in "Copy Files" (under "Build Phases"), but "Code Sign On Copy" remain unchecked.
Questions
- Is there a way to set "Code Sign On Copy" through CMake?
- It's possible to execute a PRE_LINK command which
codesign
the framework, problem is the identity is mine and I couldn't share it with others. Is there a good way to retrieve the default identity that Xcode is using?