diff options
| author | Jake Forster <jakecameron.forster@gmail.com> | 2025-07-04 17:11:30 +0930 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2025-09-25 09:35:56 +0100 |
| commit | ebeb9707d5030f2838ad3030ee373cbbd6d560bd (patch) | |
| tree | 56e74037d6582fb166c31818ebe729ab722df25c /gnu/packages/python-xyz.scm | |
| parent | d1775507d1cfe55e7b319bee7f002a9aca7b0034 (diff) | |
gnu: python-matplotlib: Patch dlopen so MPLBACKEND is not overridden.
Fixes <https://issues.guix.gnu.org/70687>.
In Python, importing 'matplotlib.pyplot' sets the backend used by Matplotlib
to Agg unless it was set to WebAgg or nbAgg. This is because it incorrectly
determines that no event loop can be started due to a failed dlopen call for
'libX11.so.6'. This is fixed by patching the dlopen path.
* gnu/packages/python-xyz.scm (python-matplotlib) [arguments]
<#:phases>: Add 'patch-dlopen.
Change-Id: I3e45c9a2921374e3b16cfcbd8e3e1e91780da306
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Diffstat (limited to 'gnu/packages/python-xyz.scm')
| -rw-r--r-- | gnu/packages/python-xyz.scm | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 64edddcd2b..724efd051b 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -11424,6 +11424,11 @@ reason=\"unknown minor image differences\")\n" match))) ;; non-deterministically when run in parallel (see: ;; https://github.com/matplotlib/matplotlib/issues/22992). "lib/matplotlib/tests/test_compare_images.py")))) + (add-after 'unpack 'patch-dlopen + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "src/_c_internal_utils.c" + (("libX11.so.6") + (search-input-file inputs "lib/libX11.so.6"))))) (add-before 'build 'configure-environment (lambda* (#:key inputs #:allow-other-keys) ;; Fix rounding errors when using the x87 FPU. |
