The table below lists the options that you can specify with the ilib command.
Options are not case sensitive, so you can specify them in lower-, upper-, or mixed-case. You can also substitute a dash for the slash preceding the option. For example, -freeFormat is equivalent to /FREEFORMAT.
You can specify options in either short or long form. For example, /f, /Fr, and /free are equivalent to /FREEFORMAT. The shortest recognized form is shown in the detailed description of each option.
The detailed description of each option follows:
| Syntax | Short Form | Default |
|---|---|---|
| /? /HELP |
/H |
None |
Specify /? or /Help to display a list of valid ILIB options.
| Syntax | Short Form | Default |
|---|---|---|
| /BACKUP /NOBACKUP |
/BA /NOBA |
/BACKUP |
Specify /NOBACKUP to stop ilib from making a back up copy of an existing static library before overwriting it. For the back up, ilib uses the base name of the library and the file extension .bak. For example, if the library being modified is mylib.lib and a backup is requested, ilib creates mylib.bak in the current directory.
If ilib creates a backup file, it removes that file just before terminating.
| Syntax | Short Form | Default |
|---|---|---|
| /BROWSE /NOBROWSE |
/BR /NOBR |
/BROWSE |
Use /BROWSE to include information from the output library that is required for the Browser from earlier versions of VisualAge C++ for OS/2 3.0 and IBM C and C++ Compilers 3.6. This information is not used by any part of the current VisualAge C++ product.
Use /NOBROWSE to exclude this browse information from the output library.
| Syntax | Short Form | Default |
|---|---|---|
| /DEF:fileName | /DEF:fileName | None |
You can include this option if you are supplying a module definition (.def) file as input. It is not required because ilib recognizes .def files that are named as input files, from their content.
Module definition files were required to build a DLL with previous versions of VisualAge C++ and predecessor products.
| Syntax | Short Form | Default |
|---|---|---|
| /EXTDICTIONARY /NOEXTDICTIONARY |
/EXTD /NOE |
/EXTDICTIONARY |
Use /NOEXTDICTIONARY to disable generation of the extended dictionary.
The extended dictionary is a table that resolves cross-references between modules in the library. It increases the linking speed by removing the need to to look through all the object modules and libraries to resolve external references. However, using an extended dictionary requires more memory. The space reserved for the extended dictionary is limited to 64K. If ilib reports an out-of-memory error, you may want to use this option. As an alternative, you can split large libraries into smaller libraries to use in linking.
| Syntax | Short Form | Default |
|---|---|---|
| /FREEFORMAT /NOFRREEFORMAT |
/F /NOFR |
/FREEFORMAT |
Use the /NOFREEFORMAT option if you are specifying options and other input to ilib using the fixed format required by VisualAge C++ for OS/2 3.0 and earlier. By default, you can specify ilib input arguments any number of times and in any order.
When you use either of these options, you must place /FREEFORMAT or /NOFREEFORMAT immediately following ilib on the command line, or as the first argument in the ILIB environment variable.
| Syntax | Short Form | Default |
|---|---|---|
| /GENDEF[:fileName] /gd[:fileName] |
/GEND[:fileName] /gd[:fileName] |
None |
Use the /GENDEF option to create a module definition (.def) file. If you omit the file name, the module definition file has the same base name as the first input file and the extension .def. You must also supply one of the following types of input files:
Module definition files were used when building a DLL with previous versions of VisualAge C++ and predecessor products.
| Syntax | Short Form | Default |
|---|---|---|
| /GENIMPLIB[:fileName] /gi[:fileName] |
/GENI[:fileName] /gi[:fileName] |
None |
Use
the /GENIMPLIB option on OS/2 to create an import library.
Use
the /GENIMPLIB option on Windows to create an import library and
an export object (.exp) file. Export object files were required
to build a DLL with VisualAge for C++ for Windows version 3.5 and IBM C and C++ Compilers 3.6.
If you omit the file name, the import library file has the same base name as the first input file and the extension .lib. You must supply one of the following types of input files:
You should not need to use this option because import libraries are created automatically when you create a DLL with an VisualAge C++ build.
| Syntax | Short Form | Default |
|---|---|---|
| /LIST[:fileName] | /L[:fileName] | None |
Use the /LIST option to produce a file that lists the contents of a static library. If you do not specify the name of the list file, ilib produces a file with the same base name as the input library and with the file extension .lst. Do not specify a path for the list file. It is placed in the current directory.
| Syntax | Short Form | Default |
|---|---|---|
| /OUT[:fileName] | /O[:fileName] | None |
Use the /OUT option when you are creating a new static library or import library or updating an existing static library. If you do not specify a file name, ilib uses the base name of the first input file and the file extension .lib.
You can combine libraries or add, replace, and remove modules in a library with this option. You can also combine these activities in one command, as in the following line:
ilib /out pets.lib cats.obj /extract:dogs /remove:birds
This command modifies the library pets.lib by creating an output file pets.lib that contains the object modules in the existing pets.lib and cats.obj. At the same time, it copies the module dogs from the library into the current directory and deletes the module birds from the library.
| Syntax | Short Form | Default |
|---|---|---|
| /QUIET, /NOQUIET /LOGO /NOLOGO |
/Q /NOQ /LO /NOL |
/NOQUIET /LOGO |
Use the /QUIET or /NOLOGO options to suppress the ilib copyright notice. /NOQUIET is equivalent to /LOGO, and provides the default behavior of ilib, which is to output copyright information at the start of a run.
| Syntax | Short Form | Default |
|---|---|---|
| /WARN[:msgnum[,msgnum,...] /NOWARN[:msgnum,msgnum,...] |
W]:msgnum] /NOW]:msgnum] |
Output all messages. |
Use the /WARN option to enable printing of the message number specified in the msgnum parameter.
![]()
Static and Dynamic
Libraries
Maintaining Static
Libraries
.def and .exp Files
are Obsolete
Calling
Conventions
![]()
Build Static Libraries
Create Module Definition
Files
Create an Import Library
and Export Object
List the Contents of a
Static Library
Combine Static Libraries
Add an Object Module to
a Static Library
Replace an Object Module
in a Static Library
Extract an Object Module
from a Static Library
Remove an Object Module
from a Static Library
