chore: get mpl 3.9 building

This commit is contained in:
Phillip Cloud 2024-05-25 12:15:37 -04:00
parent 69e4164b7d
commit 63a5819cb0
No known key found for this signature in database
GPG key ID: D908212070FD785E

View file

@ -1544,6 +1544,7 @@ lib.composeManyExtensions [
inherit (pkgs) tk tcl wayland qhull; inherit (pkgs) tk tcl wayland qhull;
inherit (pkgs.xorg) libX11; inherit (pkgs.xorg) libX11;
inherit (pkgs.darwin.apple_sdk.frameworks) Cocoa; inherit (pkgs.darwin.apple_sdk.frameworks) Cocoa;
mpl39 = lib.versionAtLeast prev.matplotlib.version "3.9.0";
in in
{ {
XDG_RUNTIME_DIR = "/tmp"; XDG_RUNTIME_DIR = "/tmp";
@ -1569,10 +1570,15 @@ lib.composeManyExtensions [
++ lib.optionals enableQt [ final.pyqt5 ] ++ lib.optionals enableQt [ final.pyqt5 ]
; ;
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ dontUseMesonConfigure = mpl39;
pkg-config
] ++ lib.optionals (lib.versionAtLeast prev.matplotlib.version "3.5.0") [ nativeBuildInputs = old.nativeBuildInputs or [ ] ++ [ pkg-config ];
final.setuptools-scm
mesonFlags = lib.optionals mpl39 [
"-Dsystem-freetype=true"
"-Dsystem-qhull=true"
# broken for linux in matplotlib 3.9.0
"-Db_lto=false"
]; ];
# Clang doesn't understand -fno-strict-overflow, and matplotlib builds with -Werror # Clang doesn't understand -fno-strict-overflow, and matplotlib builds with -Werror