# # spec file for package python-matplotlib (Version 1.0.0) # # Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: python-matplotlib License: BSD Group: Development/Libraries/Python Version: 1.0.0 Release: 2 AutoReqProv: on Summary: Plotting Library for Python Url: http://sourceforge.net/projects/matplotlib Source: matplotlib-%{version}.tar.bz2 Source1: matplotlib-setup.cfg BuildRoot: %{_tmppath}/%{name}-%{version}-build Prefix: %{_prefix} %py_requires Requires: python-numpy >= 1.2.1 Requires: python-configobj python-dateutil python-tz BuildRequires: python-numpy-devel >= 1.2.1 BuildRequires: gcc-c++ tcl tk BuildRequires: freetype2-devel gtk2-devel libpng-devel tcl-devel tk-devel wxGTK-devel BuildRequires: fltk-devel python-gtk python-tk python-wxGTK BuildRequires: python-gtk-devel %if 0%{?suse_version} >= 1120 BuildRequires: python-qt4 %else BuildRequires: python-qt %endif %if 0%{?suse_version} >= 1130 BuildRequires: libgnome-devel %else BuildRequires: gnome-libs-devel %endif ## These packages are required to prevent that matplotlib installs it's ## own versions of the packages from the lib directory BuildRequires: python-configobj python-dateutil python-tz %description matplotlib is a python 2D plotting library which produces publication quality figures in a variety of hardcopy formats and interactive environments across platforms. matplotlib can be used in python scripts, the python and ipython shell (ala matlab or mathematica), web application servers, and six graphical user interface toolkits. %package tk License: BSD Summary: Tk backend for python-matplotlib Group: Development/Libraries/Python Requires: %{name} = %{version}-%{release} Requires: python-tk %description tk Tk backend for python-matplotlib plotting package %package wx License: BSD Summary: Wx backend for python-matplotlib Group: Development/Libraries/Python Requires: %{name} = %{version}-%{release} Requires: python-wxGTK %description wx wxWidgets backend for python-matplotlib plotting package %prep %setup -n matplotlib-%{version} chmod -x lib/matplotlib/mpl-data/images/*.svg %build cp %{SOURCE1} ./setup.cfg python setup.py build %install python setup.py install --root=$RPM_BUILD_ROOT \ --record-rpm=INSTALLED_FILES --prefix=%{_prefix} %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc README.txt CHANGELOG INSTALL INTERACTIVE KNOWN_BUGS %doc PKG-INFO TODO CXX examples license %{py_sitedir}/* %exclude %{py_sitedir}/matplotlib/backends/backend_tkagg.* %exclude %{py_sitedir}/matplotlib/backends/tkagg.* %exclude %{py_sitedir}/matplotlib/backends/_tkagg.so %exclude %{py_sitedir}/matplotlib/backends/backend_wx.* %exclude %{py_sitedir}/matplotlib/backends/backend_wxagg.* %if %suse_version <= 1020 %exclude %{py_sitedir}/matplotlib/backends/_wxagg.so %endif %files tk %defattr(-,root,root,-) %{py_sitedir}/matplotlib/backends/backend_tkagg.* %{py_sitedir}/matplotlib/backends/tkagg.* %{py_sitedir}/matplotlib/backends/_tkagg.so %files wx %defattr(-,root,root,-) %{py_sitedir}/matplotlib/backends/backend_wx.* %{py_sitedir}/matplotlib/backends/backend_wxagg.* %if %suse_version <= 1020 %{py_sitedir}/matplotlib/backends/_wxagg.so %endif %changelog