retitle 57392 Mes has overly-generic MES_PREFIX search path thanks On 19-09-2022 13:17, Ekaitz Zarraga wrote: > Hi, > > I have a package that depends on `mes`. > > When I build it with `guix build $package -K` and I jump to the resulting build directory, the `environment_variables` file looks like this: > > ``` > [...] > export MES_PREFIX="/gnu/store/hy6abswwv4d89zp464fw52z65fkzr7h5-perl-5.34.0/" > ``` > > The `MES_PREFIX` is set to Perl's installation directory, which is also the first element in `LIBRARY_PATH`. > > If I change the order of the package inputs the order of the `LIBRARY_PATH` changes, which is not important, but the first element of `LIBRARY_PATH` is always the one in the `MES_PREFIX`. This doesn't look like the proper behavior: it should always be /gnu/store/*-mes-* Looking at the search paths of 'mes', it has (search-path-specification (variable "MES_PREFIX") (separator #f) (files '(""))))) so it 'accept's _all_ the store items. As such, I've renamed the issue (if you think the new name is inappropriate, feel free to rename it back.) How about, instead of having a $MES_PREFIX environment variable and search path, substitute* uses of MES_PREFIX to #$output in a phase? Greetings, Maxime.