To control running the linker from the IDDE, set options in the Linker subpage on the Build page of the IDDE's Project Settings dialog box.
OPTLINK derives its spectacular speed from being written entirely in hand- tuned assembly language, making maximal use of multithreading and processor scheduling. It does full links faster than more pedestrian linkers do incremental links.
OPTLINK combines object (.obj) and library (.lib) files into a single file that is executable by the operating system. OPTLINK can optionally create memory maps and symbol tables that are useful for debugging.
OPTLINK works with modules in Intel OMF format (.obj file), including those generated by standard assemblers, compilers and standard object module libraries. The output files produced have all address assignments resolved and are in one of these standard formats:
These features combine to create an environment in which you can create large programs, despite apparent memory constraints.
set OPTLINKS=/IG
In all modes of operation, OPTLINK commands, switches and parameters are the same.
LINK obj[,out[,map[,lib[,def[,res]]]]]
OPTLINK parameters include the following:
Wild-card characters "?" and "*" to specify multiple files are allowed. If specific names are preceded or followed by wild-card references, those modules specifically named will not be included twice. At the end of the input list, use specific data or a "+" character to invoke the default choices. If neither is supplied, operation switches to the interactive mode, and OPTLINK prompts for the remaining inputs. The "#" character tells OPTLINK to ignore the rest of the comment characters following on that line.
The lib entry may be either a single file name or a pathname (with trailing "\") to a directory containing the libraries.
OPTLINK searches library files in the order that they are presented to it: that is, those named on the command line, and then those referenced by embedded commands in object modules. To locate each library file for which no path is specified, OPTLINK first searches the current directory followed by any paths specified in the LIB variable, and finally any paths named in the command line.
C> LINK DUMP; OPTLINK Copyright (C) Digital Mars 1989-2001. All rights reserved.
If the .obj file does not exist in the current directory or in any of the paths supplied by the environment variables, OPTLINK sends an error message:
C> LINK DUMPER; OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. DUMPER.OBJ Error 2: File Not Found DUMPER.OBJ
C> LINK DUMP,,MYMAP; OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. C> LINK DUMP,,MYMAP OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. Libraries and Paths: (.lib): Definition File: (.def): Resource Files: (.res)
C> LINK OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. OBJ Files: (.obj): curset Output File: (curset.exe): Map File: (.map): Libraries and Paths: (.lib): Definition File: (.def): Resource Files: (.res)
C> LINK OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. OBJ Files: (.obj): file1+ # this is the first object file OBJ Files: (.obj): file2+ OBJ Files: (.obj): file3 # this is the last Output File: (file1.exe): myfile Map File: (.map): Libraries and Paths: (.lib): mylib Definition File: (.def): Resource Files: (.res)
C> LINK OPTLINK Copyright (C) Digital Mars 1989-2001 All rights reserved. OBJ Files: (.obj): file1 file2 file3 Output File: (file1.exe): myfile Map File: (.map): Libraries and Paths: (.lib): mylib Definition File: (.def): Resource Files: (.res)
OPTLINK uses the following syntax for indirect file operation:
LINK @indirfile
DUMP NEWEXE MYMAP;
LINK @LNKLST LINK DUMP,NEWEXE,MYMAP;
Note: It is possible for a valid file name to actually begin with the "@" character. To keep such a file from being erroneously recognized by OPTLINK as an indirect response file, enclose the entire name of the file in quotation marks.
The file name may be preceded by a pathname, which may be either absolute or relative and may include a drive specifier. If no path is specified, OPTLINK searches only the current working directory for the file or creates it in the current working directory. If a drive is specified, but no path, only the current directory for the specified drive is used.
LINK UTILITY; >LINK.LOG
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル