Skip to content

Latest commit

 

History

History
54 lines (40 loc) · 2.74 KB

File metadata and controls

54 lines (40 loc) · 2.74 KB
title -LN (Create MSIL Module) | Microsoft Docs
ms.custom
ms.date 11/04/2016
ms.reviewer
ms.suite
ms.technology
cpp-tools
ms.tgt_pltfrm
ms.topic article
f1_keywords
/LN
dev_langs
C++
helpviewer_keywords
-LN compiler option [C++]
/LN compiler option [C++]
ms.assetid 4f38f4f4-3176-4caf-8200-5c7585dc1ed3
caps.latest.revision 13
author corob-msft
ms.author corob
manager ghogen
ms.workload
cplusplus

/LN (Create MSIL Module)

Specifies that an assembly manifest should not be inserted into the output file.

Syntax

/LN  

Remarks

By default, /LN is not in effect (an assembly manifest is inserted into the output file).

When /LN is used, one of the /clr (Common Language Runtime Compilation) options must also be used.

A managed program that does not have an assembly metadata in the manifest is called a module. If you compile with /c (Compile Without Linking) and /LN, specify /NOASSEMBLY (Create a MSIL Module) in the linker phase to create the output file.

You may want to create modules if you want to take a component-based approach to building assemblies. That is, you can author types and compile them into modules. Then, you can generate an assembly from one or more modules. For more information on creating assemblies from modules, see .netmodule Files as Linker Input or Al.exe (Assembly Linker).

The default file extension for a module is .netmodule.

In [!INCLUDEvcprvc] releases before Visual C++ 2005, a module was created with /clr:noAssembly.

The Visual C++ linker accepts .netmodule files as input and the output file produced by the linker will be an assembly or .netmodule with no run-time dependence on any of the .netmodules that were input to the linker. For more information, see .netmodule Files as Linker Input.

To set this compiler option in the Visual Studio development environment

To set this compiler option programmatically

  • This compiler option cannot be changed programmatically.

See Also

Compiler Options
Setting Compiler Options