pkg.soopen package index

project history

The history of pkgconf

pkgconf is a cross-platform implementation and extension of the pkg-config model for discovering development libraries and calculating their compiler and linker flags.

history

Project history and usage

pkgconf is a cross-platform implementation and extension of the pkg-config model for discovering development libraries and calculating their compiler and linker flags.

Project history

pkgconf emerged as an alternative implementation of the pkg-config interface and developed into a broader package compiler and linker metadata toolkit. Upstream describes it as a functional superset of freedesktop.org pkg-config while explicitly declining bug-for-bug compatibility.

The project expanded beyond its command-line frontend to provide libpkgconf and SBOM-oriented utilities. Its current build uses Meson, with a lightweight Makefile option for pkg-config-only bootstrap use and Muon support where Python is unavailable.

Adoption history

pkgconf has been adopted across many operating-system package ecosystems and is frequently exposed through a pkg-config-compatible command name. The supplied package facts list Alpine, Homebrew, Debian, Fedora-family, MacPorts, Nix, Arch, Ubuntu, openSUSE, Scoop, and WinGet packages.

The upstream project deliberately leaves creation of the pkg-config symlink to operating-system vendors, making the compatibility command an explicit packaging-policy decision.

How it is used

Build systems and developers query pkgconf with package names to obtain compiler and linker flags derived from installed .pc metadata. It can be invoked directly as pkgconf or, when the operating-system vendor provides a symlink, as pkg-config.

Users should depend on stable query interfaces rather than parsing --debug output. Correct dependency declarations in .pc files allow pkgconf to flatten dependency graphs and reduce overlinking.

Why package nerds care

pkgconf sits on a critical seam between package metadata and native compilation. It resolves .pc module relationships and emits the include paths, compiler options, and linker flags consumed by build systems.

Compared with the original pkg-config implementation, pkgconf emphasizes graph-based dependency solving, large dependency graphs, virtual packages, Conflicts handling, and avoiding unnecessary overlinking. It also exposes libpkgconf for integration into compilers and IDEs and includes tools for generating SPDX software bills of materials.

Timeline

  • Project established as an alternative implementation of the pkg-config interface.
  • The project added libpkgconf for embedding metadata resolution in compilers, IDEs, and other tools.
  • Later development added bomtool and spdxtool for SPDX-oriented SBOM generation.
  • Current releases use Meson and retain lightweight bootstrap paths through Makefile.lite and Muon.

Related projects

  • freedesktop.org pkg-config is the original implementation and compatibility reference.
  • libpkgconf exposes pkgconf functionality to other developer tools.
  • bomtool and spdxtool generate SPDX-family software bills of materials from pkg-config module graphs.
  • Meson is the recommended upstream build system; Muon is supported for bootstrap environments.

Sources

Install pkgconf