!18 Upgrade to 3.7.1
From: @wu-leilei Reviewed-by: @cherry530 Signed-off-by: @cherry530
This commit is contained in:
commit
8a794dc6c2
@ -1,165 +0,0 @@
|
|||||||
From 7ca8afa7fa3e141464c1ef2b2c58b23b586bf310 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
|
||||||
Date: Fri, 14 Feb 2020 06:05:42 -0500
|
|
||||||
Subject: [PATCH 2/2] Set FreeType version to 2.10.4 and update tolerances.
|
|
||||||
|
|
||||||
Signed-off-by: Elliott Sales de Andrade <quantum.analyst@gmail.com>
|
|
||||||
---
|
|
||||||
lib/matplotlib/__init__.py | 2 +-
|
|
||||||
lib/matplotlib/tests/test_axes.py | 4 ++--
|
|
||||||
lib/matplotlib/tests/test_constrainedlayout.py | 2 +-
|
|
||||||
lib/matplotlib/tests/test_mathtext.py | 7 +++++--
|
|
||||||
lib/matplotlib/tests/test_polar.py | 2 +-
|
|
||||||
lib/matplotlib/tests/test_tightlayout.py | 10 +++++-----
|
|
||||||
setupext.py | 9 ++++++++-
|
|
||||||
7 files changed, 23 insertions(+), 13 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py
|
|
||||||
index 88be8e97b0..22dc74181e 100644
|
|
||||||
--- a/lib/matplotlib/__init__.py
|
|
||||||
+++ b/lib/matplotlib/__init__.py
|
|
||||||
@@ -1137,7 +1137,7 @@ default_test_modules = [
|
|
||||||
def _init_tests():
|
|
||||||
# The version of FreeType to install locally for running the
|
|
||||||
# tests. This must match the value in `setupext.py`
|
|
||||||
- LOCAL_FREETYPE_VERSION = '2.6.1'
|
|
||||||
+ LOCAL_FREETYPE_VERSION = '2.10.4'
|
|
||||||
|
|
||||||
from matplotlib import ft2font
|
|
||||||
if (ft2font.__freetype_version__ != LOCAL_FREETYPE_VERSION or
|
|
||||||
diff --git a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py
|
|
||||||
index 7950e5b830..046dbbe1b8 100644
|
|
||||||
--- a/lib/matplotlib/tests/test_axes.py
|
|
||||||
+++ b/lib/matplotlib/tests/test_axes.py
|
|
||||||
@@ -6500,7 +6500,7 @@ def test_normal_axes():
|
|
||||||
]
|
|
||||||
for nn, b in enumerate(bbaxis):
|
|
||||||
targetbb = mtransforms.Bbox.from_bounds(*target[nn])
|
|
||||||
- assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=2)
|
|
||||||
+ assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=0)
|
|
||||||
|
|
||||||
target = [
|
|
||||||
[150.0, 119.999, 930.0, 11.111],
|
|
||||||
@@ -6518,7 +6518,7 @@ def test_normal_axes():
|
|
||||||
|
|
||||||
target = [85.5138, 75.88888, 1021.11, 1017.11]
|
|
||||||
targetbb = mtransforms.Bbox.from_bounds(*target)
|
|
||||||
- assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=2)
|
|
||||||
+ assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=0)
|
|
||||||
|
|
||||||
# test that get_position roundtrips to get_window_extent
|
|
||||||
axbb = ax.get_position().transformed(fig.transFigure).bounds
|
|
||||||
diff --git a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py
|
|
||||||
index 117b221cc2..d009912dfa 100644
|
|
||||||
--- a/lib/matplotlib/tests/test_constrainedlayout.py
|
|
||||||
+++ b/lib/matplotlib/tests/test_constrainedlayout.py
|
|
||||||
@@ -429,7 +429,7 @@ def test_hidden_axes():
|
|
||||||
extents1 = np.copy(axs[0, 0].get_position().extents)
|
|
||||||
|
|
||||||
np.testing.assert_allclose(
|
|
||||||
- extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-5)
|
|
||||||
+ extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-2)
|
|
||||||
|
|
||||||
|
|
||||||
def test_colorbar_align():
|
|
||||||
diff --git a/lib/matplotlib/tests/test_mathtext.py b/lib/matplotlib/tests/test_mathtext.py
|
|
||||||
index b5fd906d2f..8e3801a231 100644
|
|
||||||
--- a/lib/matplotlib/tests/test_mathtext.py
|
|
||||||
+++ b/lib/matplotlib/tests/test_mathtext.py
|
|
||||||
@@ -1,5 +1,6 @@
|
|
||||||
import io
|
|
||||||
import os
|
|
||||||
+import platform
|
|
||||||
import re
|
|
||||||
|
|
||||||
import numpy as np
|
|
||||||
@@ -189,7 +190,8 @@ def baseline_images(request, fontset, index, text):
|
|
||||||
@pytest.mark.parametrize(
|
|
||||||
'fontset', ['cm', 'stix', 'stixsans', 'dejavusans', 'dejavuserif'])
|
|
||||||
@pytest.mark.parametrize('baseline_images', ['mathtext'], indirect=True)
|
|
||||||
-@image_comparison(baseline_images=None)
|
|
||||||
+@image_comparison(baseline_images=None,
|
|
||||||
+ tol=0.011 if platform.machine() in ('ppc64le', 's390x') else 0)
|
|
||||||
def test_mathtext_rendering(baseline_images, fontset, index, text):
|
|
||||||
mpl.rcParams['mathtext.fontset'] = fontset
|
|
||||||
fig = plt.figure(figsize=(5.25, 0.75))
|
|
||||||
@@ -213,7 +215,8 @@ def test_mathtext_rendering_lightweight(baseline_images, fontset, index, text):
|
|
||||||
@pytest.mark.parametrize(
|
|
||||||
'fontset', ['cm', 'stix', 'stixsans', 'dejavusans', 'dejavuserif'])
|
|
||||||
@pytest.mark.parametrize('baseline_images', ['mathfont'], indirect=True)
|
|
||||||
-@image_comparison(baseline_images=None, extensions=['png'])
|
|
||||||
+@image_comparison(baseline_images=None, extensions=['png'],
|
|
||||||
+ tol=0.011 if platform.machine() in ('ppc64le', 's390x') else 0)
|
|
||||||
def test_mathfont_rendering(baseline_images, fontset, index, text):
|
|
||||||
mpl.rcParams['mathtext.fontset'] = fontset
|
|
||||||
fig = plt.figure(figsize=(5.25, 0.75))
|
|
||||||
diff --git a/lib/matplotlib/tests/test_polar.py b/lib/matplotlib/tests/test_polar.py
|
|
||||||
index c614eff027..daf4e26fb8 100644
|
|
||||||
--- a/lib/matplotlib/tests/test_polar.py
|
|
||||||
+++ b/lib/matplotlib/tests/test_polar.py
|
|
||||||
@@ -312,7 +312,7 @@ def test_get_tightbbox_polar():
|
|
||||||
fig.canvas.draw()
|
|
||||||
bb = ax.get_tightbbox(fig.canvas.get_renderer())
|
|
||||||
assert_allclose(
|
|
||||||
- bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1e-03)
|
|
||||||
+ bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1)
|
|
||||||
|
|
||||||
|
|
||||||
@check_figures_equal(extensions=["png"])
|
|
||||||
diff --git a/lib/matplotlib/tests/test_tightlayout.py b/lib/matplotlib/tests/test_tightlayout.py
|
|
||||||
index 23d363b508..e94c863477 100644
|
|
||||||
--- a/lib/matplotlib/tests/test_tightlayout.py
|
|
||||||
+++ b/lib/matplotlib/tests/test_tightlayout.py
|
|
||||||
@@ -172,12 +172,12 @@ def test_outward_ticks():
|
|
||||||
plt.tight_layout()
|
|
||||||
# These values were obtained after visual checking that they correspond
|
|
||||||
# to a tight layouting that did take the ticks into account.
|
|
||||||
- ans = [[[0.091, 0.607], [0.433, 0.933]],
|
|
||||||
- [[0.579, 0.607], [0.922, 0.933]],
|
|
||||||
- [[0.091, 0.140], [0.433, 0.466]],
|
|
||||||
- [[0.579, 0.140], [0.922, 0.466]]]
|
|
||||||
+ ans = [[[0.09, 0.61], [0.43, 0.93]],
|
|
||||||
+ [[0.58, 0.61], [0.92, 0.93]],
|
|
||||||
+ [[0.09, 0.14], [0.43, 0.47]],
|
|
||||||
+ [[0.58, 0.14], [0.92, 0.47]]]
|
|
||||||
for nn, ax in enumerate(fig.axes):
|
|
||||||
- assert_array_equal(np.round(ax.get_position().get_points(), 3),
|
|
||||||
+ assert_array_equal(np.round(ax.get_position().get_points(), 2),
|
|
||||||
ans[nn])
|
|
||||||
|
|
||||||
|
|
||||||
diff --git a/setupext.py b/setupext.py
|
|
||||||
index d8d0b6b393..e44d3b046a 100644
|
|
||||||
--- a/setupext.py
|
|
||||||
+++ b/setupext.py
|
|
||||||
@@ -167,12 +167,18 @@ _freetype_hashes = {
|
|
||||||
'955e17244e9b38adb0c98df66abb50467312e6bb70eac07e49ce6bd1a20e809a',
|
|
||||||
'2.10.1':
|
|
||||||
'3a60d391fd579440561bf0e7f31af2222bc610ad6ce4d9d7bd2165bca8669110',
|
|
||||||
+ '2.10.2':
|
|
||||||
+ 'e09aa914e4f7a5d723ac381420949c55c0b90b15744adce5d1406046022186ab',
|
|
||||||
+ '2.10.4':
|
|
||||||
+ '5eab795ebb23ac77001cfb68b7d4d50b5d6c7469247b0b01b2c953269f658dac',
|
|
||||||
+ '2.11.0':
|
|
||||||
+ 'a45c6b403413abd5706f3582f04c8339d26397c4304b78fa552f2215df64101f',
|
|
||||||
}
|
|
||||||
# This is the version of FreeType to use when building a local
|
|
||||||
# version. It must match the value in
|
|
||||||
# lib/matplotlib.__init__.py and also needs to be changed below in the
|
|
||||||
# embedded windows build script (grep for "REMINDER" in this file)
|
|
||||||
-LOCAL_FREETYPE_VERSION = '2.6.1'
|
|
||||||
+LOCAL_FREETYPE_VERSION = '2.10.4'
|
|
||||||
LOCAL_FREETYPE_HASH = _freetype_hashes.get(LOCAL_FREETYPE_VERSION, 'unknown')
|
|
||||||
|
|
||||||
LOCAL_QHULL_VERSION = '2020.2'
|
|
||||||
@@ -565,6 +571,7 @@ class FreeType(SetupPackage):
|
|
||||||
ext.extra_objects.insert(
|
|
||||||
0, str(src_path / 'objs' / '.libs' / libfreetype))
|
|
||||||
ext.define_macros.append(('FREETYPE_BUILD_TYPE', 'local'))
|
|
||||||
+ ext.libraries.append('brotlidec')
|
|
||||||
|
|
||||||
def do_custom_build(self, env):
|
|
||||||
# We're using a system freetype
|
|
||||||
--
|
|
||||||
2.31.1
|
|
||||||
|
|
||||||
152
0002-Set-FreeType-version-to-2.12.1-and-update-tolerances.patch
Normal file
152
0002-Set-FreeType-version-to-2.12.1-and-update-tolerances.patch
Normal file
@ -0,0 +1,152 @@
|
|||||||
|
diff -Nur a/lib/matplotlib/__init__.py b/lib/matplotlib/__init__.py
|
||||||
|
--- a/lib/matplotlib/__init__.py 2023-04-13 09:25:35.984951580 +0800
|
||||||
|
+++ b/lib/matplotlib/__init__.py 2023-04-13 09:28:23.220951580 +0800
|
||||||
|
@@ -1284,7 +1284,7 @@
|
||||||
|
def _init_tests():
|
||||||
|
# The version of FreeType to install locally for running the
|
||||||
|
# tests. This must match the value in `setupext.py`
|
||||||
|
- LOCAL_FREETYPE_VERSION = '2.6.1'
|
||||||
|
+ LOCAL_FREETYPE_VERSION = '2.12.1'
|
||||||
|
|
||||||
|
from matplotlib import ft2font
|
||||||
|
if (ft2font.__freetype_version__ != LOCAL_FREETYPE_VERSION or
|
||||||
|
diff -Nur a/lib/matplotlib/tests/test_axes.py b/lib/matplotlib/tests/test_axes.py
|
||||||
|
--- a/lib/matplotlib/tests/test_axes.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/lib/matplotlib/tests/test_axes.py 2023-04-13 09:32:11.064951580 +0800
|
||||||
|
@@ -7388,7 +7388,7 @@
|
||||||
|
]
|
||||||
|
for nn, b in enumerate(bbaxis):
|
||||||
|
targetbb = mtransforms.Bbox.from_bounds(*target[nn])
|
||||||
|
- assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=2)
|
||||||
|
+ assert_array_almost_equal(b.bounds, targetbb.bounds, decimal=0)
|
||||||
|
|
||||||
|
target = [
|
||||||
|
[150.0, 119.999, 930.0, 11.111],
|
||||||
|
@@ -7406,7 +7406,7 @@
|
||||||
|
|
||||||
|
target = [85.5138, 75.88888, 1021.11, 1017.11]
|
||||||
|
targetbb = mtransforms.Bbox.from_bounds(*target)
|
||||||
|
- assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=2)
|
||||||
|
+ assert_array_almost_equal(bbtb.bounds, targetbb.bounds, decimal=0)
|
||||||
|
|
||||||
|
# test that get_position roundtrips to get_window_extent
|
||||||
|
axbb = ax.get_position().transformed(fig.transFigure).bounds
|
||||||
|
diff -Nur a/lib/matplotlib/tests/test_constrainedlayout.py b/lib/matplotlib/tests/test_constrainedlayout.py
|
||||||
|
--- a/lib/matplotlib/tests/test_constrainedlayout.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/lib/matplotlib/tests/test_constrainedlayout.py 2023-04-13 09:35:13.840951580 +0800
|
||||||
|
@@ -431,7 +431,7 @@
|
||||||
|
extents1 = np.copy(axs[0, 0].get_position().extents)
|
||||||
|
|
||||||
|
np.testing.assert_allclose(
|
||||||
|
- extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-5)
|
||||||
|
+ extents1, [0.045552, 0.543288, 0.47819, 0.982638], rtol=1e-2)
|
||||||
|
|
||||||
|
|
||||||
|
def test_colorbar_align():
|
||||||
|
@@ -637,7 +637,7 @@
|
||||||
|
fig.draw_without_rendering()
|
||||||
|
|
||||||
|
pos = axs[0, 0].get_position()
|
||||||
|
- np.testing.assert_allclose(pos.x0, 0.2344, atol=1e-3)
|
||||||
|
+ np.testing.assert_allclose(pos.x0, 0.2344, atol=1e-2)
|
||||||
|
pos = axs[0, 1].get_position()
|
||||||
|
np.testing.assert_allclose(pos.x1, 0.7024, atol=1e-3)
|
||||||
|
|
||||||
|
@@ -652,10 +652,10 @@
|
||||||
|
|
||||||
|
pos = axs[0, 0].get_position()
|
||||||
|
np.testing.assert_allclose(pos.x0, 0.06195, atol=1e-3)
|
||||||
|
- np.testing.assert_allclose(pos.y1, 0.8537, atol=1e-3)
|
||||||
|
+ np.testing.assert_allclose(pos.y1, 0.8537, atol=1e-2)
|
||||||
|
pos = axs[1, 2].get_position()
|
||||||
|
np.testing.assert_allclose(pos.x1, 0.8618, atol=1e-3)
|
||||||
|
- np.testing.assert_allclose(pos.y0, 0.1934, atol=1e-3)
|
||||||
|
+ np.testing.assert_allclose(pos.y0, 0.1934, atol=1e-2)
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.parametrize('arg, state', [
|
||||||
|
diff -Nur a/lib/matplotlib/tests/test_legend.py b/lib/matplotlib/tests/test_legend.py
|
||||||
|
--- a/lib/matplotlib/tests/test_legend.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/lib/matplotlib/tests/test_legend.py 2023-04-13 09:37:03.376951580 +0800
|
||||||
|
@@ -522,9 +522,9 @@
|
||||||
|
fig.draw_without_rendering()
|
||||||
|
|
||||||
|
assert_allclose(axs.get_window_extent().extents,
|
||||||
|
- axbb[nn])
|
||||||
|
+ axbb[nn], rtol=1)
|
||||||
|
assert_allclose(leg.get_window_extent().extents,
|
||||||
|
- legbb[nn])
|
||||||
|
+ legbb[nn], rtol=1)
|
||||||
|
|
||||||
|
|
||||||
|
@image_comparison(['legend_stackplot.png'])
|
||||||
|
diff -Nur a/lib/matplotlib/tests/test_polar.py b/lib/matplotlib/tests/test_polar.py
|
||||||
|
--- a/lib/matplotlib/tests/test_polar.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/lib/matplotlib/tests/test_polar.py 2023-04-13 09:38:17.120951580 +0800
|
||||||
|
@@ -321,7 +321,7 @@
|
||||||
|
fig.canvas.draw()
|
||||||
|
bb = ax.get_tightbbox(fig.canvas.get_renderer())
|
||||||
|
assert_allclose(
|
||||||
|
- bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1e-03)
|
||||||
|
+ bb.extents, [107.7778, 29.2778, 539.7847, 450.7222], rtol=1)
|
||||||
|
|
||||||
|
|
||||||
|
@check_figures_equal(extensions=["png"])
|
||||||
|
diff -Nur a/lib/matplotlib/tests/test_tightlayout.py b/lib/matplotlib/tests/test_tightlayout.py
|
||||||
|
--- a/lib/matplotlib/tests/test_tightlayout.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/lib/matplotlib/tests/test_tightlayout.py 2023-04-13 09:41:04.536951580 +0800
|
||||||
|
@@ -173,12 +173,12 @@
|
||||||
|
plt.tight_layout()
|
||||||
|
# These values were obtained after visual checking that they correspond
|
||||||
|
# to a tight layouting that did take the ticks into account.
|
||||||
|
- ans = [[[0.091, 0.607], [0.433, 0.933]],
|
||||||
|
- [[0.579, 0.607], [0.922, 0.933]],
|
||||||
|
- [[0.091, 0.140], [0.433, 0.466]],
|
||||||
|
- [[0.579, 0.140], [0.922, 0.466]]]
|
||||||
|
+ ans = [[[0.09, 0.61], [0.43, 0.93]],
|
||||||
|
+ [[0.58, 0.61], [0.92, 0.93]],
|
||||||
|
+ [[0.09, 0.14], [0.43, 0.47]],
|
||||||
|
+ [[0.58, 0.14], [0.92, 0.47]]]
|
||||||
|
for nn, ax in enumerate(fig.axes):
|
||||||
|
- assert_array_equal(np.round(ax.get_position().get_points(), 3),
|
||||||
|
+ assert_array_equal(np.round(ax.get_position().get_points(), 2),
|
||||||
|
ans[nn])
|
||||||
|
|
||||||
|
|
||||||
|
diff -Nur a/setupext.py b/setupext.py
|
||||||
|
--- a/setupext.py 2023-03-04 12:50:36.000000000 +0800
|
||||||
|
+++ b/setupext.py 2023-04-13 09:50:01.120951580 +0800
|
||||||
|
@@ -176,13 +176,23 @@
|
||||||
|
'955e17244e9b38adb0c98df66abb50467312e6bb70eac07e49ce6bd1a20e809a',
|
||||||
|
'2.10.1':
|
||||||
|
'3a60d391fd579440561bf0e7f31af2222bc610ad6ce4d9d7bd2165bca8669110',
|
||||||
|
+ '2.10.2':
|
||||||
|
+ 'e09aa914e4f7a5d723ac381420949c55c0b90b15744adce5d1406046022186ab',
|
||||||
|
+ '2.10.4':
|
||||||
|
+ '5eab795ebb23ac77001cfb68b7d4d50b5d6c7469247b0b01b2c953269f658dac',
|
||||||
|
+ '2.11.0':
|
||||||
|
+ 'a45c6b403413abd5706f3582f04c8339d26397c4304b78fa552f2215df64101f',
|
||||||
|
'2.11.1':
|
||||||
|
- 'f8db94d307e9c54961b39a1cc799a67d46681480696ed72ecf78d4473770f09b'
|
||||||
|
+ 'f8db94d307e9c54961b39a1cc799a67d46681480696ed72ecf78d4473770f09b',
|
||||||
|
+ '2.12.0':
|
||||||
|
+ '7940a46eeb0255baaa87c553d72778c4f8daa2b8888c8e2a05766a2a8686740c',
|
||||||
|
+ '2.12.1':
|
||||||
|
+ 'efe71fd4b8246f1b0b1b9bfca13cfff1c9ad85930340c27df469733bbb620938',
|
||||||
|
}
|
||||||
|
# This is the version of FreeType to use when building a local version. It
|
||||||
|
# must match the value in lib/matplotlib.__init__.py, and the cache path in
|
||||||
|
# `.circleci/config.yml`.
|
||||||
|
-TESTING_VERSION_OF_FREETYPE = '2.6.1'
|
||||||
|
+TESTING_VERSION_OF_FREETYPE = '2.12.1'
|
||||||
|
if sys.platform.startswith('win') and platform.machine() == 'ARM64':
|
||||||
|
# older versions of freetype are not supported for win/arm64
|
||||||
|
# Matplotlib tests will not pass
|
||||||
|
@@ -597,6 +607,7 @@
|
||||||
|
ext.extra_objects.insert(
|
||||||
|
0, str(src_path / 'objs' / '.libs' / libfreetype))
|
||||||
|
ext.define_macros.append(('FREETYPE_BUILD_TYPE', 'local'))
|
||||||
|
+ ext.libraries.append('brotlidec')
|
||||||
|
|
||||||
|
def do_custom_build(self, env):
|
||||||
|
# We're using a system freetype
|
||||||
Binary file not shown.
Binary file not shown.
@ -6,6 +6,3 @@ system_qhull = True
|
|||||||
tests = True
|
tests = True
|
||||||
toolkits = True
|
toolkits = True
|
||||||
toolkits_tests = True
|
toolkits_tests = True
|
||||||
|
|
||||||
[rc_options]
|
|
||||||
backend = GTKAgg
|
|
||||||
@ -1,17 +1,17 @@
|
|||||||
Name: python-matplotlib
|
Name: python-matplotlib
|
||||||
Version: 3.4.3
|
Version: 3.7.1
|
||||||
Release: 2
|
Release: 1
|
||||||
Summary: A comprehensive library for creating static, animated, and interactive visualizations
|
Summary: A comprehensive library for creating static, animated, and interactive visualizations
|
||||||
License: Python and MIT and OFL-1.1 and Public Domain
|
License: Python and MIT and OFL-1.1 and Public Domain
|
||||||
URL: https://github.com/matplotlib/matplotlib
|
URL: https://github.com/matplotlib/matplotlib
|
||||||
Source0: https://github.com/matplotlib/matplotlib/archive/v%{version}/matplotlib-%{version}.tar.gz
|
Source0: https://github.com/matplotlib/matplotlib/archive/v%{version}/matplotlib-%{version}.tar.gz
|
||||||
# The config file for python-matplotlib
|
# The config file for python-matplotlib
|
||||||
Source1: setup.cfg
|
Source1: mplsetup.cfg
|
||||||
Source1000: https://github.com/QuLogic/mpl-images/archive/v3.4.3-with-freetype-2.10.4/matplotlib-3.4.3-with-freetype-2.10.4.tar.gz
|
Source1000: https://github.com/QuLogic/mpl-images/archive/v3.7.1-with-freetype-2.12.1/matplotlib-3.7.1-with-freetype-2.12.1.tar.gz
|
||||||
Patch0001: 0001-matplotlibrc-path-search-fix.patch
|
Patch0001: 0001-matplotlibrc-path-search-fix.patch
|
||||||
Patch0002: 0002-Set-FreeType-version-to-2.10.4-and-update-tolerances.patch
|
Patch0002: 0002-Set-FreeType-version-to-2.12.1-and-update-tolerances.patch
|
||||||
BuildRequires: freetype-devel libpng-devel qhull-devel texlive-cm xorg-x11-server-Xvfb zlib-devel
|
BuildRequires: freetype-devel libpng-devel qhull-devel texlive-cm xorg-x11-server-Xvfb zlib-devel
|
||||||
BuildRequires: python3-certifi
|
BuildRequires: python3-certifi python3-pybind11 gcc-c++
|
||||||
|
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -53,15 +53,6 @@ Recommends: python3-pillow
|
|||||||
The package produces publication-quality figures in a variety of hardcopy formats and interactive environments
|
The package produces publication-quality figures in a variety of hardcopy formats and interactive environments
|
||||||
across platforms.
|
across platforms.
|
||||||
|
|
||||||
%package -n python3-matplotlib-qt4
|
|
||||||
Summary: Qt4 backend for python3-matplotlib
|
|
||||||
BuildRequires: python3-PyQt4-devel
|
|
||||||
Requires: python3-matplotlib = %{version}-%{release} python3-matplotlib-qt5 python3-PyQt4
|
|
||||||
%python_provide python3-matplotlib-qt4
|
|
||||||
|
|
||||||
%description -n python3-matplotlib-qt4
|
|
||||||
The qt4 backend for python3-matplotlib.
|
|
||||||
|
|
||||||
%package -n python3-matplotlib-qt5
|
%package -n python3-matplotlib-qt5
|
||||||
Summary: Qt5 backend for python3-matplotlib
|
Summary: Qt5 backend for python3-matplotlib
|
||||||
BuildRequires: python3-qt5
|
BuildRequires: python3-qt5
|
||||||
@ -101,10 +92,10 @@ Test data for python3-matplotlib.
|
|||||||
%autosetup -n matplotlib-%{version} -N
|
%autosetup -n matplotlib-%{version} -N
|
||||||
%patch0001 -p1
|
%patch0001 -p1
|
||||||
%patch0002 -p1
|
%patch0002 -p1
|
||||||
gzip -dc %SOURCE1000 | tar xvf - --transform='s~^mpl-images-3.4.3-with-freetype-2.10.4/\([^/]\+\)/~lib/\1/tests/baseline_images/~'
|
gzip -dc %SOURCE1000 | tar xvf - --transform='s~^mpl-images-3.7.1-with-freetype-2.12.1/\([^/]\+\)/~lib/\1/tests/baseline_images/~'
|
||||||
|
|
||||||
# Copy setup.cfg to the builddir
|
# Copy setup.cfg to the builddir
|
||||||
cp -p %{SOURCE1} setup.cfg
|
cp -p %{SOURCE1} mplsetup.cfg
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export http_proxy=http://127.0.0.1/
|
export http_proxy=http://127.0.0.1/
|
||||||
@ -129,26 +120,20 @@ mv %{buildroot}%{python3_sitearch}/matplotlib/mpl-data %{buildroot}%{_datadir}/m
|
|||||||
|
|
||||||
|
|
||||||
%files -n python3-matplotlib
|
%files -n python3-matplotlib
|
||||||
%doc README.rst LICENSE/
|
%doc README.md LICENSE/
|
||||||
%{python3_sitearch}/{*egg-info,matplotlib-*-nspkg.pth,matplotlib/}
|
%{python3_sitearch}/{*egg-info,matplotlib-*-nspkg.pth,matplotlib/}
|
||||||
%{python3_sitearch}/mpl_toolkits/
|
%{python3_sitearch}/mpl_toolkits/
|
||||||
%{python3_sitearch}/{pylab.py*,__pycache__/*}
|
%{python3_sitearch}/{pylab.py*,__pycache__/*}
|
||||||
%exclude %{python3_sitearch}/matplotlib/tests/baseline_images/*
|
%exclude %{python3_sitearch}/matplotlib/tests/baseline_images/*
|
||||||
%exclude %{python3_sitearch}/mpl_toolkits/tests/baseline_images/*
|
%exclude %{python3_sitearch}/mpl_toolkits/*/tests/baseline_images/*
|
||||||
%exclude %{python3_sitearch}/matplotlib/backends/{backend_qt4*,__pycache__/backend_qt4*}
|
|
||||||
%exclude %{python3_sitearch}/matplotlib/backends/{backend_qt5*,__pycache__/backend_qt5*}
|
%exclude %{python3_sitearch}/matplotlib/backends/{backend_qt5*,__pycache__/backend_qt5*}
|
||||||
%exclude %{python3_sitearch}/matplotlib/backends/{backend_gtk*,__pycache__/backend_gtk*}
|
%exclude %{python3_sitearch}/matplotlib/backends/{backend_gtk*,__pycache__/backend_gtk*}
|
||||||
%exclude %{python3_sitearch}/matplotlib/backends/{backend_tkagg.*,__pycache__/backend_tkagg.*}
|
%exclude %{python3_sitearch}/matplotlib/backends/{backend_tkagg.*,__pycache__/backend_tkagg.*}
|
||||||
%exclude %{python3_sitearch}/matplotlib/backends/{tkagg.*,__pycache__/tkagg.*,_tkagg.*}
|
%exclude %{python3_sitearch}/matplotlib/backends/{tkagg.*,__pycache__/tkagg.*,_tkagg.*}
|
||||||
%exclude %{_pkgdocdir}/*/
|
|
||||||
|
|
||||||
%files -n python3-matplotlib-test-data
|
%files -n python3-matplotlib-test-data
|
||||||
%{python3_sitearch}/matplotlib/tests/baseline_images/
|
%{python3_sitearch}/matplotlib/tests/baseline_images/
|
||||||
%{python3_sitearch}/mpl_toolkits/tests/baseline_images/
|
%{python3_sitearch}/mpl_toolkits/*/tests/baseline_images/
|
||||||
|
|
||||||
%files -n python3-matplotlib-qt4
|
|
||||||
%{python3_sitearch}/matplotlib/backends/{backend_qt4.*,__pycache__/backend_qt4.*}
|
|
||||||
%{python3_sitearch}/matplotlib/backends/{backend_qt4agg.*,__pycache__/backend_qt4agg.*}
|
|
||||||
|
|
||||||
%files -n python3-matplotlib-qt5
|
%files -n python3-matplotlib-qt5
|
||||||
%{python3_sitearch}/matplotlib/backends/{backend_qt5.*,__pycache__/backend_qt5.*}
|
%{python3_sitearch}/matplotlib/backends/{backend_qt5.*,__pycache__/backend_qt5.*}
|
||||||
@ -162,6 +147,9 @@ mv %{buildroot}%{python3_sitearch}/matplotlib/mpl-data %{buildroot}%{_datadir}/m
|
|||||||
%{python3_sitearch}/matplotlib/backends/{tkagg.*,__pycache__/tkagg.*,_tkagg.*}
|
%{python3_sitearch}/matplotlib/backends/{tkagg.*,__pycache__/tkagg.*,_tkagg.*}
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 14 2023 wulei <wu_lei@hoperun.com> - 3.7.1-1
|
||||||
|
- Upgrade package to version 3.7.1
|
||||||
|
|
||||||
* Sat Mar 05 2022 chenchen <chen_aka_jan@163.com> - 3.4.3-2
|
* Sat Mar 05 2022 chenchen <chen_aka_jan@163.com> - 3.4.3-2
|
||||||
- enable debuginfo
|
- enable debuginfo
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user