]> git.pld-linux.org Git - packages/python-svgwrite.git/blame - python-svgwrite.spec
- disable one more test
[packages/python-svgwrite.git] / python-svgwrite.spec
CommitLineData
4cbbd4d5
ER
1#
2# Conditional build:
3%bcond_without doc # don't build doc
4%bcond_without tests # do not perform "make test"
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
7
8%define module svgwrite
9%define egg_name svgwrite
10%define pypi_name svgwrite
11Summary: Python 2 library to create SVG drawings
12Name: python-%{pypi_name}
fce7743c 13Version: 1.3.1
36a44a97 14Release: 2
4cbbd4d5
ER
15License: MIT
16Group: Libraries/Python
fce7743c
JR
17Source0: https://github.com/mozman/svgwrite/archive/v%{version}/%{module}-%{version}.tar.gz
18# Source0-md5: a3d9311578538ba5acd6bb98d14cae38
19URL: https://github.com/mozman/svgwrite
4cbbd4d5
ER
20BuildRequires: rpm-pythonprov
21BuildRequires: rpmbuild(macros) >= 1.714
22BuildArch: noarch
23%if %{with python2}
24BuildRequires: python-modules
25BuildRequires: python-pyparsing
26BuildRequires: python-setuptools
27%endif
28%if %{with python3}
29BuildRequires: python3-modules
30BuildRequires: python3-pyparsing
31BuildRequires: python3-setuptools
32BuildRequires: python3-setuptools
33%endif
34BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36%description
37Python 2 library to create SVG drawings.
38
39%package -n python3-%{pypi_name}
40Summary: Python 3 library to create SVG drawings
41Requires: python3-pyparsing
42Requires: python3-setuptools
43
44%description -n python3-%{pypi_name}
45Python 3 library to create SVG drawings.
46
47%prep
48%setup -q -n %{pypi_name}-%{version}
49
fce7743c
JR
50# test is hosed and fails on the order of attr in a tag
51%{__rm} tests/test_pretty_xml.py
36a44a97
JR
52# needs network access
53%{__rm} tests/test_style.py
fce7743c 54
4cbbd4d5
ER
55%build
56%py3_build
57%py_build
58
59%if %{with tests}
60%{__python3} -m unittest discover -s tests
61%{__python} -m unittest discover -s tests
62%endif
63
64%install
65rm -rf $RPM_BUILD_ROOT
66%py3_install
67%py_install
68
69%clean
70rm -rf $RPM_BUILD_ROOT
71
72%if %{with python2}
73%files
74%defattr(644,root,root,755)
75%doc NEWS.rst README.rst LICENSE.TXT
76%{py_sitescriptdir}/%{module}
77%{py_sitescriptdir}/%{egg_name}-%{version}-py%{py_ver}.egg-info
78%endif
79
80%if %{with python3}
81%files -n python3-%{pypi_name}
82%defattr(644,root,root,755)
83%doc NEWS.rst README.rst LICENSE.TXT
84%{py3_sitescriptdir}/%{module}
85%{py3_sitescriptdir}/%{pypi_name}-%{version}-py%{py3_ver}.egg-info
86%endif
This page took 0.121287 seconds and 4 git commands to generate.