Open lu-zero opened 2 years ago
Do you have some examples how this would be used in practice?
in rav1e we tripped in a situation in which an user sets PKG_CONFIG_PATH
to a cross-build path and somehow it trips since our build.rs that requires to link host stuff.
In would be good to have a mean to have different search paths per target to avoid the or even just have a HOST/TARGET split.
Ideally you would invoke pkg-config yourself with the right env vars, instead of having pkg-config understand build / host etc. This also allows you to extend the same to other dependency search tools like cmake and qmake. This is exactly what meson does: --build.pkg-config-path
--build.cmake-prefix-path
vs --pkg-config-path
--cmake-prefix-path
.
even just have a HOST/TARGET split.
Looks like pkg-config-rs, used by system-deps already support HOST/TARGET env variables. Would this do or what are you looking for exactly?
Probably it does, I opened the issue to forward the concern a rav1e user had.
It should mimic cargo use of triples for the compiler env.