]> git.pld-linux.org Git - SPECS.git/blob - python-more_itertools.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / python-more_itertools.spec
1 # NOTE: 5.0.0 is the last version supporting python2; for later versions see python3-more_itertools.spec
2 #
3 # Conditional build:
4 %bcond_without  doc     # Sphinx documentation
5 %bcond_without  tests   # unit tests
6 %bcond_without  python2 # CPython 2.x module
7 %bcond_with     python3 # CPython 3.x module [see python3-more_itertools.spec instead]
8
9 Summary:        More routines for operating on iterables, beyond itertools
10 Summary(pl.UTF-8):      Uzupełniające itertools dodatkowe funkcje do operowania na zmiennych iterowalnych
11 Name:           python-more_itertools
12 Version:        5.0.0
13 Release:        3
14 License:        MIT
15 Group:          Libraries/Python
16 #Source0Download: https://pypi.org/simple/more_itertools/
17 Source0:        https://files.pythonhosted.org/packages/source/m/more_itertools/more-itertools-%{version}.tar.gz
18 # Source0-md5:  f2ea58aa336ce6c13b7b225b3bbe305d
19 URL:            https://github.com/erikrose/more-itertools
20 BuildRequires:  rpm-pythonprov
21 BuildRequires:  rpmbuild(macros) >= 1.714
22 %if %{with python2}
23 BuildRequires:  python-modules >= 1:2.7
24 BuildRequires:  python-setuptools
25 %if %{with tests}
26 BuildRequires:  python-six >= 1.0.0
27 %endif
28 %endif
29 %if %{with python3}
30 BuildRequires:  python3-modules >= 1:3.4
31 BuildRequires:  python3-setuptools
32 %if %{with tests}
33 BuildRequires:  python3-six >= 1.0.0
34 %endif
35 %endif
36 %if %{with doc}
37 BuildRequires:  python3-sphinx_rtd_theme
38 BuildRequires:  sphinx-pdg-3
39 %endif
40 Requires:       python-modules >= 1:2.7
41 BuildArch:      noarch
42 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
43
44 %description
45 Python's itertools library is a gem - you can compose elegant
46 solutions for a variety of problems with the functions it provides. In
47 more-itertools we collect additional building blocks, recipes, and
48 routines for working with Python iterables.
49
50 %description -l pl.UTF-8
51 Biblioteka Pythona itertools to skarb - przy użyciu udostępnianych
52 funkcji można komponować eleganckie rozwiązania różnych problemów.
53 W pakiecie more-itertools zebrane są dodatkowe elementy konstrukcyjne,
54 przepisy i procedury do pracy z pythonowymi zmiennymi iterowalnymi.
55
56 %package -n python3-more_itertools
57 Summary:        More routines for operating on iterables, beyond itertools
58 Summary(pl.UTF-8):      Uzupełniające itertools dodatkowe funkcje do operowania na zmiennych iterowalnych
59 Group:          Libraries/Python
60 Requires:       python3-modules >= 1:3.4
61
62 %description -n python3-more_itertools
63 Python's itertools library is a gem - you can compose elegant
64 solutions for a variety of problems with the functions it provides. In
65 more-itertools we collect additional building blocks, recipes, and
66 routines for working with Python iterables.
67
68 %description -n python3-more_itertools -l pl.UTF-8
69 Biblioteka Pythona itertools to skarb - przy użyciu udostępnianych
70 funkcji można komponować eleganckie rozwiązania różnych problemów.
71 W pakiecie more-itertools zebrane są dodatkowe elementy konstrukcyjne,
72 przepisy i procedury do pracy z pythonowymi zmiennymi iterowalnymi.
73
74 %package apidocs
75 Summary:        API documentation for Python more-itertools module
76 Summary(pl.UTF-8):      Dokumentacja API modułu Pythona more-itertools
77 Group:          Documentation
78
79 %description apidocs
80 API documentation for Python more-itertools module.
81
82 %description apidocs -l pl.UTF-8
83 Dokumentacja API modułu Pythona more-itertools.
84
85 %prep
86 %setup -q -n more-itertools-%{version}
87
88 %build
89 %if %{with python2}
90 %py_build %{?with_tests:test}
91 %endif
92
93 %if %{with python3}
94 %py3_build %{?with_tests:test}
95 %endif
96
97 %if %{with doc}
98 %{__make} -C docs html \
99         SPHINXBUILD=sphinx-build-3
100 %endif
101
102 %install
103 rm -rf $RPM_BUILD_ROOT
104
105 %if %{with python2}
106 %py_install
107
108 %py_postclean
109 %endif
110
111 %if %{with python3}
112 %py3_install
113 %endif
114
115 %clean
116 rm -rf $RPM_BUILD_ROOT
117
118 %if %{with python2}
119 %files
120 %defattr(644,root,root,755)
121 %doc LICENSE README.rst
122 %{py_sitescriptdir}/more_itertools
123 %{py_sitescriptdir}/more_itertools-%{version}-py*.egg-info
124 %endif
125
126 %if %{with python3}
127 %files -n python3-more_itertools
128 %defattr(644,root,root,755)
129 %doc LICENSE README.rst
130 %{py3_sitescriptdir}/more_itertools
131 %{py3_sitescriptdir}/more_itertools-%{version}-py*.egg-info
132 %endif
133
134 %if %{with doc}
135 %files apidocs
136 %defattr(644,root,root,755)
137 %doc docs/_build/html/{_modules,_static,*.html,*.js}
138 %endif
This page took 0.556965 seconds and 3 git commands to generate.