Why does:

Interface Libraries
https://cmake.org/cmake/help/latest/command/add_library.html?highlight=add_library#id3

allow include directories via

target_include_directories(INTERFACE)

but not link_directories

https://cmake.org/cmake/help/latest/prop_dir/LINK_DIRECTORIES.html?highlight=link_directories

which if we look at property scope:

https://cmake.org/cmake/help/latest/manual/cmake-properties.7.html

Why is include_directories at target resolution while link_directories is
at directory resolution.

link_directories is a property on a directory which if I recalled correctly
I complained about many many moons ago (circa 2009) when I first realized
this.  I did not understand this logic then and don't understand this logic
now.  Someone what to give me the recipe for the CMake cool-aid so I can
mix that up, drink it down, and re-read the doc and finally come to terms
with this.  Or could the powers that be redesign CMake to make sense.  At
the time I wrapped this nonsense in a macro and pretended it did not happen
... now I am rewriting my project for "new" CMake and still don't get this.
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to