target_link_libraries() is supposed to work for linker flags as well:
cmake version 2.8.12
target_link_libraries
Link a target to given libraries.
target_link_libraries(target [item1 [item2 [...]]]
[[debug|optimized|general] item] ...)
As of 2.8.12, you can set target properties on an imported library to
specify its include directories, compile options etc, and these will be
automatically propagated to any other target that links to it via
target_link_libraries(). No more tedious faffing about with global
variables like
http://public.kitware.com/Bug/view.php?id=13574
On 8/11/2012, at 5:39 PM, cmake-requ...@cmake.org wrote:
From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf Of
David Cole
Sent: mercredi 7 novembre 2012 20:41
To: cmake; CMake Developers
Subject: [CMake] Bug fix