]> git.pld-linux.org Git - packages/python-incremental.git/blob - python-incremental.spec
rebuild with python 3.10
[packages/python-incremental.git] / python-incremental.spec
1 # TODO: apidocs (BR: pydoctor), tests (BR: twisted.trial >= 16.4.0, click >= 6.0)
2 #
3 # Conditional build:
4 %bcond_with     doc     # API documentation (pydoctor based)
5 %bcond_with     tests   # unit tests (require Twisted)
6 %bcond_without  python2 # CPython 2.x module
7 %bcond_without  python3 # CPython 3.x module
8
9 Summary:        Library that versions Python projects
10 Summary(pl.UTF-8):      Biblioteka wersjonująca projekty w Pythonie
11 Name:           python-incremental
12 Version:        21.3.0
13 Release:        2
14 License:        MIT
15 Group:          Libraries/Python
16 #Source0Download: https://pypi.org/simple/incremental/
17 Source0:        https://files.pythonhosted.org/packages/source/i/incremental/incremental-%{version}.tar.gz
18 # Source0-md5:  9f7ad12e0c05a12cee52a7350976c4e3
19 URL:            https://pypi.org/project/incremental/
20 %if %{with python2}
21 BuildRequires:  python-modules >= 1:2.7
22 BuildRequires:  python-setuptools
23 %if %{with tests}
24 BuildRequires:  python-click >= 6.0
25 BuildRequires:  python-twisted >= 16.4.0
26 %endif
27 %endif
28 %if %{with python3}
29 BuildRequires:  python3-modules >= 1:3.4
30 BuildRequires:  python3-setuptools
31 %if %{with tests}
32 BuildRequires:  python3-click >= 6.0
33 BuildRequires:  python3-twisted >= 16.4.0
34 %endif
35 %endif
36 BuildRequires:  rpm-pythonprov
37 BuildRequires:  rpmbuild(macros) >= 1.714
38 %if %{with doc}
39 BuildRequires:  pydoctor
40 %endif
41 # replace with other requires if defined in setup.py
42 Requires:       python-modules >= 1:2.7
43 BuildArch:      noarch
44 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45
46 %description
47 Incremental is a small library that versions your Python projects.
48
49 %description -l pl.UTF-8
50 Incremental to mała biblioteka do wersjonowania projektów w Pythonie.
51
52 %package -n python3-incremental
53 Summary:        Library that versions Python projects
54 Summary(pl.UTF-8):      Biblioteka wersjonująca projekty w Pythonie
55 Group:          Libraries/Python
56 Requires:       python3-modules >= 1:3.4
57
58 %description -n python3-incremental
59 Incremental is a small library that versions your Python projects.
60
61 %description -n python3-incremental -l pl.UTF-8
62 Incremental to mała biblioteka do wersjonowania projektów w Pythonie.
63
64 %package apidocs
65 Summary:        API documentation for Python incremental module
66 Summary(pl.UTF-8):      Dokumentacja API modułu Pythona incremental
67 Group:          Documentation
68
69 %description apidocs
70 API documentation for Python incremental module.
71
72 %description apidocs -l pl.UTF-8
73 Dokumentacja API modułu Pythona incremental.
74
75 %prep
76 %setup -q -n incremental-%{version}
77
78 %build
79 %if %{with python2}
80 %py_build
81
82 %if %{with tests}
83 trial-2 incremental
84 %endif
85 %endif
86
87 %if %{with python3}
88 %py3_build
89
90 %if %{with tests}
91 trial-3 incremental
92 %endif
93 %endif
94
95 %if %{with doc}
96 pydoctor -q --project-name incremental src/incremental
97 %endif
98
99 %install
100 rm -rf $RPM_BUILD_ROOT
101
102 %if %{with python2}
103 %py_install
104
105 %py_postclean
106 %endif
107
108 %if %{with python3}
109 %py3_install
110 %endif
111
112 %clean
113 rm -rf $RPM_BUILD_ROOT
114
115 %if %{with python2}
116 %files
117 %defattr(644,root,root,755)
118 %doc LICENSE NEWS.rst README.rst
119 %{py_sitescriptdir}/incremental
120 %{py_sitescriptdir}/incremental-%{version}-py*.egg-info
121 %endif
122
123 %if %{with python3}
124 %files -n python3-incremental
125 %defattr(644,root,root,755)
126 %doc LICENSE NEWS.rst README.rst
127 %{py3_sitescriptdir}/incremental
128 %{py3_sitescriptdir}/incremental-%{version}-py*.egg-info
129 %endif
130
131 %if %{with doc}
132 %files apidocs
133 %defattr(644,root,root,755)
134 %doc # TODO
135 %endif
This page took 0.029332 seconds and 3 git commands to generate.