]> git.pld-linux.org Git - packages/python-pluggy.git/blob - python-pluggy.spec
Initial version 0.3.1
[packages/python-pluggy.git] / python-pluggy.spec
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  pluggy
9 Summary:        Plugin and hook calling mechanisms for Python
10 Summary(pl.UTF-8):      Mechanizmy wtyczek dla Pythona
11 Name:           python-%{module}
12 Version:        0.3.1
13 Release:        1
14 License:        MIT
15 Group:          Libraries/Python
16 Source0:        https://pypi.python.org/packages/1b/a9/6f5f80b75a8d84d21a8a13486fe26a2da9f043f93b464b2e3928be256dc4/pluggy-%{version}.tar.gz
17 # Source0-md5:  ecdd791e309f60668b66fec97c2ee7db
18 URL:            https://pypi.python.org/pypi/%{module}
19 BuildRequires:  rpm-pythonprov
20 BuildRequires:  rpmbuild(macros) >= 1.714
21 %if %{with python2}
22 BuildRequires:  python-modules
23 %endif
24 %if %{with python3}
25 BuildRequires:  python3-modules
26 %endif
27 Requires:       python-modules
28 BuildArch:      noarch
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %description
32 Plugin manager as used by pytest but stripped of pytest specific
33 details.
34
35 %description -l pl.UTF-8
36 Zarządca wtyczek tak jak używany przez pytest, ale pozbawiony detali
37 specyficznych dla pytest.
38
39 %package -n python3-%{module}
40 Summary:        Plugin and hook calling mechanisms for Python
41 Summary(pl.UTF-8):      Mechanizmy wtyczek dla Pythona
42 Group:          Libraries/Python
43 Requires:       python3-modules
44
45 %description -n python3-%{module}
46 Plugin manager as used by pytest but stripped of pytest specific
47 details.
48
49 %description -n python3-%{module} -l pl.UTF-8
50 Zarządca wtyczek tak jak używany przez pytest, ale pozbawiony detali
51 specyficznych dla pytest.
52
53 %package apidocs
54 Summary:        %{module} API documentation
55 Summary(pl.UTF-8):      Dokumentacja API %{module}
56 Group:          Documentation
57
58 %description apidocs
59 API documentation for %{module}.
60
61 %description apidocs -l pl.UTF-8
62 Dokumentacja API %{module}.
63
64 %prep
65 %setup -q -n %{module}-%{version}
66
67 %build
68 %if %{with python2}
69 %py_build %{?with_tests:test}
70 %endif
71
72 %if %{with python3}
73 %py3_build %{?with_tests:test}
74 %endif
75
76 %if %{with doc}
77 cd docs
78 %{__make} -j1 html
79 rm -rf _build/html/_sources
80 %endif
81
82 %install
83 rm -rf $RPM_BUILD_ROOT
84
85 %if %{with python2}
86 %py_install
87
88 %py_postclean
89 %endif
90
91 %if %{with python3}
92 %py3_install
93 %endif
94
95 %clean
96 rm -rf $RPM_BUILD_ROOT
97
98 %if %{with python2}
99 %files
100 %defattr(644,root,root,755)
101 %doc CHANGELOG README.rst
102 %{py_sitescriptdir}/%{module}.py*
103 %if "%{py_ver}" > "2.4"
104 %{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
105 %endif
106 %endif
107
108 %if %{with python3}
109 %files -n python3-%{module}
110 %defattr(644,root,root,755)
111 %doc CHANGELOG README.rst
112 %{py3_sitescriptdir}/%{module}.py
113 %{py3_sitescriptdir}/__pycache__/%{module}.*.pyc
114 %{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
115 %endif
116
117 %if %{with doc}
118 %files apidocs
119 %defattr(644,root,root,755)
120 %doc docs/_build/html/*
121 %endif
This page took 0.094899 seconds and 3 git commands to generate.