MantisBT - CMake
View Issue Details
0014791CMakeCMakepublic2014-03-06 10:212016-06-10 14:31
Philipp Möller 
Kitware Robot 
normalminoralways
closedmoved 
LinuxArch Linux
CMake 2.8.12.2 
 
0014791: Allow link directories to be set per target
Currently it is not possible to specify the directories in which libraries for linking are to be searched on a per target basis. This is a standard flag in most compilers.

Usually specifying the directory in which libraries are searched for is not necessary as CMake convention is to use full paths for libraries. Unfortunately, specifying the directory **only** (and not the actual libraries) is necessary to get the Visual Studio auto-linking feature to work which is used by several C++ libraries (Boost, CGAL).

A common thing for VS users is to do:

find_package(Boost COMPONENTS system) # checks omitted
add_executable(main main.cpp) # executable using Boost.system
link_directories(${Boost_LIBRARY_DIRS}) # global sucks, enable this per target
# set includes and so on
No tags attached.
Issue History
2014-03-06 10:21Philipp MöllerNew Issue
2016-06-10 14:29Kitware RobotNote Added: 0042501
2016-06-10 14:29Kitware RobotStatusnew => resolved
2016-06-10 14:29Kitware RobotResolutionopen => moved
2016-06-10 14:29Kitware RobotAssigned To => Kitware Robot
2016-06-10 14:31Kitware RobotStatusresolved => closed

Notes
(0042501)
Kitware Robot   
2016-06-10 14:29   
Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page.