mirror of
https://github.com/tldr-pages/tldr.git
synced 2026-08-28 20:11:19 +08:00
5f34f9e406
Update pkg-config.md
634 B
634 B
pkg-config
Provide the details of installed libraries for compiling applications. More information: https://manned.org/pkg-config.
- Get the list of libraries and their dependencies:
pkg-config --libs {{library1 library2 ...}}
- Get the list of libraries, their dependencies, and proper cflags for gcc:
pkg-config --cflags --libs {{library1 library2 ...}}
- Print the version of the linked modules:
pkg-config --modversion {{module1 module2 ...}}
- Compile your code with libgtk-3, libwebkit2gtk-4.0 and all their dependencies:
c++ example.cpp $(pkg-config --cflags --libs gtk+-3.0 webkit2gtk-4.0) -o example