瀏覽代碼

target_link_libraries: Document that new sigs privatize old (#13876)

Explain in the documentation for the legacy signature

 target_link_libraries(foo bar)

that the other signatures like

 target_link_libraries(foo LINK_INTERFACE_LIBRARIES ...)
 target_link_libraries(foo LINK_PRIVATE ...)

will set the LINK_INTERFACE_LIBRARIES target property and therefore make
libraries specified only by the legacy signature private.
Brad King 12 年之前
父節點
當前提交
f032fb904b
共有 1 個文件被更改,包括 3 次插入1 次删除
  1. 3 1
      Source/cmTargetLinkLibrariesCommand.h

+ 3 - 1
Source/cmTargetLinkLibrariesCommand.h

@@ -93,7 +93,9 @@ public:
       "linked to this target will appear on the link line for the other "
       "target too.  "
       "See the LINK_INTERFACE_LIBRARIES target property to override the "
-      "set of transitive link dependencies for a target."
+      "set of transitive link dependencies for a target.  "
+      "Calls to other signatures of this command may set the property "
+      "making any libraries linked exclusively by this signature private."
       "\n"
       "  target_link_libraries(<target> LINK_INTERFACE_LIBRARIES\n"
       "                        [[debug|optimized|general] <lib>] ...)\n"