]>
Commit | Line | Data |
---|---|---|
80eebb0b JB |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without doc # Sphinx documentation | |
4 | %bcond_without tests # unit tests | |
5 | ||
6 | Summary: Sphinx spell checking extension | |
7 | Summary(pl.UTF-8): Rozszerzenie Sphinksa do sprawdzania pisowni | |
8 | Name: python3-sphinxcontrib-spelling | |
9 | Version: 5.0.0 | |
10 | Release: 1 | |
11 | License: BSD | |
12 | Group: Libraries/Python | |
13 | #Source0Download: https://pypi.org/simple/sphinxcontrib-spelling/ | |
14 | Source0: https://files.pythonhosted.org/packages/source/s/sphinxcontrib-spelling/sphinxcontrib-spelling-%{version}.tar.gz | |
15 | # Source0-md5: 48a3197bd3bf3c4ebc407433263b5cd5 | |
16 | URL: https://pypi.org/project/sphinxcontrib-spelling/ | |
17 | BuildRequires: python3-modules >= 1:3.5 | |
18 | BuildRequires: python3-pbr | |
19 | BuildRequires: python3-setuptools | |
20 | %if %{with tests} | |
21 | BuildRequires: python3-Sphinx >= 2.0.0 | |
22 | BuildRequires: python3-fixtures >= 3.0.0 | |
23 | BuildRequires: python3-pyenchant >= 1.6.5 | |
24 | BuildRequires: python3-pytest | |
25 | BuildRequires: python3-six | |
26 | BuildRequires: python3-subunit >= 0.0.18 | |
27 | BuildRequires: python3-testrepository >= 0.0.18 | |
28 | BuildRequires: python3-testscenarios >= 0.4 | |
29 | BuildRequires: python3-testtools >= 1.4.0 | |
30 | %endif | |
31 | BuildRequires: rpm-pythonprov | |
32 | BuildRequires: rpmbuild(macros) >= 1.714 | |
33 | %if %{with doc} || %{with tests} | |
34 | # en_US dict for enchant | |
35 | BuildRequires: aspell-en | |
36 | BuildRequires: enchant-aspell | |
37 | %endif | |
38 | %if %{with doc} | |
39 | BuildRequires: sphinx-pdg >= 2.0.0 | |
40 | %endif | |
41 | Requires: python3-modules >= 1:3.5 | |
42 | Requires: python3-sphinxcontrib | |
43 | BuildArch: noarch | |
44 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
45 | ||
46 | %description | |
47 | This package contains sphinxcontrib.spelling, a spelling checker for | |
48 | Sphinx-based documentation. It uses PyEnchant to produce a report | |
49 | showing misspelled words. | |
50 | ||
51 | %description -l pl.UTF-8 | |
52 | Ten pakiet zawiera sphinxcontrib.spelling - rozszerzenie do | |
53 | sprawdzania pisowni w dokumentacji opartej na Sphinksie. Wykorzystuje | |
54 | PyEnchant do tworzenia raportu wskazującego błędnie napisane słowa. | |
55 | ||
56 | %package apidocs | |
57 | Summary: API documentation for Python sphinxcontrib-spelling module | |
58 | Summary(pl.UTF-8): Dokumentacja API modułu Pythona sphinxcontrib-spelling | |
59 | Group: Documentation | |
60 | ||
61 | %description apidocs | |
62 | API documentation for Python sphinxcontrib-spelling module. | |
63 | ||
64 | %description apidocs -l pl.UTF-8 | |
65 | Dokumentacja API modułu Pythona sphinxcontrib-spelling. | |
66 | ||
67 | %prep | |
68 | %setup -q -n sphinxcontrib-spelling-%{version} | |
69 | ||
70 | %build | |
71 | %py3_build %{?with_tests:test} | |
72 | ||
73 | %if %{with doc} | |
74 | # enable spell checking to additionally verify particular | |
75 | # python+sphinx+sphinxcontrib.spelling combo | |
76 | ENABLE_SPELLING=1 \ | |
77 | PYTHONPATH=$(pwd) \ | |
78 | %{__make} -C docs html | |
79 | %endif | |
80 | ||
81 | %install | |
82 | rm -rf $RPM_BUILD_ROOT | |
83 | ||
84 | %py3_install | |
85 | ||
86 | %clean | |
87 | rm -rf $RPM_BUILD_ROOT | |
88 | ||
89 | %files | |
90 | %defattr(644,root,root,755) | |
91 | %doc AUTHORS ChangeLog LICENSE README | |
92 | %{py3_sitescriptdir}/sphinxcontrib/spelling | |
93 | %{py3_sitescriptdir}/sphinxcontrib_spelling-%{version}-py*.egg-info | |
94 | %{py3_sitescriptdir}/sphinxcontrib_spelling-%{version}-py*-nspkg.pth | |
95 | ||
96 | %if %{with doc} | |
97 | %files apidocs | |
98 | %defattr(644,root,root,755) | |
99 | %doc docs/build/html/{_static,*.html,*.js} | |
100 | %endif |