]> git.pld-linux.org Git - packages/python-sphinxcontrib-apidoc.git/blob - python-sphinxcontrib-apidoc.spec
- disable pytest plugins
[packages/python-sphinxcontrib-apidoc.git] / python-sphinxcontrib-apidoc.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # unit tests
4 %bcond_without  python2 # CPython 2.x module
5 %bcond_without  python3 # CPython 3.x module
6
7 Summary:        Sphinx extension for running 'sphinx-apidoc' on each build
8 Summary(pl.UTF-8):      Rozszerzenie Sphinksa do uruchamiania 'sphinx-apidoc' przy każdym budowaniu
9 Name:           python-sphinxcontrib-apidoc
10 Version:        0.3.0
11 Release:        2
12 License:        BSD
13 Group:          Libraries/Python
14 #Source0Download: https://pypi.org/simple/sphinxcontrib-apidoc/
15 Source0:        https://files.pythonhosted.org/packages/source/s/sphinxcontrib-apidoc/sphinxcontrib-apidoc-%{version}.tar.gz
16 # Source0-md5:  baf2ad8a88918b04b54d0655aa273a82
17 URL:            https://pypi.org/project/sphinxcontrib-apidoc/
18 %if %{with python2}
19 BuildRequires:  python-modules >= 1:2.7
20 BuildRequires:  python-pbr >= 4.0
21 BuildRequires:  python-setuptools
22 %if %{with tests}
23 BuildRequires:  python-Sphinx >= 1.6.0
24 BuildRequires:  python-pytest >= 3.0
25 BuildRequires:  python-pytest < 4.0
26 %endif
27 %endif
28 %if %{with python3}
29 BuildRequires:  python3-modules >= 1:3.4
30 BuildRequires:  python3-pbr >= 4.0
31 BuildRequires:  python3-setuptools
32 %if %{with tests}
33 BuildRequires:  python3-Sphinx >= 1.6.0
34 BuildRequires:  python3-pytest >= 3.0
35 BuildRequires:  python3-pytest < 4.0
36 %endif
37 %endif
38 BuildRequires:  rpm-pythonprov
39 BuildRequires:  rpmbuild(macros) >= 1.714
40 Requires:       python-modules >= 1:2.7
41 Requires:       python-sphinxcontrib
42 BuildArch:      noarch
43 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44
45 %description
46 sphinx-apidoc is a tool for automatic generation of Sphinx sources
47 that, using the autodoc extension, documents a whole package in the
48 style of other automatic API documentation tools.
49
50 %description -l pl.UTF-8
51 sphinx-apidoc to narzędzie do automatycznego generowania źródeł
52 sphinksowych, które, przy użyciu rozszerzenia autodoc, dokumentują
53 cały pakiet w stylu innych narzędzi do automatycznego dokumentowania
54 API.
55
56 %package -n python3-sphinxcontrib-apidoc
57 Summary:        Sphinx extension for running 'sphinx-apidoc' on each build
58 Summary(pl.UTF-8):      Rozszerzenie Sphinksa do uruchamiania 'sphinx-apidoc' przy każdym budowaniu
59 Group:          Libraries/Python
60 Requires:       python3-modules >= 1:3.4
61 Requires:       python3-sphinxcontrib
62
63 %description -n python3-sphinxcontrib-apidoc
64 sphinx-apidoc is a tool for automatic generation of Sphinx sources
65 that, using the autodoc extension, documents a whole package in the
66 style of other automatic API documentation tools.
67
68 %description -n python3-sphinxcontrib-apidoc -l pl.UTF-8
69 sphinx-apidoc to narzędzie do automatycznego generowania źródeł
70 sphinksowych, które, przy użyciu rozszerzenia autodoc, dokumentują
71 cały pakiet w stylu innych narzędzi do automatycznego dokumentowania
72 API.
73
74 %prep
75 %setup -q -n sphinxcontrib-apidoc-%{version}
76
77 %build
78 %if %{with python2}
79 %py_build
80
81 %if %{with tests}
82 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
83 %{__python} -m pytest tests
84 %endif
85 %endif
86
87 %if %{with python3}
88 %py3_build
89
90 %if %{with tests}
91 PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
92 %{__python3} -m pytest tests
93 %endif
94 %endif
95
96 %install
97 rm -rf $RPM_BUILD_ROOT
98
99 %if %{with python2}
100 %py_install
101
102 %py_postclean
103 %endif
104
105 %if %{with python3}
106 %py3_install
107 %endif
108
109 %clean
110 rm -rf $RPM_BUILD_ROOT
111
112 %if %{with python2}
113 %files
114 %defattr(644,root,root,755)
115 %doc AUTHORS ChangeLog LICENSE README.rst
116 %{py_sitescriptdir}/sphinxcontrib/apidoc
117 %{py_sitescriptdir}/sphinxcontrib_apidoc-%{version}-py*.egg-info
118 %{py_sitescriptdir}/sphinxcontrib_apidoc-%{version}-py*-nspkg.pth
119 %endif
120
121 %if %{with python3}
122 %files -n python3-sphinxcontrib-apidoc
123 %defattr(644,root,root,755)
124 %doc AUTHORS ChangeLog LICENSE README.rst
125 %{py3_sitescriptdir}/sphinxcontrib/apidoc
126 %{py3_sitescriptdir}/sphinxcontrib_apidoc-%{version}-py*.egg-info
127 %{py3_sitescriptdir}/sphinxcontrib_apidoc-%{version}-py*-nspkg.pth
128 %endif
This page took 0.040059 seconds and 3 git commands to generate.