From 35906864bbb3a4dedab8ccefc1ecaf2a95ad00fb Mon Sep 17 00:00:00 2001 From: Alik Aslanyan Date: Wed, 7 Jun 2023 18:41:42 +0400 Subject: [PATCH 1/2] Clarify documentation regarding `+bundle` linkage modifier --- src/doc/rustc/src/command-line-arguments.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/doc/rustc/src/command-line-arguments.md b/src/doc/rustc/src/command-line-arguments.md index 3be4382b0a3aa..db470ab41174e 100644 --- a/src/doc/rustc/src/command-line-arguments.md +++ b/src/doc/rustc/src/command-line-arguments.md @@ -62,11 +62,15 @@ attribute or on the command-line, it will link a dynamic library if available, otherwise it will use a static library. If the kind is specified on the command-line, it will override the kind specified in a `link` attribute. +Note that if you don't specify the `KIND`, the default linkage modifiers won't be applied. +For instance, [`+bundle` linkage modifier][bundle-modifier] won't be used in conjunction with static library by default. + The name used in a `link` attribute may be overridden using the form `-l ATTR_NAME:LINK_NAME` where `ATTR_NAME` is the name in the `link` attribute, and `LINK_NAME` is the name of the actual library that will be linked. [link-attribute]: ../reference/items/external-blocks.html#the-link-attribute +[bundle-modifier]: #linking-modifiers-bundle ### Linking modifiers: `whole-archive` From f3266a865b2345d5532784eda6c695ce95900001 Mon Sep 17 00:00:00 2001 From: Alik Aslanyan Date: Tue, 27 Jun 2023 19:03:08 +0400 Subject: [PATCH 2/2] Update src/doc/rustc/src/command-line-arguments.md Co-authored-by: David Wood --- src/doc/rustc/src/command-line-arguments.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/rustc/src/command-line-arguments.md b/src/doc/rustc/src/command-line-arguments.md index db470ab41174e..f2a07b13ff80e 100644 --- a/src/doc/rustc/src/command-line-arguments.md +++ b/src/doc/rustc/src/command-line-arguments.md @@ -62,7 +62,7 @@ attribute or on the command-line, it will link a dynamic library if available, otherwise it will use a static library. If the kind is specified on the command-line, it will override the kind specified in a `link` attribute. -Note that if you don't specify the `KIND`, the default linkage modifiers won't be applied. +If you don't specify `KIND`, no linkage modifiers will be applied. For instance, [`+bundle` linkage modifier][bundle-modifier] won't be used in conjunction with static library by default. The name used in a `link` attribute may be overridden using the form `-l