cabal
cabal copied to clipboard
Cabal should respect PKG_CONFIG
Describe the bug
Cabal should probably respect the PKG_CONFIG
environment variable, rather than hard-coding the name "pkg-config", as done in, e.g., Distribution.Simple.Program.Builtin. For instance, mingw
packages are moving to use pkgconf, which leads to trouble with Cabal, as pkg-config
and pkgconf
cannot both be installed.
If memory serves me, PKG_CONFIG
env var is used by other package managers, besides Cabal. Thus, relying on it here could be problematic.
Is that env var documented as a standard anywhere or is it just widespread convention?
I can't recall. Sorry!
FreeBSD also uses pkgconf
but we also install the pkg-config
symlink pointing to pkgconf
. Maybe MinGW should do the same?
If an utility is intended to be a drop-in replacement and not intended to be coinstalled, I'd rather fix it on the packaging side.