 | BL51 User's Guide |  |
|
|
| NODEFAULTLIBRARY Linker Directive| Abbreviation | NLIB | | Arguments | None. | | Default | C run-time libraries are included in the linkage. | | µVision | Options — BL51 Misc — Misc Controls. | | Description | The NODEFAULTLIBRARY directive disables automatic linkage with the C run-time libraries. By default, the linker includes required run-time libraries (based on memory model and floating-point usage). If NODEFAULTLIBRARY is used, C run-time libraries must be manually included in the linkage. For example:
BL51 inputlist, CxxFPS.LIB, CxxS.LIB NODEFAULTLIBRARY
This example includes the SMALL memory model library (CxxS.LIB) and the SMALL floating-point library (CxxFPS.LIB). If the program contains no floating-point math operations CxxFPS.LIB should not be included in the linkage. Note - The C51LIB environment variable specifies the location of library files. Typically, this is set to \KEIL\C51\LIB but you may change it using the DOS SET command. The linker looks in this folder for the C run-time libraries. If you use the µVision IDE, the location of the run-time libraries is set automatically. You may change it in the Project — File Extensions, Books, and Environment dialog.
- If no environment variable is set, the linker searches for libraries in exepath/../LIB which corresponds to the location for library files in a default installation.
| | Example |
BL51 file1.obj NODEFAULTLIBRARY
|
|
|