vuls: init at 0.27.0 (#348530)
[NixPkgs.git] / pkgs / build-support / pkg-config-wrapper / pkg-config-wrapper.sh
blob1d43c8e162ab2319b2feeee099fa2a8a35a0b65b
1 #! @shell@
2 set -eu -o pipefail +o posix
3 shopt -s nullglob
5 if (( "${NIX_DEBUG:-0}" >= 7 )); then
6 set -x
7 fi
9 source @out@/nix-support/utils.bash
11 if [ -z "${NIX_PKG_CONFIG_WRAPPER_FLAGS_SET_@suffixSalt@:-}" ]; then
12 source @out@/nix-support/add-flags.sh
15 set -- @addFlags@ "$@"
17 if (( ${#role_suffixes[@]} > 0 )); then
18 # replace env var with nix-modified one
19 PKG_CONFIG_PATH=$PKG_CONFIG_PATH_@suffixSalt@ exec @prog@ "$@"
20 else
21 # pkg-config isn't a real dependency so ignore setup hook entirely
22 exec @prog@ "$@"