- Qbs Manual
- Qbs 2.1.0

# LibraryProbe

Locates library files outside the project. More...

Inherits: | PathProbe

- List of all members, including inherited members

## Detailed Description

On Windows, searches for library files within directories specified by the `PATH` environment variable.

On Unix, searches for library files within directories specified by the `LIBRARY_PATH` environment variable, as well as in `"/usr/lib"` and `"/usr/local/lib"`.

On Linux, also searches in platform-specific directories, such as `"/usr/lib64"` and `"/usr/lib/x86_64-linux-gnu"`.

For example, LibraryProbe can be used to search for a `zlib` library as follows:

     import qbs.Probes

     CppApplication {
         Probes.LibraryProbe {
             id: zlibProbe
             names: "z"
         }
         cpp.libraryPaths: zlibProbe.found ? [zlibProbe.path] : []
         cpp.dynamicLibraries: zlibProbe.found ? [zlibProbe.names] : []
         files: 'main.cpp'
     }