Accepting request 510271 from devel:languages:python
1 OBS-URL: https://build.opensuse.org/request/show/510271 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-matplotlib?expand=0&rev=53
This commit is contained in:
parent
f69b712df4
commit
946bb729f5
49
0001-Fix-include-path-for-system-libqhull.patch
Normal file
49
0001-Fix-include-path-for-system-libqhull.patch
Normal file
@ -0,0 +1,49 @@
|
|||||||
|
From e75ca533cc5a590d7831507794a2db25ca46e07e Mon Sep 17 00:00:00 2001
|
||||||
|
From: =?UTF-8?q?Stefan=20Br=C3=83=C2=BCns?= <stefan.bruens@rwth-aachen.de>
|
||||||
|
Date: Thu, 13 Jul 2017 21:38:16 +0200
|
||||||
|
Subject: [PATCH] Fix include path for system libqhull
|
||||||
|
|
||||||
|
Current libqhull uses the libqhull subdirectory. If the system libqhull
|
||||||
|
is not found, it falls back to a much older bundled version.
|
||||||
|
---
|
||||||
|
setupext.py | 4 ++--
|
||||||
|
src/qhull_wrap.c | 2 +-
|
||||||
|
2 files changed, 3 insertions(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/setupext.py b/setupext.py
|
||||||
|
index 3819636..8894b17 100644
|
||||||
|
--- a/setupext.py
|
||||||
|
+++ b/setupext.py
|
||||||
|
@@ -1175,14 +1175,14 @@ class Qhull(SetupPackage):
|
||||||
|
self.__class__.found_external = True
|
||||||
|
try:
|
||||||
|
return self._check_for_pkg_config(
|
||||||
|
- 'qhull', 'qhull/qhull_a.h', min_version='2003.1')
|
||||||
|
+ 'qhull', 'libqhull/qhull_a.h', min_version='2003.1')
|
||||||
|
except CheckFailed as e:
|
||||||
|
self.__class__.found_pkgconfig = False
|
||||||
|
# Qhull may not be in the pkg-config system but may still be
|
||||||
|
# present on this system, so check if the header files can be
|
||||||
|
# found.
|
||||||
|
include_dirs = [
|
||||||
|
- os.path.join(x, 'qhull') for x in get_include_dirs()]
|
||||||
|
+ os.path.join(x, 'libqhull') for x in get_include_dirs()]
|
||||||
|
if has_include_file(include_dirs, 'qhull_a.h'):
|
||||||
|
return 'Using system Qhull (version unknown, no pkg-config info)'
|
||||||
|
else:
|
||||||
|
diff --git a/src/qhull_wrap.c b/src/qhull_wrap.c
|
||||||
|
index 06d278e..7d6ace4 100644
|
||||||
|
--- a/src/qhull_wrap.c
|
||||||
|
+++ b/src/qhull_wrap.c
|
||||||
|
@@ -7,7 +7,7 @@
|
||||||
|
*/
|
||||||
|
#include "Python.h"
|
||||||
|
#include "numpy/noprefix.h"
|
||||||
|
-#include "qhull/qhull_a.h"
|
||||||
|
+#include <libqhull/qhull_a.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
|
|
||||||
|
--
|
||||||
|
2.13.2
|
||||||
|
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Thu Jul 13 20:06:48 UTC 2017 - stefan.bruens@rwth-aachen.de
|
||||||
|
|
||||||
|
- Add 0001-Fix-include-path-for-system-libqhull.patch
|
||||||
|
Avoid falling back to outdated bundled version
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sun Apr 30 17:33:15 UTC 2017 - toddrme2178@gmail.com
|
Sun Apr 30 17:33:15 UTC 2017 - toddrme2178@gmail.com
|
||||||
|
|
||||||
|
@ -30,6 +30,8 @@ Group: Development/Libraries/Python
|
|||||||
Url: http://matplotlib.org
|
Url: http://matplotlib.org
|
||||||
Source: https://files.pythonhosted.org/packages/source/m/matplotlib/matplotlib-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/m/matplotlib/matplotlib-%{version}.tar.gz
|
||||||
Source1: matplotlib-setup.cfg
|
Source1: matplotlib-setup.cfg
|
||||||
|
# PATCH-FIX-OPENSUSE 0001-Fix-include-path-for-system-libqhull.patch stefan.bruens@rwth-aachen.de -- avoid using bundled qhull, fixed in mpl 2.1.0
|
||||||
|
Patch0: 0001-Fix-include-path-for-system-libqhull.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
BuildRequires: c++_compiler
|
BuildRequires: c++_compiler
|
||||||
@ -230,6 +232,7 @@ for %{name} plotting package
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n matplotlib-%{version}
|
%setup -q -n matplotlib-%{version}
|
||||||
|
%patch0 -p1
|
||||||
chmod -x lib/matplotlib/mpl-data/images/*.svg
|
chmod -x lib/matplotlib/mpl-data/images/*.svg
|
||||||
find examples lib/matplotlib lib/mpl_toolkits/mplot3d -type f -name "*.py" -exec sed -i "s|#!\/usr\/bin\/env python||" {} \;
|
find examples lib/matplotlib lib/mpl_toolkits/mplot3d -type f -name "*.py" -exec sed -i "s|#!\/usr\/bin\/env python||" {} \;
|
||||||
find examples lib/matplotlib lib/mpl_toolkits/mplot3d -type f -name "*.py" -exec sed -i "s|#!\/usr\/bin\/python||" {} \;
|
find examples lib/matplotlib lib/mpl_toolkits/mplot3d -type f -name "*.py" -exec sed -i "s|#!\/usr\/bin\/python||" {} \;
|
||||||
|
Loading…
Reference in New Issue
Block a user