]> git.pld-linux.org Git - packages/python-subunit.git/blame - python-subunit.spec
- separated subunit-python* packages with tools; release 2
[packages/python-subunit.git] / python-subunit.spec
CommitLineData
fd3c6536 1#
fd3c6536 2# Conditional build:
69bf9949
JB
3%bcond_without python2 # CPython 2.x module and tools
4%bcond_without python3 # CPython 3.x module and tools
66bb170b 5%bcond_without tests # test target
fd3c6536
JB
6
7%define module template
8Summary: subunit - streaming protocol for test results
9Summary(pl.UTF-8): subunit - protokół strumieniowy do wyników testów
10Name: python-subunit
11Version: 1.2.0
69bf9949 12Release: 2
fd3c6536
JB
13License: Apache v2.0 or BSD
14Group: Libraries/Python
15#Source0Download: https://pypi.python.org/simple/python-subunit/
16Source0: https://pypi.python.org/packages/source/p/python-subunit/%{name}-%{version}.tar.gz
17# Source0-md5: 3305455dfe22e2b8666531909c026a2f
18URL: https://pypi.python.org/pypi/python-subunit
19BuildRequires: rpm-pythonprov
20BuildRequires: rpmbuild(macros) >= 1.714
21%if %{with python2}
22BuildRequires: python-extras
23BuildRequires: python-modules >= 1:2.6
24BuildRequires: python-testtools >= 0.9.34
25%if %{with tests}
26BuildRequires: python-fixtures
27BuildRequires: python-hypothesis
28BuildRequires: python-testscenarios
29%endif
30%endif
31%if %{with python3}
32BuildRequires: python3-extras
33BuildRequires: python3-modules >= 1:3.2
34BuildRequires: python3-testtools >= 0.9.34
35%if %{with tests}
36BuildRequires: python3-fixtures
37BuildRequires: python3-hypothesis
38BuildRequires: python3-testscenarios
39%endif
40%endif
41Requires: python-extras
42Requires: python-modules >= 1:2.6
43Requires: python-testtools >= 0.9.34
44BuildArch: noarch
45BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47%description
48Subunit is a streaming protocol for test results.
49
69bf9949
JB
50This package contains Python 2.x modules.
51
fd3c6536
JB
52%description -l pl.UTF-8
53Subunit to protokół strumieniowy przeznaczony do wyników testów.
54
69bf9949
JB
55Ten pakiet zawiera moduły Pythona 2.x.
56
57%package -n subunit-python
58Summary: Python tools for subunit streaming protocol for test results
59Summary(pl.UTF-8): Pythonowe narzędzia dla protokołu strumieniowego do wyników testów subunit
60Group: Development/Tools
61Requires: subunit-python2 = %{version}-%{release}
62
63%description -n subunit-python
64Python tools for subunit streaming protocol for test results.
65
66%description -n subunit-python -l pl.UTF-8
67Pythonowe narzędzia dla protokołu strumieniowego do wyników testów
68subunit.
69
70%package -n subunit-python2
71Summary: Python 2 tools for subunit streaming protocol for test results
72Summary(pl.UTF-8): Narzędzia Pythona 2 dla protokołu strumieniowego do wyników testów subunit
73Group: Development/Tools
74Requires: python-subunit = %{version}-%{release}
75
76%description -n subunit-python2
77Python 2 tools for subunit streaming protocol for test results.
78
79%description -n subunit-python2 -l pl.UTF-8
80Narzędzia Pythona 2 dla protokołu strumieniowego do wyników testów
81subunit.
82
fd3c6536
JB
83%package -n python3-subunit
84Summary: subunit - streaming protocol for test results
85Summary(pl.UTF-8): subunit - protokół strumieniowy do wyników testów
86Group: Libraries/Python
87Requires: python3-extras
88Requires: python3-modules >= 1:3.2
89Requires: python3-testtools >= 0.9.34
90
91%description -n python3-subunit
92Subunit is a streaming protocol for test results.
93
69bf9949
JB
94This package contains Python 2.x modules.
95
fd3c6536
JB
96%description -n python3-subunit -l pl.UTF-8
97Subunit to protokół strumieniowy przeznaczony do wyników testów.
98
69bf9949
JB
99Ten pakiet zawiera moduły Pythona 2.x.
100
101%package -n subunit-python3
102Summary: Python 3 tools for subunit streaming protocol for test results
103Summary(pl.UTF-8): Narzędzia Pythona 3 dla protokołu strumieniowego do wyników testów subunit
104Group: Development/Tools
105Requires: python3-subunit = %{version}-%{release}
106
107%description -n subunit-python3
108Python 3 tools for subunit streaming protocol for test results.
109
110%description -n subunit-python3 -l pl.UTF-8
111Narzędzia Pythona 3 dla protokołu strumieniowego do wyników testów
112subunit.
113
fd3c6536
JB
114%prep
115%setup -q
116
117%build
118%if %{with python2}
119%py_build %{?with_tests:test}
120%endif
121
122%if %{with python3}
123%py3_build %{?with_tests:test}
124%endif
125
126%install
127rm -rf $RPM_BUILD_ROOT
128
129%if %{with python3}
130%py3_install
131
132%{__rm} -r $RPM_BUILD_ROOT%{py3_sitescriptdir}/subunit/tests
133
134for f in $RPM_BUILD_ROOT%{_bindir}/* ; do
135 %{__mv} "$f" "${f}-3"
136done
137%endif
138
139%if %{with python2}
140%py_install
141
142%{__rm} -r $RPM_BUILD_ROOT%{py_sitescriptdir}/subunit/tests
143%py_postclean
144
c2540c56 145for f in $RPM_BUILD_ROOT%{_bindir}/*[!3]; do
fd3c6536
JB
146 %{__mv} "$f" "${f}-2"
147 ln -sf $(basename $f)-2 "$f"
148done
149%endif
150
151%clean
152rm -rf $RPM_BUILD_ROOT
153
154%if %{with python2}
155%files
156%defattr(644,root,root,755)
157%doc NEWS README.rst
69bf9949
JB
158%{py_sitescriptdir}/subunit
159%{py_sitescriptdir}/python_subunit-%{version}-py*.egg-info
160
161%files -n subunit-python
162%defattr(644,root,root,755)
fd3c6536
JB
163%attr(755,root,root) %{_bindir}/subunit-1to2
164%attr(755,root,root) %{_bindir}/subunit-2to1
165%attr(755,root,root) %{_bindir}/subunit-filter
166%attr(755,root,root) %{_bindir}/subunit-ls
167%attr(755,root,root) %{_bindir}/subunit-notify
168%attr(755,root,root) %{_bindir}/subunit-output
169%attr(755,root,root) %{_bindir}/subunit-stats
170%attr(755,root,root) %{_bindir}/subunit-tags
171%attr(755,root,root) %{_bindir}/subunit2csv
172%attr(755,root,root) %{_bindir}/subunit2gtk
173%attr(755,root,root) %{_bindir}/subunit2junitxml
174%attr(755,root,root) %{_bindir}/subunit2pyunit
175%attr(755,root,root) %{_bindir}/tap2subunit
69bf9949
JB
176
177%files -n subunit-python2
178%defattr(644,root,root,755)
fd3c6536
JB
179%attr(755,root,root) %{_bindir}/subunit-1to2-2
180%attr(755,root,root) %{_bindir}/subunit-2to1-2
181%attr(755,root,root) %{_bindir}/subunit-filter-2
182%attr(755,root,root) %{_bindir}/subunit-ls-2
183%attr(755,root,root) %{_bindir}/subunit-notify-2
184%attr(755,root,root) %{_bindir}/subunit-output-2
185%attr(755,root,root) %{_bindir}/subunit-stats-2
186%attr(755,root,root) %{_bindir}/subunit-tags-2
187%attr(755,root,root) %{_bindir}/subunit2csv-2
188%attr(755,root,root) %{_bindir}/subunit2gtk-2
189%attr(755,root,root) %{_bindir}/subunit2junitxml-2
190%attr(755,root,root) %{_bindir}/subunit2pyunit-2
191%attr(755,root,root) %{_bindir}/tap2subunit-2
fd3c6536
JB
192%endif
193
194%if %{with python3}
195%files -n python3-subunit
196%defattr(644,root,root,755)
197%doc NEWS README.rst
69bf9949
JB
198%{py3_sitescriptdir}/subunit
199%{py3_sitescriptdir}/python_subunit-%{version}-py*.egg-info
200
201%files -n subunit-python3
202%defattr(644,root,root,755)
fd3c6536
JB
203%attr(755,root,root) %{_bindir}/subunit-1to2-3
204%attr(755,root,root) %{_bindir}/subunit-2to1-3
205%attr(755,root,root) %{_bindir}/subunit-filter-3
206%attr(755,root,root) %{_bindir}/subunit-ls-3
207%attr(755,root,root) %{_bindir}/subunit-notify-3
208%attr(755,root,root) %{_bindir}/subunit-output-3
209%attr(755,root,root) %{_bindir}/subunit-stats-3
210%attr(755,root,root) %{_bindir}/subunit-tags-3
211%attr(755,root,root) %{_bindir}/subunit2csv-3
212%attr(755,root,root) %{_bindir}/subunit2gtk-3
213%attr(755,root,root) %{_bindir}/subunit2junitxml-3
214%attr(755,root,root) %{_bindir}/subunit2pyunit-3
215%attr(755,root,root) %{_bindir}/tap2subunit-3
fd3c6536 216%endif
This page took 0.178479 seconds and 4 git commands to generate.