opam icon indicating copy to clipboard operation
opam copied to clipboard

Allow to have filters for setenv

Open mseri opened this issue 1 year ago • 2 comments

It is increasingly useful, especially for conf packages and packages linking against external libraries, to be able to set specific env variables (e.g. PKG_CONFIG_PATH but not just that) specific for the os and the distribution in order to compile successfully. Would it be possible to have the full set of filtes available also for setenv?

mseri avatar Jan 18 '24 11:01 mseri

See as an example the use done here: https://github.com/ocaml/opam-repository/pull/25076

mseri avatar Jan 18 '24 11:01 mseri

The mechanism itself can be added with an x- field (not recommended), but for the full feature, it needs a change in the opam file syntax, that can't be done before 3.0.

rjbou avatar Jan 18 '24 11:01 rjbou