fink / fink-distributions

Package descriptions and patches for Fink
25 stars 38 forks source link

upgrade matplotlib-py #671

Open nieder opened 4 years ago

nieder commented 4 years ago

Our current matplotlib-py-1.5.3 is very old (sep 9, 2016)

Latest release is 3.3.2 (Sep 15, 2020). The latest version that supports py27 is 2.2.5 (Feb 2, 2020).

Currently, 1.5.3 fails building the qt5agg backend (unclear if our Qt5-5.7 is too old or too new for v1.5.3).

Newer matplotlib packages will need some sort of update to (at least)

This is a tracking bug mostly to remember what needs to be done @schwehr

dmacks commented 4 years ago

qhull is @akhansen and at least the current packages of it have no external deps, so should be an ~easy one-off update.

pycairo needs a newer cairo, but that's only on top of the freetype/fontconfig stack, not glib/gtk.

nieder commented 4 years ago

Just tested, and qhull-2020.2 is a simple cmake build with libN=8.

I think the pycairo updates are only needed for specific frontends.

schwehr commented 4 years ago

I haven't put any time into fink or even used it in more than 6 months. Anyone is welcome to take any of my packages.

nieder commented 4 years ago

See #672 for qhull update

dhomeier commented 4 years ago

I've got 3.3.2 to build with Qt4[Agg], Qt5[Agg], Tk[Agg], WX[Agg], PDF, PS, SVG and Agg backends, using the PyQt5 update in #675 (bringing a bunch of further Qt5 updates with it), and our wxpython400 for WX. Qt4 support will be discontinued within the next 2 minor versions, so it would not be worth much effort on debugging any potential build issues. Pycairo is required for the GTk3 backend, but not essential. Will open a PR with the remaining -py dependencies later.

nieder commented 4 years ago

@dhomeier while the qt5.15 stuff is figured out to get 3.3.2, I've tried to get 2.2.5 (last one to support py27). Should I open a PR for that to at least not have an ancient matplotlib? I had to turn off qt5agg and wxagg since they were failing (probably requires newer than qt5.7), and I'm getting a failing test that seems to be a python issue.

dhomeier commented 4 years ago

@nieder I have also built matplotlib-py27-2.2.5 with qt5agg, but without wxagg, but that was with the qt5.15 update. Trying to rebuild with the existing qt5 now, but found that even enabling Qt4 needed at least an update of the sip-py*. That was however still possible on top of the qt5.7-based PyQt5/, so I could go also push the py27 version; still waiting for a py37 build to complete. But if you want to go ahead with your version that's fine as well.

nieder commented 4 years ago

See #677. I also had to kill wxagg.

dhomeier commented 4 years ago

See #677. I also had to kill wxagg.

Thanks, I'll make a closer comparison of the info files. For reference, my branch ist now at https://github.com/dhomeier/fink-distributions/tree/matplotlib2%2B3 . Strangely the py27 version seemed to say in the build messages it could not detect a wx installation, but in the end does build and link against wxpython400 (and works with wxagg). Qt turned out quite a bit trickier – 3.x obviously needs a sip.so library from at least 4.19.20-something, but that SIP version in turn fails to build our PyQt4/PyQt5 versions (I actually could not locate any source downloads for older SIP 4 versions, among the tarballs I still had left in my /sw/src, 4.18.17 was the last one that would build pyqt[45]-mac-py 5.11 against Qt5 5.7, and 4.19.22 the first one to build PyQt[45]/sip.so modules implementing the "API v12.6" that mpl's PyQt[45].QtCore modules require (4.19.13-17 provide "API v12.0 to v12.5"). Fortunately since @danielj7 split off the Qt4 and Qt5 libraries, I updated the sip-pyqt*-py only and checked that they do not interfere with the pyqt*-mac-py builds. Note that the matplotlib-py35 should still work (3.0.3 being the last version that supported py35), but I haven't been able to build and test it on 10.14, since I can no longer build a functional Python 3.5 (or 3.6) due to https://github.com/fink/fink-distributions/issues/655#issuecomment-709617073 .

nieder commented 4 years ago

Regarding your 2.2.5-py27: you're building a local freetype.dylib that has the same install_name as Fink's so that the .so modules use the ft-2.6.1 library during tests (to get matching results), but once installed the .so link paths find Fink's FT library in %p/lib/ft219/lib ? I think that's what's happening, but just want to confirm. But FT-2.6.1 should only be a TestSource. We don't want to download it when someone is not running tests.

Instead of the rsync magic, does %p/bin/python%type_raw[python] setup.py develop --root=... work? Might clean up the way the build process is ordered (testing in InstallScript, etc). Missing pytest-mpl-py package. Are the BuildConflicts against qhull*-dev needed? I don't see a difference in the build process or the final _qhull.so module.

I potentially fine with either yours or my mpl-2.2.5 being checked in for all current python versions, then figuring out what's needed for 3x series.

dhomeier commented 4 years ago

Continuing the thread in #678