Subject: [bug#75688] [PATCH 0/2] Introduce GUIX_LIBRARY_PATH to replace harmful environment variables

From: 宋文武 <[email-masked]>
Date: Thu, 23 Jan 2025 14:43:22 +0800

Maxim Cournoyer <[email-masked]> writes:

> It's too early for me to say if it could really work, but I'll repeat
> that a priori I'm not too fond of GUIX_LIBRARY_PATH (just the name would
> clash with a GCC env var too) and custom logic that'd need to be
> maintained in the software (we'd need to patch the software to have
> GUIX_* variables anyway but the resulting patch would be trivial); I
> think I'd rather have multiple, explicit environment variables computed
> by search paths.

v2 patches sent to use multiple variables, replace the use of wrapper
scripts in glib-or-gtk-build-system with 'search-paths.d' files.
Patches for glib, gdk-pixbuf and gtk(s) while not trivial, seems
reasonable to me..

> Just to make sure, GUIX_* variables would be honored *on top* of their
> non GUIX_ prefixed (stock) variants, right?  E.g. we wouldn't want GCC
> to stop honoring LIBRARY_PATH even if we add GUIX_LIBRARY_PATH, as that
> would confuse users.

Yes, and non prefixed ones have higher priority than GUIX_ ones, to
allow overrides.

The patches require mass rebuilds due to glib-or-gtk-build-system ->
meson/cmake/rust, etc.  I haven't test them, but show be fine for review
now, if it seems fine, I could work on qt.

Also nix have the same issue, http://github.com/nixos/nixpkgs/issues/60260
Maybe we could share the maintaince of patches with them somehow.

Thanks.