Skip to content

Commit

Permalink
Set PKG_CONFIG_ALLOW_SYSTEM_(CFLAGS|LIBS) by default
Browse files Browse the repository at this point in the history
  • Loading branch information
jasagredo committed Sep 18, 2023
1 parent 470aa2e commit e061b03
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Cabal/src/Distribution/Simple/Program/Builtin.hs
Original file line number Diff line number Diff line change
Expand Up @@ -400,4 +400,11 @@ pkgConfigProgram :: Program
pkgConfigProgram =
(simpleProgram "pkg-config")
{ programFindVersion = findProgramVersion "--version" id
, programPostConf = \_ pkgConfProg ->
let programOverrideEnv' =
programOverrideEnv pkgConfProg
++ [ ("PKG_CONFIG_ALLOW_SYSTEM_CFLAGS", Just "1")
, ("PKG_CONFIG_ALLOW_SYSTEM_LIBS", Just "1")
]
in pure $ pkgConfProg { programOverrideEnv = programOverrideEnv' }
}

0 comments on commit e061b03

Please sign in to comment.