1 |
mitya |
1104367 |
%global pkgname repoze.sphinx.autointerface |
2 |
|
|
%global srcname %(tr . - <<< %{pkgname}) |
3 |
|
|
|
4 |
|
|
Name: python-%{srcname} |
5 |
|
|
Version: 0.8 |
6 |
kekepower |
1350745 |
Release: %mkrel 5 |
7 |
mitya |
1104369 |
Group: Development/Python |
8 |
mitya |
1104367 |
Summary: Auto-generate Sphinx API docs from Zope interfaces |
9 |
|
|
|
10 |
|
|
License: BSD |
11 |
|
|
URL: https://github.com/repoze/%{pkgname} |
12 |
|
|
Source0: https://github.com/repoze/%{pkgname}/archive/%{version}/%{pkgname}-%{version}.tar.gz |
13 |
|
|
BuildArch: noarch |
14 |
|
|
|
15 |
ovitters |
1146310 |
BuildRequires: pkgconfig(python2) |
16 |
kekepower |
1329015 |
BuildRequires: python2dist(setuptools) |
17 |
|
|
BuildRequires: python2dist(sphinx) |
18 |
|
|
BuildRequires: python2dist(zope.interface) |
19 |
mitya |
1104367 |
|
20 |
kekepower |
1329015 |
BuildRequires: pkgconfig(python3) |
21 |
|
|
BuildRequires: python3dist(setuptools) |
22 |
|
|
BuildRequires: python3dist(sphinx) |
23 |
|
|
BuildRequires: python3dist(zope.interface) |
24 |
mitya |
1104367 |
|
25 |
mitya |
1104369 |
%{?python_provide:%python_provide python-%{srcname}} |
26 |
|
|
|
27 |
mitya |
1104367 |
%global common_desc \ |
28 |
|
|
This package defines an extension for the Sphinx documentation system. \ |
29 |
|
|
The extension allows generation of API documentation by introspection of \ |
30 |
|
|
zope.interface instances in code. |
31 |
|
|
|
32 |
|
|
%description |
33 |
|
|
%{common_desc} |
34 |
|
|
|
35 |
kekepower |
1329015 |
%package -n python2-%{srcname} |
36 |
|
|
Group: Development/Python |
37 |
|
|
Summary: Auto-generate Sphinx API docs from Zope interfaces |
38 |
|
|
Requires: python2dist(sphinx) |
39 |
|
|
Requires: python2dist(zope.interface) |
40 |
|
|
|
41 |
|
|
%{?python_provide:%python_provide python2-%{srcname}} |
42 |
|
|
|
43 |
|
|
%description -n python2-%{srcname} |
44 |
|
|
%{common_desc} |
45 |
|
|
|
46 |
mitya |
1104367 |
%package -n python3-%{srcname} |
47 |
mitya |
1104369 |
Group: Development/Python |
48 |
mitya |
1104367 |
Summary: Auto-generate Sphinx API docs from Zope interfaces |
49 |
kekepower |
1329015 |
Requires: python3dist(sphinx) |
50 |
|
|
Requires: python3dist(zope.interface) |
51 |
mitya |
1104367 |
|
52 |
|
|
%{?python_provide:%python_provide python3-%{srcname}} |
53 |
|
|
|
54 |
|
|
%description -n python3-%{srcname} |
55 |
|
|
%{common_desc} |
56 |
|
|
|
57 |
|
|
%prep |
58 |
|
|
%setup -q -c |
59 |
|
|
|
60 |
|
|
cp -a %{pkgname}-%{version} python3-%{pkgname}-%{version} |
61 |
|
|
|
62 |
|
|
%build |
63 |
mitya |
1104369 |
|
64 |
mitya |
1104367 |
# Python 2 build |
65 |
|
|
pushd %{pkgname}-%{version} |
66 |
|
|
%py2_build |
67 |
|
|
python2 %{_bindir}/rst2html --no-datestamp CHANGES.rst CHANGES.html |
68 |
|
|
python2 %{_bindir}/rst2html --no-datestamp README.rst README.html |
69 |
|
|
popd |
70 |
|
|
|
71 |
|
|
# Python 3 build |
72 |
|
|
pushd python3-%{pkgname}-%{version} |
73 |
|
|
%py3_build |
74 |
|
|
popd |
75 |
|
|
|
76 |
|
|
%install |
77 |
mitya |
1104369 |
|
78 |
mitya |
1104367 |
# Python 2 install |
79 |
|
|
pushd %{pkgname}-%{version} |
80 |
|
|
%py2_install |
81 |
|
|
popd |
82 |
|
|
|
83 |
|
|
# Python 3 install |
84 |
|
|
pushd python3-%{pkgname}-%{version} |
85 |
|
|
%py3_install |
86 |
|
|
popd |
87 |
|
|
|
88 |
kekepower |
1329015 |
%files -n python2-%{srcname} |
89 |
mitya |
1104367 |
%doc %{pkgname}-%{version}/CHANGES.html %{pkgname}-%{version}/CONTRIBUTORS.txt |
90 |
|
|
%doc %{pkgname}-%{version}/README.html |
91 |
|
|
%license %{pkgname}-%{version}/COPYRIGHT.txt %{pkgname}-%{version}/LICENSE.txt |
92 |
|
|
%{python2_sitelib}/* |
93 |
|
|
|
94 |
|
|
%files -n python3-%{srcname} |
95 |
|
|
%doc %{pkgname}-%{version}/CHANGES.html %{pkgname}-%{version}/CONTRIBUTORS.txt |
96 |
|
|
%doc %{pkgname}-%{version}/README.html |
97 |
|
|
%license %{pkgname}-%{version}/COPYRIGHT.txt %{pkgname}-%{version}/LICENSE.txt |
98 |
|
|
%{python3_sitelib}/* |
99 |
|
|
|