summaryrefslogtreecommitdiff
path: root/Source/cmTargetLinkLibrariesCommand.h
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2010-12-15 12:18:59 -0500
committerBrad King <brad.king@kitware.com>2010-12-15 12:18:59 -0500
commit999ce0aa9c3fe2def05bde37ffbff627b2df8235 (patch)
treee6c4b7eeb72e6ea016e36162d5e0007e459dcc83 /Source/cmTargetLinkLibrariesCommand.h
parenta14a8562ea5f321b0a8f6f61f4c457da298825c5 (diff)
downloadcmake-999ce0aa9c3fe2def05bde37ffbff627b2df8235.tar.gz
Document target_link_libraries target scope (#11058)
The target_link_libraries command requires its first argument to be a target in the current directory. Document this and update the error message to be more specific. While at it, format the error message with a call stack.
Diffstat (limited to 'Source/cmTargetLinkLibrariesCommand.h')
-rw-r--r--Source/cmTargetLinkLibrariesCommand.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmTargetLinkLibrariesCommand.h b/Source/cmTargetLinkLibrariesCommand.h
index 43a0d7ce39..ce57df7f2a 100644
--- a/Source/cmTargetLinkLibrariesCommand.h
+++ b/Source/cmTargetLinkLibrariesCommand.h
@@ -62,6 +62,10 @@ public:
" target_link_libraries(<target> [item1 [item2 [...]]]\n"
" [[debug|optimized|general] <item>] ...)\n"
"Specify libraries or flags to use when linking a given target. "
+ "The named <target> must have been created in the current directory "
+ "by a command such as add_executable or add_library. "
+ "The remaining arguments specify library names or flags."
+ "\n"
"If a library name matches that of another target in the project "
"a dependency will automatically be added in the build system to make "
"sure the library being linked is up-to-date before the target links. "