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