Include a library to GNU / LLVM based project

To add a library to the project:

  1. Open the Project Settings by click to properties button button.

  2. Select the item C/C++ Build  Settings  Tool Settings  C Linker  Libraries.

  3. Click to Add…​ button (add button) in the Library search path input box to add directories containing the library file(s).

  4. Click to Add…​ button (add button) in the Library input box and add library name.

    The name convention for libraries is lib<library name>.a. That means that you do not pass the prefix lib and the extension .a to the linker, just a library name.

ide project settings libraries
Fig. 1. The project settings - Libraries