]> git.pld-linux.org Git - packages/python-sphinx_rtd_theme.git/blob - python-sphinx_rtd_theme.spec
c5980f937997acd3ee4a4505be49ad5de27b727d
[packages/python-sphinx_rtd_theme.git] / python-sphinx_rtd_theme.spec
1 #
2 # Conditional build:
3 %bcond_without  python2 # CPython 2.x module
4 %bcond_without  python3 # CPython 3.x module
5 %bcond_without  tests   # unit tests
6
7 %define         module  sphinx_rtd_theme
8 Summary:        ReadTheDocs.org theme for Sphinx
9 Summary(pl.UTF-8):      Motyw ReadTheDocs.org dla Sphinksa
10 Name:           python-%{module}
11 Version:        0.4.3
12 Release:        5
13 License:        MIT
14 Group:          Libraries/Python
15 #Source0Download: https://pypi.org/simple/sphinx_rtd_theme/
16 Source0:        https://files.pythonhosted.org/packages/source/s/sphinx_rtd_theme/%{module}-%{version}.tar.gz
17 # Source0-md5:  6c50f30bc39046f497d336039a0c13fa
18 URL:            https://github.com/snide/sphinx_rtd_theme/
19 BuildRequires:  rpm-pythonprov
20 BuildRequires:  rpmbuild(macros) >= 1.714
21 %if %{with python2}
22 BuildRequires:  python-modules >= 1:2.7
23 BuildRequires:  python-setuptools
24 %if %{with tests}
25 BuildRequires:  python-pytest
26 BuildRequires:  python-readthedocs-sphinx-ext
27 %endif
28 %endif
29 %if %{with python3}
30 BuildRequires:  python3-modules >= 1:3.3
31 BuildRequires:  python3-setuptools
32 %if %{with tests}
33 BuildRequires:  python3-pytest
34 BuildRequires:  python3-readthedocs-sphinx-ext
35 %endif
36 %endif
37 Requires:       python-modules >= 1:2.7
38 BuildArch:      noarch
39 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40
41 %description
42 This is a mobile-friendly Sphinx theme made for readthedocs.org.
43
44 %description -l pl.UTF-8
45 Ten pakiet zawiera przyjazny dla urządzeń przenośnych motyw Sphinksa
46 wykonany przez readthedocs.org.
47
48 %package -n python3-%{module}
49 Summary:        ReadTheDocs.org theme for Sphinx
50 Summary(pl.UTF-8):      Motyw ReadTheDocs.org dla Sphinksa
51 Group:          Libraries/Python
52 Requires:       python3-modules >= 1:3.3
53
54 %description -n python3-%{module}
55 This is a mobile-friendly Sphinx theme made for readthedocs.org.
56
57 %description -n python3-%{module} -l pl.UTF-8
58 Ten pakiet zawiera przyjazny dla urządzeń przenośnych motyw Sphinksa
59 wykonany przez readthedocs.org.
60
61 %prep
62 %setup -q -n %{module}-%{version}
63
64 %build
65 %if %{with python2}
66 %py_build
67
68 %if %{with tests}
69 %{__python} -m pytest tests
70 %endif
71 %endif
72
73 %if %{with python3}
74 %py3_build
75
76 %if %{with tests}
77 %{__python3} -m pytest tests
78 %endif
79 %endif
80
81 %install
82 rm -rf $RPM_BUILD_ROOT
83
84 %if %{with python2}
85 %py_install
86
87 %py_postclean
88 %endif
89
90 %if %{with python3}
91 %py3_install
92 %endif
93
94 %clean
95 rm -rf $RPM_BUILD_ROOT
96
97 %if %{with python2}
98 %files
99 %defattr(644,root,root,755)
100 %doc LICENSE README.rst
101 %{py_sitescriptdir}/%{module}
102 %{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
103 %endif
104
105 %if %{with python3}
106 %files -n python3-%{module}
107 %defattr(644,root,root,755)
108 %doc LICENSE README.rst
109 %{py3_sitescriptdir}/%{module}
110 %{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
111 %endif
This page took 0.051093 seconds and 2 git commands to generate.