ae10e83
%global srcname pycha
ae10e83
%global sum A library for drawing charts with Python and Cairo
Ionuț Arțăriși 4e24713
ae10e83
Name:           python-%{srcname}
ae10e83
Version:        0.7.0
7a81e56
Release:        12%{?dist}
ae10e83
Summary:        %{sum}
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
License:        LGPLv3+
ae10e83
URL:            https://bitbucket.org/lgs/pycha/
ae10e83
Source0:        https://files.pythonhosted.org/packages/source/p/%{srcname}/%{srcname}-%{version}.tar.gz
Ionuț Arțăriși 4e24713
Source1:        chavier.desktop
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
BuildArch:      noarch
Ionuț Arțăriși 4e24713
BuildRequires:  desktop-file-utils
ae10e83
BuildRequires:  python3-devel
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%description
Ionuț Arțăriși 4e24713
Pycha is a very simple Python package for drawing charts using the great Cairo
Ionuț Arțăriși 4e24713
library. Its goals are:
Ionuț Arțăriși 4e24713
    * Lightweight
Ionuț Arțăriși 4e24713
    * Simple to use
Ionuț Arțăriși 4e24713
    * Nice looking with default values
Ionuț Arțăriși 4e24713
    * Customization 
Ionuț Arțăriși 4e24713
It won't try to draw any possible chart on earth but draw the most common ones
Ionuț Arțăriși 4e24713
nicely.
Ionuț Arțăriși 4e24713
ae10e83
%package -n python3-%{srcname}
ae10e83
Summary:        %{sum}
ae10e83
%{?python_provide:%python_provide python3-%{srcname}}
8e9d15c
BuildRequires:  python3dist(pycairo)
8e9d15c
Requires:       python%{python3_version}dist(pycairo)
ae10e83
ae10e83
%description -n python3-%{srcname}
ae10e83
Pycha is a very simple Python package for drawing charts using the great Cairo
ae10e83
library. Its goals are:
ae10e83
    * Lightweight
ae10e83
    * Simple to use
ae10e83
    * Nice looking with default values
ae10e83
    * Customization 
ae10e83
It won't try to draw any possible chart on earth but draw the most common ones
ae10e83
nicely.
ae10e83
Ionuț Arțăriși 4e24713
%package -n     chavier
Ionuț Arțăriși 4e24713
Summary:        GUI application for exploring the pycha library
ae10e83
Requires:       python3-%{srcname} = %{version}-%{release}
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%description -n chavier
Ionuț Arțăriși 4e24713
Chavier allows the user to generate random data sets or use existing data to
Ionuț Arțăriși 4e24713
test the various options that %{shortname} provides in an interactive GUI
Ionuț Arțăriși 4e24713
application. Various chart types can be plotted and their options adjusted
Ionuț Arțăriși 4e24713
from the interface.
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%prep
9f91abd
%setup -q -n %{srcname}-%{version}
ae10e83
ae10e83
# remove upstream egg-info
9f91abd
rm -rf *.egg-info
ae10e83
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%build
9f91abd
2to3 --no-diffs -w chavier pycha tests
9f91abd
9f91abd
# for i in range(len(flat_y) / n_stores)
9f91abd
# TypeError: 'float' object cannot be interpreted as an integer
9f91abd
sed -i 's@ / n_stores@ // n_stores@g' pycha/stackedbar.py
9f91abd
ae10e83
%py3_build
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%install
ae10e83
%py3_install
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
desktop-file-install \
Ionuț Arțăriși 4e24713
--dir=%{buildroot}%{_datadir}/applications %{SOURCE1}
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%check
9f91abd
%{__python3} setup.py test
Ionuț Arțăriși 4e24713
ae10e83
ae10e83
%files -n python3-%{srcname}
9f91abd
%doc examples/ AUTHORS README.txt
9f91abd
%license COPYING
ae10e83
%{python3_sitelib}/%{srcname}
ae10e83
%{python3_sitelib}/%{srcname}-*.egg-info
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%files -n chavier
Ionuț Arțăriși 4e24713
%{_bindir}/chavier
Ionuț Arțăriși 4e24713
%{_datadir}/applications/chavier.desktop
ae10e83
%{python3_sitelib}/chavier
ae10e83
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
%changelog
7a81e56
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.0-12
7a81e56
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
7a81e56
8e9d15c
* Fri Dec 28 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 0.7.0-11
8e9d15c
- Fixup Requires
8e9d15c
9f91abd
* Thu Dec 27 2018 Miro Hrončok <mhroncok@redhat.com> - 0.7.0-10
9f91abd
- Subpackage python2-pycha has been removed
9f91abd
  See https://fedoraproject.org/wiki/Changes/Mass_Python_2_Package_Removal
9f91abd
b1d1463
* Sat Jul 14 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.0-9
b1d1463
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
b1d1463
09cda01
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.7.0-8
09cda01
- Rebuilt for Python 3.7
09cda01
2f6c960
* Tue Feb 27 2018 Iryna Shcherbina <ishcherb@redhat.com> - 0.7.0-7
2f6c960
- Update Python 2 dependency declarations to new packaging standards
2f6c960
  (See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3)
2f6c960
c6d8a42
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.0-6
c6d8a42
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
c6d8a42
c916f0d
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.0-5
c916f0d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
c916f0d
41c0335
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.0-4
41c0335
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
41c0335
de7b288
* Mon Dec 19 2016 Miro Hrončok <mhroncok@redhat.com> - 0.7.0-3
de7b288
- Rebuild for Python 3.6
de7b288
b61c216
* Tue Jul 19 2016 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.0-2
b61c216
- https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages
b61c216
ae10e83
* Fri Jul 15 2016 Dan Horák <dan[at]danny.cz> - 0.7.0-1
ae10e83
- new upstream release 0.7.0
ae10e83
- introduced py3 variant
ae10e83
cb700d6
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.0-9
cb700d6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
cb700d6
5ed9dc0
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-8
5ed9dc0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
5ed9dc0
104a54c
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-7
104a54c
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
104a54c
1e48e46
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-6
1e48e46
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
1e48e46
279d39f
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-5
279d39f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
279d39f
94213d5
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-4
94213d5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
94213d5
eff6c31
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-3
eff6c31
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
eff6c31
b1d0e47
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.6.0-2
b1d0e47
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
b1d0e47
Ionuț C. Arțăriși 324ce27
* Sun Jan 16 2011 Ionuț C. Arțăriși <mapleoin@fedoraproject.org> - 0.6.0-1
Ionuț C. Arțăriși 324ce27
- new upstream release 0.6.0
Ionuț C. Arțăriși 324ce27
Ionuț C. Arțăriși 74e9602
* Sat Aug  7 2010 Ionuț C. Arțăriși <mapleoin@fedoraproject.org> - 0.5.3-1
Ionuț C. Arțăriși 74e9602
- new upstream bugfix release
Ionuț C. Arțăriși 74e9602
7da47e3
* Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 0.5.2-3
7da47e3
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
7da47e3
Ionuț Arțăriși 4e24713
* Sat Mar 27 2010 Ionuț C. Arțăriși <mapleoin@fedoraproject.org> - 0.5.2-2
Ionuț Arțăriși 4e24713
- changed license from LGPLv3 to LGPLv3+
Ionuț Arțăriși 4e24713
- fixed spelling error in %%description
Ionuț Arțăriși 4e24713
- capitalized chavier package %%summary
Ionuț Arțăriși 4e24713
- added pycairo Requires
Ionuț Arțăriși 4e24713
- removed tests
Ionuț Arțăriși 4e24713
Ionuț Arțăriși 4e24713
* Tue Mar 23 2010 Ionuț C. Arțăriși <mapleoin@fedoraproject.org> - 0.5.2-1
Ionuț Arțăriși 4e24713
- first Fedora release