Show: Delphi C++
Display Preferences

Link object file (Delphi)

From RAD Studio
Jump to: navigation, search

Go Up to Delphi Compiler Directives (List) Index

Type

Parameter

Syntax

{$L filename} {$LINK filename}

Scope

Local



Remarks

The $L parameter instructs the compiler to link the named file with the program or unit being compiled. The $L directive is used to link with code written in other languages for procedures and functions declared to be external. The format of object file recognized by the Delphi compiler is depending on target platform. For 32-bit Windows or OSX, the named file must be an Intel relocatable object file (OMF86) or 32-bit COFF format object file. For 64-bit Windows, 64-bit COFF can be recognized. The default extension for filename is .OBJ. If filename does not specify a directory path, then, in addition to searching for the file in the same directory as the current module, Delphi searches in the directories specified in the Search path input box on the Directories/Conditionals page of the Project|Options dialog box (or in the directories specified in the -O option on the command line).

To specify a file name that includes a space, surround the file name with single quotation marks: {$L 'My file'}.

For further details about linking with assembly language, see online Help.

Personal tools
RAD Studio 10.2 Tokyo
In other languages
Previous Versions
Assistance