Skip to content

Latest commit

 

History

History
43 lines (27 loc) · 1.71 KB

def-specify-module-definition-file.md

File metadata and controls

43 lines (27 loc) · 1.71 KB
description title ms.date f1_keywords helpviewer_keywords ms.assetid
Learn more about: /DEF (Specify module-definition file)
/DEF (Specify module-definition file)
09/09/2022
VC.Project.VCLinkerTool.ModuleDefinitionFile
/def
module definition files, specifying
DEF linker option
-DEF linker option
module definition files
/DEF linker option
6497fa68-65f0-48ca-8f66-b87166fc631a

/DEF (Specify module-definition file)

Specifies a module-definition file to the linker.

Syntax

/DEF:filename

Arguments

filename
The name of a module-definition file (.def) to be passed to the linker.

Remarks

The /DEF linker option passes a module-definition file (.def) to the linker. Only one .def file can be specified to LINK. For details about .def files, see Module-definition files.

To specify a .def file from within the development environment, add it to the project along with your other source files and then specify the file in the project's Property Pages dialog.

To set this linker option in the Visual Studio development environment

  1. Open the project's Property Pages dialog box. For more information, see Set compiler and build properties.

  2. Select the Configuration Properties > Linker > Input property page.

  3. Modify the Module Definition File property. Choose OK or Apply to save your changes.

To set this linker option programmatically

  • See xref:Microsoft.VisualStudio.VCProjectEngine.VCLinkerTool.ModuleDefinitionFile%2A.

See also

MSVC linker reference
MSVC Linker Options