Keil Logo

Searching Libraries

The BL51 Linker searches for libraries specified on the command line and for libraries specified in an object module. When a Compiler creates an object module from a high-level-language program (like C) the names of the default libraries are included in that object module. The linker uses the same method to find library files no matter how they are specified.

If the library file includes a path specification, the linker searches for that library only in the specified path. Libraries specified by object modules do not include path specifications.

If a library file does not include a path specification, the linker searches for it in:

  • the current folder,
  • the folders specified with the C51LIB environment variable.

Object files created by the compiler typically contain the names of the required standard libraries. Additional library specifications are not needed unless you want to:

  • include modules from additional libraries,
  • search for libraries in a different location,
  • override use of the default libraries.

Refer to the Input Modules section of the Map File to determine what libraries are included in a program.

  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.