[CMake] Xcode Link Binary With Libraries phase

István Csanády istvancsanady at gmail.com
Mon Sep 28 04:51:36 EDT 2015


Hi,

I have multiple framework targets in my project, that depend on each other.
I add the linking phase using the target_link_libraries command

target_link_libraries (${PROJECT_NAME} ${USED_LIBS})

that will create linker flags like this:

/Users/icsanady/occt_git/occt/src/TKernel/Debug$(EFFECTIVE_PLATFORM_NAME)/TKernel.framework/Versions/A/TKernel

There are two problems with this:
1. I don't want to link to the full path, but rather a relative path
2. My frameworks are not versioned, so I want the trailing /Versions/A part
removed

If I add the dependent framework through the Build Phases/Link Binary With
Libraries phase, everything works as expected. Can I somehow add that build
phase with CMake?

Thanks,
Istvan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20150928/a8b16ae3/attachment.html>


More information about the CMake mailing list