]> git.pld-linux.org Git - SPECS.git/blob - mercurial.spec
SPECS updated Wed 1 May 10:14:00 CEST 2024
[SPECS.git] / mercurial.spec
1 # NOTE
2 # - Warning: tests will fail if at same time tests are running (shared hw for
3 #   builders) as fixed port 20059 is used.
4 # - Warning: tests will fail inside vserver as binding to localhost, peername
5 #   is not 127.0.0.1 (will be ip of interfaces/0/ip instead)
6 # - Tests fail with python3 (state as of 6.5.1)
7 #
8 # Conditional build:
9 %bcond_with     tests   # don't run tests
10
11 %define         webapp          hgweb
12 %define         webappdir       %{_sysconfdir}/webapps/%{webapp}
13 %define         appdir          %{_datadir}/%{webapp}
14 %define         cgibindir       %{_prefix}/lib/cgi-bin
15 Summary:        Mercurial Distributed SCM
16 Summary(pl.UTF-8):      Mercurial - rozproszony system kontroli wersji
17 Name:           mercurial
18 Version:        6.5.1
19 Release:        3
20 License:        GPL v2+
21 Group:          Development/Version Control
22 Source0:        https://www.mercurial-scm.org/release/%{name}-%{version}.tar.gz
23 # Source0-md5:  fccff6981f362466b8e9e0fa0de0ddb6
24
25 Source2:        %{name}-%{webapp}.config
26 Source3:        %{name}-%{webapp}-httpd.config
27
28 Patch1:         %{name}-clean-environment.patch
29 URL:            https://www.mercurial-scm.org/
30 BuildRequires:  gettext-tools
31 BuildRequires:  python3 >= 1:3.6
32 BuildRequires:  python3-devel >= 1:3.6
33 BuildRequires:  python3-docutils
34 BuildRequires:  python3-pygobject3-devel
35 BuildRequires:  rpm-pythonprov
36 BuildRequires:  rpmbuild(macros) >= 1.219
37 %{?with_tests:BuildRequires:    unzip}
38 Requires:       python3-%{name} = %{version}-%{release}
39 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40
41 %description
42 Mercurial is a fast, lightweight source control management system
43 designed for efficient handling of very large distributed projects.
44 Features include:
45 - O(1) delta-compressed file storage and retrieval scheme
46 - Complete cross-indexing of file and changesets for efficient
47   exploration of project history
48 - Robust SHA1-based integrity checking and append-only storage model
49 - Decentralized development model with arbitrary merging between trees
50 - High-speed HTTP-based network merge protocol
51 - Easy-to-use command-line interface
52 - Integrated stand-alone web interface
53 - Small Python codebase
54 - GPL license
55
56 %description -l pl.UTF-8
57 Mercurial to szybki, lekki system zarządzania kodem źródłowym
58 zaprojektowany do wydajnej obsługi bardzo dużych rozproszonych
59 projektów. Możliwości obejmują:
60 - przechowywanie skompresowanych plików różnic i schemat odtwarzania
61   O(1)
62 - pełne indeksowanie plików i zmian w celu szybkiego przeglądania
63   historii projektu
64 - silne, oparte na SHA1 sprawdzanie integralności oraz model
65   przechowywania z samym dołączaniem
66 - zdecentralizowany model rozwoju z dowolnym łączeniem między drzewami
67 - szybki protokół łączenia po sieci oparty na HTTP
68 - łatwy w użyciu interfejs linii poleceń
69 - zintegrowany samodzielny interfejs WWW
70 - mały kod podstawowy w Pythonie
71 - licencja GPL
72
73 %package -n python3-%{name}
74 Summary:        Mercurial Distributed SCM - Python libraries
75 Summary(pl.UTF-8):      Rozproszony system kontroli wersji Mercurial - biblioteki Pythona
76 Group:          Libraries/Python
77 Requires:       python3-modules >= 1:3.6
78 Obsoletes:      python-mercurial < 6.5.1
79 Conflicts:      mercurial < 3.5.2-2
80
81 %description -n python3-%{name}
82 Mercurial Distributed SCM - Python 3 libraries.
83
84 %description -n python3-%{name} -l pl.UTF-8
85 Rozproszony system kontroli wersji Mercurial - biblioteki Pythona 3.
86
87 %package hgweb
88 Summary:        Scripts for serving Mercurial repositories over HTTP
89 Summary(pl.UTF-8):      Skrypty do serwowania repozytoriów Mercuriala przez HTTP
90 Group:          Development/Version Control
91 Requires:       %{name} = %{version}-%{release}
92 Requires:       apache(mod_wsgi) >= 1.1
93 Requires:       webapps
94
95 %description hgweb
96 CGI scripts for serving Mercurial repositories.
97
98 %description hgweb -l pl.UTF-8
99 Skrypty CGI do serwowania repozytoriów Mercuriala.
100
101 %package hgk
102 Summary:        GUI for mercurial
103 Summary(pl.UTF-8):      Graficzny interfejs użytkownika dla systemu Mercurial
104 Group:          Development/Version Control
105 Requires:       %{name} = %{version}-%{release}
106 Requires:       python3-modules
107
108 %description hgk
109 A tool called that allows browsing the history of a repository in a
110 GUI.
111
112 To enable it add to .hgrc file:
113 [extensions]
114 hgk=
115
116 %description hgk -l pl.UTF-8
117 Narzędzie pozwalające na przeglądanie historii repozytorium w
118 graficznym interfejsie użytkownika.
119
120 Aby je uaktywnić, należy dodać do pliku .hgrc:
121 [extensions]
122 hgk=
123
124 %package -n bash-completion-%{name}
125 Summary:        Bash completion for Mercurial
126 Summary(pl.UTF-8):      Bashowe dopełnianie parametrów Mercuriala
127 Group:          Applications/Shells
128 Requires:       %{name} = %{epoch}:%{version}-%{release}
129 Requires:       bash-completion >= 2.0
130
131 %description -n bash-completion-%{name}
132 Bash completion for Mercurial.
133
134 %description -n bash-completion-%{name} -l pl.UTF-8
135 Bashowe dopełnianie parametrów Mercuriala.
136
137 %package -n zsh-completion-%{name}
138 Summary:        Zsh completion for Mercurial
139 Summary(pl.UTF-8):      Dopełnianie parametrów w zsh dla Mercuriala
140 Group:          Applications/Shells
141 Requires:       %{name} = %{epoch}:%{version}-%{release}
142 Requires:       zsh
143
144 %description -n zsh-completion-%{name}
145 Zsh completion for Mercurial.
146
147 %description -n zsh-completion-%{name} -l pl.UTF-8
148 Dopełnianie parametrów w zsh dla Mercuriala.
149
150 %prep
151 %setup -q
152
153 %patch1 -p1
154
155 # fails on builders due to lack of networking
156 %{__rm} tests/test-clonebundles.t
157
158 # flaky tests
159 %{__rm} tests/{test-convert-cvs-synthetic,test-convert-cvs,test-convert-cvs-detectmerge,test-convert-cvsnt-mergepoints,test-convert-cvs-branch,test-parse-date,test-gpg}.t
160
161 %{__sed} -i -e '1s|#!/usr/bin/env python3$|#!%{__python3}|' hgweb.cgi
162 %{__sed} -i -e '1s|#!/usr/bin/env wish$|#!/usr/bin/wish|' contrib/hgk
163
164 %build
165 %py3_build
166 %{__make} -C doc
167
168 %if %{with tests}
169 cd tests
170 %{__python3} run-tests.py %{?_smp_mflags} --verbose
171 %endif
172
173 %install
174 rm -rf $RPM_BUILD_ROOT
175 %py3_install
176
177 %{__rm} $RPM_BUILD_ROOT%{py3_sitedir}/mercurial/dummycert.pem
178
179 install -d $RPM_BUILD_ROOT{%{cgibindir},%{webappdir}}
180 install -p *.cgi $RPM_BUILD_ROOT%{cgibindir}
181 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}/%{webapp}.config
182 cp -p %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/apache.conf
183 cp -p %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/httpd.conf
184
185 install -p contrib/hgk $RPM_BUILD_ROOT%{_bindir}
186
187 install -d $RPM_BUILD_ROOT%{_mandir}/man{1,5}
188 cp -p doc/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
189 cp -p doc/*.5 $RPM_BUILD_ROOT%{_mandir}/man5
190
191 #py_comp $RPM_BUILD_ROOT%{py3_sitedir}
192
193 %clean
194 rm -rf $RPM_BUILD_ROOT
195
196 %triggerin hgweb -- apache1 < 1.3.37-3, apache1-base
197 %webapp_register apache %{webapp}
198
199 %triggerun hgweb -- apache1 < 1.3.37-3, apache1-base
200 %webapp_unregister apache %{webapp}
201
202 %triggerin hgweb -- apache < 2.2.0, apache-base
203 %webapp_register httpd %{webapp}
204
205 %triggerun hgweb -- apache < 2.2.0, apache-base
206 %webapp_unregister httpd %{webapp}
207
208 %files
209 %defattr(644,root,root,755)
210 %doc CONTRIBUTORS README.rst
211 %attr(755,root,root) %{_bindir}/hg
212 %{_mandir}/man1/*.1*
213 %{_mandir}/man5/*.5*
214
215 %files -n python3-%{name}
216 %defattr(644,root,root,755)
217 %{py3_sitedir}/hgdemandimport
218 %{py3_sitedir}/hgext
219 %{py3_sitedir}/hgext3rd
220 %dir %{py3_sitedir}/%{name}
221 %{py3_sitedir}/%{name}/__pycache__
222 %attr(755,root,root) %{py3_sitedir}/%{name}/*.so
223 %{py3_sitedir}/%{name}/*.py
224 %dir %{py3_sitedir}/%{name}/cext
225 %{py3_sitedir}/%{name}/cext/__pycache__
226 %{py3_sitedir}/%{name}/cext/*.py
227 %attr(755,root,root) %{py3_sitedir}/%{name}/cext/*.so
228 %{py3_sitedir}/%{name}/cffi
229 %{py3_sitedir}/%{name}/defaultrc
230 %{py3_sitedir}/%{name}/dirstateutils
231 %{py3_sitedir}/%{name}/helptext
232 %{py3_sitedir}/%{name}/hgweb
233 %{py3_sitedir}/%{name}/interfaces
234 %{py3_sitedir}/%{name}/pure
235 %{py3_sitedir}/%{name}/revlogutils
236 %{py3_sitedir}/%{name}/stabletailgraph
237 %{py3_sitedir}/%{name}/templates
238 %{py3_sitedir}/%{name}/testing
239 %dir %{py3_sitedir}/%{name}/thirdparty
240 %{py3_sitedir}/%{name}/thirdparty/__pycache__
241 %{py3_sitedir}/%{name}/thirdparty/*.py
242 %{py3_sitedir}/%{name}/thirdparty/attr
243 %attr(755,root,root) %{py3_sitedir}/%{name}/thirdparty/*.so
244 %dir %{py3_sitedir}/%{name}/thirdparty/zope
245 %{py3_sitedir}/%{name}/thirdparty/zope/__pycache__
246 %{py3_sitedir}/%{name}/thirdparty/zope/*.py
247 %dir %{py3_sitedir}/%{name}/thirdparty/zope/interface
248 %{py3_sitedir}/%{name}/thirdparty/zope/interface/__pycache__
249 %{py3_sitedir}/%{name}/thirdparty/zope/interface/*.py
250 %attr(755,root,root) %{py3_sitedir}/%{name}/thirdparty/zope/interface/*.so
251 %{py3_sitedir}/%{name}/upgrade_utils
252 %{py3_sitedir}/%{name}/utils
253 %dir %{py3_sitedir}/%{name}/locale
254 %lang(da) %{py3_sitedir}/%{name}/locale/da
255 %lang(de) %{py3_sitedir}/%{name}/locale/de
256 %lang(el) %{py3_sitedir}/%{name}/locale/el
257 %lang(fr) %{py3_sitedir}/%{name}/locale/fr
258 %lang(it) %{py3_sitedir}/%{name}/locale/it
259 %lang(ja) %{py3_sitedir}/%{name}/locale/ja
260 %lang(pt_BR) %{py3_sitedir}/%{name}/locale/pt_BR
261 %lang(ro) %{py3_sitedir}/%{name}/locale/ro
262 %lang(ru) %{py3_sitedir}/%{name}/locale/ru
263 %lang(sv) %{py3_sitedir}/%{name}/locale/sv
264 %lang(zh_CN) %{py3_sitedir}/%{name}/locale/zh_CN
265 %lang(zh_TW) %{py3_sitedir}/%{name}/locale/zh_TW
266 %{py3_sitedir}/mercurial-%{version}-py*.egg-info
267
268 %files hgweb
269 %defattr(644,root,root,755)
270 %attr(755,root,root) %{cgibindir}/hgweb.cgi
271 %dir %{webappdir}
272 %config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/apache.conf
273 %config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/hgweb.config
274 %config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/httpd.conf
275
276 %files hgk
277 %defattr(644,root,root,755)
278 %attr(755,root,root) %{_bindir}/hgk
279
280 %files -n bash-completion-%{name}
281 %defattr(644,root,root,755)
282 %{bash_compdir}/hg
283
284 %files -n zsh-completion-mercurial
285 %defattr(644,root,root,755)
286 %{zsh_compdir}/_hg
This page took 0.135307 seconds and 4 git commands to generate.