[CMake] Link different libraries in different targets

domenico the.secator at gmail.com
Tue Apr 2 12:08:23 EDT 2013


Hi there !

I'm quite new to CMake, so please forgive me if the question seems obvious.
My project has lines like :

link_directories(/path/to/libA/)
add_library(my_project SHARED my_file.cpp)
target_link_libraries(my_project A)

I browsed help and googled a few, but I still wonder how I could set
"/path/to/libA/" to be different according to targets.
Something like "/path/to/libA/Foo/" for some targets "/path/to/libA/Bar/"
for others.
But my targets are not the basic "Release/Debug/..." ones, more diverse.

Info : I'm working with VS2008, but trying CMake for Mac/Linux/iOS ports.

Thanks
Domé
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130402/8a74e584/attachment.htm>


More information about the CMake mailing list