]> git.pld-linux.org Git - SPECS.git/blob - python-execnet.spec
SPECS updated Sun 1 Aug 20:13:02 CEST 2021
[SPECS.git] / python-execnet.spec
1 #
2 # Conditional build:
3 %bcond_without  python2 # CPython 2.x module
4 %bcond_without  python3 # CPython 3.x module
5 %bcond_without  doc     # Sphinx documentation
6 %bcond_with     tests   # py.test based tests [use network, need some environment]
7
8 %define         module  execnet
9 Summary:        Rapid multi-Python deployment
10 Summary(pl.UTF-8):      Szybkie wdrożenia na wielu Pythonach
11 Name:           python-%{module}
12 Version:        1.8.0
13 Release:        2
14 License:        MIT
15 Group:          Libraries/Python
16 #Source0Download: https://pypi.org/simple/execnet/
17 Source0:        https://files.pythonhosted.org/packages/source/e/execnet/%{module}-%{version}.tar.gz
18 # Source0-md5:  388ee8e2c60df6b578781c8aadb1359b
19 URL:            https://codespeak.net/execnet/
20 %if %{with python2}
21 BuildRequires:  python-modules >= 1:2.7
22 BuildRequires:  python-setuptools >= 7.0
23 BuildRequires:  python-setuptools_scm
24 %if %{with tests}
25 BuildRequires:  python-apipkg >= 1.4
26 BuildRequires:  python-py
27 BuildRequires:  python-pytest
28 BuildRequires:  python-pytest-timeout
29 %endif
30 %endif
31 %if %{with python3}
32 BuildRequires:  python3-modules >= 1:3.5
33 BuildRequires:  python3-setuptools >= 7.0
34 BuildRequires:  python3-setuptools_scm
35 %if %{with tests}
36 BuildRequires:  python3-apipkg >= 1.4
37 BuildRequires:  python3-py
38 BuildRequires:  python3-pytest
39 BuildRequires:  python3-pytest-timeout
40 %endif
41 %endif
42 BuildRequires:  rpm-pythonprov
43 BuildRequires:  rpmbuild(macros) >= 1.714
44 %if %{with doc}
45 BuildRequires:  sphinx-pdg
46 %endif
47 Requires:       python-modules >= 1:2.7
48 BuildArch:      noarch
49 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50
51 %description
52 execnet provides carefully tested means to ad-hoc interact with Python
53 interpreters across version, platform and network barriers. It
54 provides a minimal and fast API targetting the following uses:
55  - distribute tasks to local or remote processes
56  - write and deploy hybrid multi-process applications
57  - write scripts to administer multiple hosts
58
59 %description -l pl.UTF-8
60 execnet dostarcza uważnie przetestowane narzędzia do interakcji z
61 interpreterami Pythona zainstalowanych w różnych wersjach, na różnych
62 platformach i w różnych sieciach. Zapewnia minimalne i szybkie API
63 przeznaczone do następujących zastosowań:
64  - rozpraszania zadań na lokalne lub zdalne procesy
65  - pisania i wdrażania wieloprocesowych aplikacji hybrydowych
66  - pisania skryptów do administrowania wieloma hostami
67
68 %package -n python3-%{module}
69 Summary:        Rapid multi-Python deployment
70 Summary(pl.UTF-8):      Szybkie wdrożenia na wielu Pythonach
71 Group:          Libraries/Python
72 Requires:       python3-modules >= 1:3.5
73
74 %description -n python3-%{module}
75 execnet provides carefully tested means to ad-hoc interact with Python
76 interpreters across version, platform and network barriers. It
77 provides a minimal and fast API targetting the following uses:
78  - distribute tasks to local or remote processes
79  - write and deploy hybrid multi-process applications
80  - write scripts to administer multiple hosts
81
82 %description -n python3-%{module} -l pl.UTF-8
83 execnet dostarcza uważnie przetestowane narzędzia do interakcji z
84 interpreterami Pythona zainstalowanych w różnych wersjach, na różnych
85 platformach i w różnych sieciach. Zapewnia minimalne i szybkie API
86 przeznaczone do następujących zastosowań:
87  - rozpraszania zadań na lokalne lub zdalne procesy
88  - pisania i wdrażania wieloprocesowych aplikacji hybrydowych
89  - pisania skryptów do administrowania wieloma hostami
90
91 %package apidocs
92 Summary:        API documentation for Python execnet module
93 Summary(pl.UTF-8):      Dokumentacja API modułu Pythona execnet
94 Group:          Documentation
95
96 %description apidocs
97 API documentation for Python execnet module.
98
99 %description apidocs -l pl.UTF-8
100 Dokumentacja API modułu Pythona execnet.
101
102 %prep
103 %setup -q -n %{module}-%{version}
104
105 %build
106 %if %{with python2}
107 %py_build
108
109 %if %{with tests}
110 PYTHONPATH=$(pwd) \
111 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
112 PYTEST_PLUGINS="pytest_timeout" \
113 %{__python} -m pytest testing --timeout=20
114 %endif
115 %endif
116
117 %if %{with python3}
118 %py3_build
119
120 %if %{with tests}
121 PYTHONPATH=$(pwd) \
122 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
123 PYTEST_PLUGINS="pytest_timeout" \
124 %{__python3} -m pytest testing --timeout=20
125 %endif
126 %endif
127
128 %if %{with doc}
129 %{__make} -C doc html
130 %endif
131
132 %install
133 rm -rf $RPM_BUILD_ROOT
134
135 %if %{with python2}
136 %py_install
137
138 # no %%py_postclean !
139 # the source code might be run on a remote machine
140 %endif
141
142 %if %{with python3}
143 %py3_install
144 %endif
145
146 %clean
147 rm -rf $RPM_BUILD_ROOT
148
149 %if %{with python2}
150 %files
151 %defattr(644,root,root,755)
152 %doc CHANGELOG.rst ISSUES.txt LICENSE README.rst
153 %{py_sitescriptdir}/%{module}
154 %{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
155 %endif
156
157 %if %{with python3}
158 %files -n python3-%{module}
159 %defattr(644,root,root,755)
160 %doc CHANGELOG.rst ISSUES.txt LICENSE README.rst
161 %{py3_sitescriptdir}/%{module}
162 %{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
163 %endif
164
165 %if %{with doc}
166 %files apidocs
167 %defattr(644,root,root,755)
168 %doc doc/_build/html/{_images,_static,example,*.html,*.js}
169 %endif
This page took 0.06659 seconds and 3 git commands to generate.