[CMake] Interface Libraries allow include directories but not link directories.. Why?
Brian Davis
bitminer at gmail.com
Tue Aug 22 12:00:57 EDT 2017
Upon further reflection the abs paths for every lib is absolutely not
defensible.
1) Pass only the short lib name to target_link_libraries
2) Add absolute path to future target_link_directories if you must
Then it's one (1) long path on the command line string and not N long paths
fore each lib
I seriously can't believe in 2017 I am actually having this conversation.
Did I miss something here or does Kitware really mean to have package
maintainers spec
target_link_libraries(
targ
INTERFACE
C:\projects\lib1\install\lib\lib1
C:\projects\lib1\install\lib\lib2
C:\projects\lib1\install\lib\lib3
)
and not
target_link_libraries(
targ
INTERFACE
lib1
lib2
lib3
)
target_link_directories( targ INTERFACE C:\projects\lib1\install\lib )
Does Kitware understand the length problem on command line tools and get
the difference I am trying to convey here? As far as cmd line would go
"one of these is not like the other", but would have same effect. If
implemented for projs like ITK maybe I could build is a place other than C:\
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20170822/6e47e26d/attachment.html>
More information about the CMake
mailing list