mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-23 18:52:09 +01:00
In some test cases (but not only) GLib needs to preload libraries when launching executables, however this doesn't work well with ASAN because libasan needs to be the first library to be loaded in such case. We've been ignoring the error so far, using verify_asan_link_order=false ASAN option, but this is not the correct way because it implies that we don't check any pre-loaded library, as we instead should. So in the platforms we know, get the proper sanitizer libraries paths and pre-load them when required. We don't do it for installed tests since the full paths may change in the target system, so ignoring the error is safer. This meson code has been used for various years now in fprintd project to run tests in CI in both fedora and debian-based systems with no issues, so I consider it reliable. In case no preload variables are found the default ignore mode is used