When searching for an object (.obj) or library (.lib), the linker looks only in the specified directory if a path is indicated. If a path is not specified, the linker looks in the following locations in this order:
If the linker cannot locate a file, it generates an error message and stops linking.
In addition to the libraries you specify, by default the linker searches the IBM C and C++ Compilers runtime libraries defined in your object files at compile time and the system import library, KERNEL32.LIB (Windows) or OS2386.LIB (OS/2).
A response file contains the following information:
FUN.OBJ TEXT.OBJ TABLE.OBJ CARE.OBJ NEWLIBV3.LIB C:\TESTLIB\
The linker links four object files to create an executable file named FUN.EXE. The linker searches NEWLIBV3.LIB before searching the default libraries to resolve references.
To locate NEWLIBV3.LIB and the default libraries, the linker searches the following locations in this order: