C library for retrieving compiler/linker flags and other metadata
The libpkg-config
library provides a C API for retrieving C-language family
compiler/linker flags and other metadata from pkg-config
files (.pc
). It's
primarily aimed at build system and other similar tools (see the recommended
usage below).
This library is a fork of libpkgconf
from the pkgconf
project.
The fork was motivated by the poor quality of changes in general (see these
three commits for a representative example: 0253fdd
c613eb5
ab404bc
) and disregard for backwards
compatibility in particular (for example, sr.ht/18). While we have
removed a large amount of non-essential functionality and "innovations" as
well as spend some time fixing and cleaning things up, make no mistake it is
still an over-engineered, inscrutable mess and there likely are bugs in the
corner cases. However, we do use it in build2
, which means at
least the recommended usage patterns (see below) are reasonably well
tested. We hope to continue cleaning things up as time permits but a complete
rewrite is also on the cards (in which case it will most likely become a C++
library).
3 Versions