In the context of that particular part of the CMake documentation, it is referring to targets that are not created by add_library() or add_executable(). Targets created by add_custom_target() are not something CMake knows what to do with if you give them to the target_link_libraries() command, since these custom targets may not (and typically won't) correspond to a physical file being created (that's what add_custom_command() is for). So the term *utility target* can be thought of as being a custom target you create for convenience, but not something which actually corresponds to a library or executable. Examples of utility targets that CMake will automatically create for you include things like *all*, *test*, *package*, etc.
On Tue, Jul 26, 2016 at 6:39 AM, Azharuddin Mohammed < [email protected]> wrote: > Hi > > > > CMake Policy CMP0039 ( > https://cmake.org/cmake/help/v3.0/policy/CMP0039.html) mentions that “Utility > targets may not have link dependencies” . Can someone please explain what > does “utility targets” mean ? > > > > Thanks > > > > - > > Azhar > > -- > > 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 > -- Craig Scott Melbourne, Australia http://crascit.com
-- 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
