You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/build/reference/linker-options.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -77,7 +77,7 @@ You can use the [comment](../../preprocessor/comment-c-cpp.md) pragma to specify
77
77
|[/LARGEADDRESSAWARE](largeaddressaware-handle-large-addresses.md)|Tells the compiler that the application supports addresses larger than two gigabytes|
78
78
|[/LIBPATH](libpath-additional-libpath.md)|Specifies a path to search before the environmental library path.|
79
79
|[/LINKREPRO](linkrepro.md)|Specifies a path to generate link repro artifacts in.|
80
-
|[/LINKREPROTARGET](linkreprotarget.md)|Specifies a file name to filter generated link repro artifacts.|
80
+
|[/LINKREPROTARGET](linkreprotarget.md)|Generates a link repro only when producing the specified target.|
Tells the linker to generate a link repro in a specified directory.
10
+
Tells the linker or library tool to generate a link repro in a specified directory.
11
11
12
12
## Syntax
13
13
@@ -20,19 +20,11 @@ The user-specified directory to store the link repro in. Directory names that in
20
20
21
21
## Remarks
22
22
23
-
::: moniker range=">=vs-2019"
23
+
The **/LINKREPRO** option is used to create a *link repro*. It's a set of build artifacts that allow Microsoft to reproduce a problem that occurs at link time, or during library operations. It's useful for problems such as a backend crash involving Link-Time Code Generation (LTCG), an LNK1000 linker error, or a linker crash. The tool produces a link repro when you specify the **/LINKREPRO** linker option, or when you set the `link_repro` environment variable in your command-line build environment. For more information, see the [Link repros](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md#link-repros) section of [How to report a problem with the Microsoft C++ toolset](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md).
24
24
25
-
The **/LINKREPRO** linker option is used to create a *link repro*. It's a set of build artifacts that allow Microsoft to reproduce a problem that occurs at link time. It's useful for problems such as a backend crash involving Link-Time Code Generation (LTCG), an LNK1000 linker error, or a linker crash. The linker produces a link repro when you specify the **/LINKREPRO** linker option, or when you set the `link_repro` environment variable in your command-line build environment.
25
+
Both the **/LINKREPRO** linker option and the `link_repro` environment variable require you to specify an output directory for the link repro. On the command line or in the IDE, specify the directory by using a **/LINKREPRO:**_directory-name_ option. The _directory-name_ you specify may be an absolute or relative path, but the directory must exist. The command-line option overrides any directory value set in the `link_repro` environment variable.
26
26
27
-
Create a link repro to get support for an LTCG crash, a linker crash, or an internal error that happens at link time. For more information, see the [Link repros](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md#link-repros) section of [How to report a problem with the Microsoft C++ toolset](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md).
28
-
29
-
Both the **/LINKREPRO** linker option and the `link_repro` environment variable require you to specify an output directory for the link repro. On the command line or in the IDE, specify the directory by using a **/LINKREPRO:**_directory-name_ option. The _directory-name_ you specify may be an absolute or relative path, but the directory must exist. The command-line option overrides any directory value set in the `link_repro` environment variable. You must also specify the [/OUT](out-output-file-name.md) linker option when you use the **/LINKREPRO** option.
30
-
31
-
For information on how to filter link repro generation on a file name, see the [/LINKREPROTARGET](linkreprotarget.md) linker option. This option can be used to specify a specific target to generate a link repro for. It's useful in complex builds that invoke the linker more than once.
32
-
33
-
::: moniker-end
34
-
35
-
The **/LINKREPRO** option is available starting in Visual Studio 2019 version 16.1.
27
+
For information on how to limit link repro generation to a specific target file name, see the [/LINKREPROTARGET](linkreprotarget.md) option. This option can be used to specify a specific target to generate a link repro for. It's useful in complex builds that invoke the linker or library tool more than once.
36
28
37
29
### To set this linker option in the Visual Studio development environment
38
30
@@ -42,6 +34,8 @@ The **/LINKREPRO** option is available starting in Visual Studio 2019 version 16
42
34
43
35
1. Enter the **/LINKREPRO:**_directory-name_ option in the **Additional Options** box. The _directory-name_ value you specify must exist. Choose **OK** to apply the change.
44
36
37
+
Once you've generated the link repro, open this property page again to remove the **/LINKREPRO** option from your builds.
38
+
45
39
### To set this linker option programmatically
46
40
47
41
- See <xref:Microsoft.VisualStudio.VCProjectEngine.VCLinkerTool.AdditionalOptions%2A>.
Tells the linker to generate a link repro filtered by the specified file name.
10
+
Tells the linker or library tool to generate a link repro only when the target has the specified file name.
11
11
12
12
## Syntax
13
13
@@ -16,23 +16,17 @@ Tells the linker to generate a link repro filtered by the specified file name.
16
16
### Arguments
17
17
18
18
**/LINKREPROTARGET:**_file-name_\
19
-
The user-specified file name to generate the link repro for. File names that include spaces must be enclosed in double quotes. The file name should include the base name and the extension, but not the path.
19
+
The target file name to filter on. A link repro is only generated when the named file is the output target. File names that include spaces must be enclosed in double quotes. The file name should include the base name and the extension, but not the path.
20
20
21
21
## Remarks
22
22
23
-
::: moniker range=">=vs-2019"
23
+
The **/LINKREPROTARGET** option is used to specify a target file name to generate a *link repro* for. A link repro is a set of build artifacts that allow Microsoft to reproduce a problem that occurs at link time, or during library operations. The linker or library tool produces a link repro when you specify the [/LINKREPRO](linkrepro.md) option, or when you set the `link_repro` environment variable in your command-line build environment.
24
24
25
-
The **/LINKREPROTARGET** linker option is used to specify a file name to filter *link repro* generation. A link repro is a set of build artifacts that allow Microsoft to reproduce a problem that occurs at link time. The linker produces a link repro when you specify the [/LINKREPRO](linkrepro.md) linker option, or when you set the `link_repro` environment variable in your command-line build environment.
26
-
27
-
The **/LINKREPROTARGET** linker option is useful in complex builds that invoke the linker more than once. It lets you specify a specific target for the link repro, such as *problem.dll*. This lets you generate the link repro only when you link a specific file.
25
+
The **/LINKREPROTARGET** option is useful in complex builds that invoke the linker or library tool more than once. It lets you specify a specific target for the link repro, such as *problem.dll*. It lets you generate the link repro only when the tool produces a specific file.
28
26
29
27
For more information about how and when to create a link repro, see the [Link repros](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md#link-repros) section of [How to report a problem with the Microsoft C++ toolset](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md).
30
28
31
-
The **/LINKREPRO** and [/OUT](out-output-file-name.md) linker options must be set for the **/LINKREPROTARGET** option to have any effect.
32
-
33
-
::: moniker-end
34
-
35
-
The **/LINKREPROTARGET** option is available starting in Visual Studio 2019 version 16.1.
29
+
The **/LINKREPRO** and [/OUT](out-output-file-name.md) options must be set for the **/LINKREPROTARGET** option to have any effect.
36
30
37
31
### To set this linker option in the Visual Studio development environment
Copy file name to clipboardExpand all lines: docs/build/reference/running-lib.md
+1-7Lines changed: 1 addition & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -38,16 +38,10 @@ If lib.exe fails at runtime, you can use **/ERRORREPORT** to send information to
38
38
39
39
For more information about **/ERRORREPORT**, see [/errorReport (Report Internal Compiler Errors)](errorreport-report-internal-compiler-errors.md).
40
40
41
-
::: moniker range=">=vs-2019"
42
-
43
41
> **/LINKREPRO:**_directory-path_\
44
42
> **/LINKREPROTARGET:**_filename_
45
43
46
-
To help Microsoft diagnose lib.exe crashes and internal errors, you can use the **/LINKREPRO** option. It works the same way as the [/LINKREPRO](linkrepro.md) linker option. The [/LINKREPROTARGET](linkreprotarget.md) option can be used with the **/LINKREPRO** option. It filters on a _filename_, to only generate repro artifacts when lib.exe is used on that file. For more information, see [How to report a problem with the Microsoft C++ toolset](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md).
47
-
48
-
The **/LINKREPRO** and **/LINKREPROTARGET** options are available starting in Visual Studio 2019 version 16.1.
49
-
50
-
::: moniker-end
44
+
To help Microsoft diagnose lib.exe crashes and internal errors, you can use the [/LINKREPRO](linkrepro.md) option. It generates a *link repro*, a set of build artifacts that allow Microsoft to reproduce a problem that occurs during library operations. The [/LINKREPROTARGET](linkreprotarget.md) option can be used with the **/LINKREPRO** option. It only generates link repro artifacts when lib.exe produces the specified file. For more information, see [How to report a problem with the Microsoft C++ toolset](../../overview/how-to-report-a-problem-with-the-visual-cpp-toolset.md).
0 commit comments