Creating the DEF File

The DEF file is a module definition file. The DEF lists the exported DLL functions. A DEF file is an ASCII text file containing one or more module statements that describe various attributes of a DLL. A DLL requires a DEF file to create an import library (LIB) file and an export (EXP) file. The linker uses the import library to build any executable module that uses the DLL, and uses the export file to build the DLL file.

The following is an example of a typical plug-in DEF file. You should change MyPlugIn.dll to the name of your plug-in with the appropriate extension (e.g. MySimpleObject.dlo).

LIBRARY MyPlugIn.dll
EXPORTS
   LibDescription   @1
   LibNumberClasses @2
   LibClassDesc     @3
   LibVersion       @4
SECTIONS
.data READ WRITE