]>
Commit | Line | Data |
---|---|---|
1 | # | |
2 | # Conditional build: | |
3 | %bcond_without tests # don't perform make test | |
4 | %bcond_with tests_cvs # perform tests which use CVS | |
5 | %bcond_without tests_svn # perform tests which use subversion | |
6 | %bcond_without doc # skip building/packaging docs/manuals (takes some time) | |
7 | %bcond_without pcre # perl-compatible regexes support | |
8 | %bcond_without gnome_keyring # build without gnome keyring support | |
9 | ||
10 | %include /usr/lib/rpm/macros.perl | |
11 | Summary: Distributed version control system focused on speed, effectivity and usability | |
12 | Summary(pl.UTF-8): Rozproszony system śledzenia treści skupiony na szybkości, wydajności i użyteczności | |
13 | Name: git-core | |
14 | Version: 1.9.0 | |
15 | Release: 3 | |
16 | License: GPL v2 | |
17 | Group: Development/Tools | |
18 | Source0: http://git-core.googlecode.com/files/git-%{version}.tar.gz | |
19 | # Source0-md5: e16c14b27c644b8e0dd72bdb5ff77450 | |
20 | Source1: %{name}-gitweb.conf | |
21 | Source2: %{name}-gitweb-httpd.conf | |
22 | Source3: %{name}-gitweb-lighttpd.conf | |
23 | Source4: %{name}.sysconfig | |
24 | Source5: %{name}.inet | |
25 | Source6: %{name}.init | |
26 | Source7: gitolite.pl | |
27 | Patch0: %{name}-tests.patch | |
28 | Patch1: %{name}-key-bindings.patch | |
29 | Patch2: %{name}-sysconfdir.patch | |
30 | Patch3: cherry-picked-commitlog.patch | |
31 | Patch4: %{name}-svn-exit-errors.patch | |
32 | URL: http://git-scm.com/ | |
33 | BuildRequires: autoconf >= 2.59 | |
34 | BuildRequires: automake | |
35 | BuildRequires: curl-devel | |
36 | BuildRequires: expat-devel | |
37 | BuildRequires: gettext-devel | |
38 | %if %{with gnome_keyring} | |
39 | BuildRequires: libgnome-keyring-devel | |
40 | BuildRequires: pkgconfig | |
41 | %endif | |
42 | BuildRequires: openssl-devel | |
43 | %{?with_pcre:BuildRequires: pcre-devel} | |
44 | BuildRequires: perl-Error > 0.15 | |
45 | BuildRequires: perl-base | |
46 | BuildRequires: python-devel | |
47 | BuildRequires: rpm-perlprov >= 4.1-13 | |
48 | BuildRequires: rpm-pythonprov | |
49 | BuildRequires: rpmbuild(macros) >= 1.673 | |
50 | BuildRequires: tcl | |
51 | BuildRequires: zlib-devel | |
52 | %if %{with doc} | |
53 | BuildRequires: asciidoc >= 7.1.2-3 | |
54 | BuildRequires: docbook-dtd45-xml | |
55 | BuildRequires: xmlto | |
56 | %endif | |
57 | %if %{with tests} | |
58 | %if %{with tests_cvs} | |
59 | # tests failed sometimes when using nserver/cvsnt client so enforce pure cvs here | |
60 | BuildRequires: cvs-gnu-client < 1.13 | |
61 | BuildRequires: cvs-gnu-client >= 1.12 | |
62 | %endif | |
63 | %{?with_tests_svn:BuildRequires: subversion} | |
64 | Conflicts: pdksh < 5.2.14-46 | |
65 | %endif | |
66 | Requires: coreutils | |
67 | Requires: diffutils | |
68 | Requires: findutils | |
69 | Requires: grep | |
70 | Requires: openssh-clients | |
71 | Requires: perl-Error | |
72 | Requires: perl-Git = %{version}-%{release} | |
73 | Requires: sed | |
74 | Suggests: git-core-bzr | |
75 | Suggests: git-core-cvs | |
76 | Suggests: git-core-hg | |
77 | Suggests: git-core-p4 | |
78 | Suggests: git-core-svn | |
79 | Suggests: less | |
80 | Suggests: rsync | |
81 | Obsoletes: python-Git | |
82 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
83 | ||
84 | # html docs have links to txt files | |
85 | %define _noautocompressdoc *.txt | |
86 | ||
87 | %define webapp gitweb | |
88 | %define webappdir %{_sysconfdir}/webapps/%{webapp} | |
89 | %define appdir %{_datadir}/%{webapp} | |
90 | %define cgibindir %{_prefix}/lib/cgi-bin | |
91 | ||
92 | %description | |
93 | "git" can mean anything, depending on your mood. | |
94 | ||
95 | - random three-letter combination that is pronounceable, and not | |
96 | actually used by any common UNIX command. The fact that it is a | |
97 | mispronunciation of "get" may or may not be relevant. | |
98 | - stupid. contemptible and despicable. simple. Take your pick from the | |
99 | dictionary of slang. | |
100 | - "global information tracker": you're in a good mood, and it actually | |
101 | works for you. Angels sing, and a light suddenly fills the room. | |
102 | - "goddamn idiotic truckload of sh*t": when it breaks | |
103 | ||
104 | This is a stupid (but extremely fast) directory content manager. It | |
105 | doesn't do a whole lot, but what it 'does' do is track directory | |
106 | contents efficiently. | |
107 | ||
108 | %description -l pl.UTF-8 | |
109 | "git" może oznaczać cokolwiek, w zależności od nastroju. | |
110 | ||
111 | - losową kombinację trzech liter, która jest wymawialna i właściwie | |
112 | nie używana przez żadne popularne polecenie uniksowe. Fakt, że jest to | |
113 | błędna pisownia słowa "get" może mieć lub nie mieć znaczenia. | |
114 | - głupi, pogardliwy, prosty. Można wybrać ze słownika slangu. | |
115 | - "global information tracker" (narzędzie do globalnego śledzenia | |
116 | informacji) - jeśli jesteśmy w dobrym nastroju i git akurat działa. | |
117 | Anioły śpiewają, a światło niespodziewanie wypełnia pokój. | |
118 | - "goddamn idiotic truckload of sh*t" (przeklęty idiotyczny ładunek | |
119 | g*) - kiedy się zepsuje. | |
120 | ||
121 | Jest to prymitywny (ale bardzo szybki) zarządca treści słownikowej. | |
122 | Nie robi wiele, ale to, co "robi", to wydajne śledzenie zawartości | |
123 | katalogu. | |
124 | ||
125 | %package doc | |
126 | Summary: Documentation for git-core | |
127 | Summary(pl.UTF-8): Dokumentacja do git-core | |
128 | Group: Documentation | |
129 | ||
130 | %description doc | |
131 | Documentation for git-core. | |
132 | ||
133 | %description doc -l pl.UTF-8 | |
134 | Dokumentacja do git-core. | |
135 | ||
136 | %description doc -l fr.UTF-8 | |
137 | Javadoc pour git-core. | |
138 | ||
139 | %package daemon-inetd | |
140 | Summary: Files necessary to run git-daemon as an inetd service | |
141 | Summary(pl.UTF-8): Pliki niezbędne do uruchomienia git-daemona w trybie usługi inetd | |
142 | Group: Networking/Daemons | |
143 | Requires: %{name} = %{version}-%{release} | |
144 | Requires: setup >= 2.4.11-1 | |
145 | Provides: git-core-daemon | |
146 | Obsoletes: git-core-daemon | |
147 | Obsoletes: git-core-daemon-standalone | |
148 | ||
149 | %description daemon-inetd | |
150 | Git-daemon is a really simple TCP git daemon that can serve git | |
151 | repositories. This package provides all necessarry files to run | |
152 | git-daemon as an inetd service. | |
153 | ||
154 | %description daemon-inetd -l pl.UTF-8 | |
155 | Git-daemon to prosty demon git korzystający z protokołu TCP do | |
156 | udostępniania repozytoriów git. Ten pakiet dostarcza pliki potrzebne | |
157 | do uruchomienia git-demona w trybie usługi inetd. | |
158 | ||
159 | %package daemon-standalone | |
160 | Summary: Files necessary to run git-daemon as a standalone service | |
161 | Summary(pl.UTF-8): Pliki niezbędne do uruchomienia git-daemona w trybie usługi samodzielnej | |
162 | Group: Networking/Daemons | |
163 | Requires: %{name} = %{version}-%{release} | |
164 | Provides: git-core-daemon | |
165 | Obsoletes: git-core-daemon | |
166 | Obsoletes: git-core-daemon-inetd | |
167 | ||
168 | %description daemon-standalone | |
169 | Git-daemon is a really simple TCP git daemon that can serve git | |
170 | repositories. This package provides all necessarry files to run | |
171 | git-daemon as an standalone service. | |
172 | ||
173 | %description daemon-standalone -l pl.UTF-8 | |
174 | Git-daemon to prosty demon git korzystający z protokołu TCP do | |
175 | udostępniania repozytoriów git. Ten pakiet dostarcza pliki potrzebne | |
176 | do uruchomienia git-daemona w trybie usługi samodzielnej. | |
177 | ||
178 | %package devel | |
179 | Summary: Git library with header files | |
180 | Summary(pl.UTF-8): Biblioteka Gita oraz pliki nagłówkowe | |
181 | Group: Development/Libraries | |
182 | Requires: zlib-devel | |
183 | ||
184 | %description devel | |
185 | Git library with header files. | |
186 | ||
187 | %description devel -l pl.UTF-8 | |
188 | Biblioteka Gita oraz pliki nagłówkowe. | |
189 | ||
190 | %package gitk | |
191 | Summary: Tcl/Tk interface to the Git version control system | |
192 | Summary(pl.UTF-8): Napisany w Tcl/Tk interfejs do systemu kontroli wersji Git | |
193 | Group: Development/Tools | |
194 | Requires: %{name} = %{version}-%{release} | |
195 | Requires: tk | |
196 | ||
197 | %description gitk | |
198 | gitk displays changes in a repository or a selected set of commits. | |
199 | This includes visualizing the commit graph, showing information | |
200 | related to each commit, and the files in the trees of each revision. | |
201 | ||
202 | Historically, gitk was the first repository browser. It's written in | |
203 | Tcl/Tk and started off in a separate repository but was later merged | |
204 | into the main git repository. | |
205 | ||
206 | %description gitk -l pl.UTF-8 | |
207 | gitk wyświetla zmiany w repozytorium lub wybranym zbiorze commitów. | |
208 | Oznacza to wizualizację grafu commitów, wyświetlanie informacji | |
209 | związanych z każdym z commitów oraz listę plików dla każdej rewizji. | |
210 | ||
211 | Z historycznego punktu widzenia gitk był pierwszą przeglądarką | |
212 | repozytorium git. Napisany jest w Tcl/Tk i początkowo był rozwijany w | |
213 | osobnym repozytorium, ale z czasem został włączony do głównego | |
214 | repozytorium gita. | |
215 | ||
216 | %package gitweb | |
217 | Summary: Web frontend to git | |
218 | Summary(pl.UTF-8): Frontend WWW do gita | |
219 | Group: Development/Tools | |
220 | Requires: %{name} = %{version}-%{release} | |
221 | Requires: webapps | |
222 | Requires: webserver(access) | |
223 | Requires: webserver(alias) | |
224 | Requires: webserver(cgi) | |
225 | Suggests: webserver(setenv) | |
226 | ||
227 | %description gitweb | |
228 | This package provides a web interface for browsing git repositories. | |
229 | ||
230 | %description gitweb -l pl.UTF-8 | |
231 | Pakiet ten dostarcza interfejs WWW do przeglądania repozytoriów gita. | |
232 | ||
233 | %package gitview | |
234 | Summary: A GTK+ based repository browser for git | |
235 | Summary(pl.UTF-8): Oparta na GTK+ przeglądarka repozytorium gita | |
236 | Group: Development/Tools | |
237 | Requires: %{name} = %{version}-%{release} | |
238 | Requires: python >= 1:2.4 | |
239 | Requires: python-pycairo >= 1.0 | |
240 | Requires: python-pygobject | |
241 | Requires: python-pygtk-gtk >= 2:2.8 | |
242 | Suggests: python-gnome-desktop-gtksourceview | |
243 | ||
244 | %description gitview | |
245 | A GTK+ based repository browser for git. | |
246 | ||
247 | %description gitview -l pl.UTF-8 | |
248 | Oparta na GTK+ przeglądarka repozytorium gita. | |
249 | ||
250 | %package gui | |
251 | Summary: Tcl/Tk interface to the Git version control system | |
252 | Summary(pl.UTF-8): Napisany w Tcl/Tk interfejs do systemu kontroli wersji Git | |
253 | Group: Development/Tools | |
254 | Requires: %{name} = %{version}-%{release} | |
255 | Requires: tk | |
256 | Requires: xdg-utils | |
257 | Suggests: meld | |
258 | ||
259 | %description gui | |
260 | Displays changes in a repository or a selected set of commits. This | |
261 | includes visualizing the commit graph, showing information related to | |
262 | each commit, and the files in the trees of each revision. | |
263 | ||
264 | Historically, gitk was the first repository browser. It's written in | |
265 | Tcl/Tk and started off in a separate repository but was later merged | |
266 | into the main git repository. | |
267 | ||
268 | %description gui -l pl.UTF-8 | |
269 | Wyświetla zmiany w repozytorium lub wybranym zbiorze commitów. Oznacza | |
270 | to wizualizację grafu commitów, wyświetlanie informacji związanych z | |
271 | każdym z commitów oraz listę plików dla każdej rewizji. | |
272 | ||
273 | Z punktu widzenia historii, gitk był pierwszą przeglądarką | |
274 | repozytorium git. Napisany jest w Tcl/Tk i początkowo był rozwijany w | |
275 | osobnym repozytorium, ale z czasem został włączony do głównego | |
276 | repozytorium gita. | |
277 | ||
278 | %package arch | |
279 | Summary: Git tools for importing Arch repositories | |
280 | Summary(pl.UTF-8): Narzędzia Gita do importowania repozytoriów Archa | |
281 | Group: Development/Tools | |
282 | Requires: %{name} = %{version}-%{release} | |
283 | Requires: tla | |
284 | ||
285 | %description arch | |
286 | Git tools for importing Arch repositories. | |
287 | ||
288 | %description arch -l pl.UTF-8 | |
289 | Narzędzia Gita do importowania repozytoriów Archa. | |
290 | ||
291 | %package bzr | |
292 | Summary: Git tools for working with bzr repositories | |
293 | Summary(pl.UTF-8): Narzędzia Gita do pracy z repozytoriami bzr | |
294 | Group: Development/Tools | |
295 | Requires: %{name} = %{version}-%{release} | |
296 | Requires: bzr | |
297 | ||
298 | %description bzr | |
299 | Git tools for working with bzr repositories. | |
300 | ||
301 | %description bzr -l pl.UTF-8 | |
302 | Narzędzia Gita do pracy z repozytoriami bzr. | |
303 | ||
304 | %package cvs | |
305 | Summary: CVS support for Git | |
306 | Summary(pl.UTF-8): Obsługa CVS dla Gita | |
307 | Group: Development/Tools | |
308 | Requires: %{name} = %{version}-%{release} | |
309 | Requires: cvsps >= 2.1-2 | |
310 | Requires: rcs | |
311 | ||
312 | %description cvs | |
313 | CVS support for Git. | |
314 | ||
315 | %description cvs -l pl.UTF-8 | |
316 | Obsługa CVS dla Gita. | |
317 | ||
318 | %package hg | |
319 | Summary: Git tools for working with mercurial repositories | |
320 | Summary(pl.UTF-8): Narzędzia Gita do pracy z repozytoriami mercuriala | |
321 | Group: Development/Tools | |
322 | Requires: %{name} = %{version}-%{release} | |
323 | Requires: mercurial >= 1.8 | |
324 | ||
325 | %description hg | |
326 | Git tools for working with mercurial repositories. | |
327 | ||
328 | %description hg -l pl.UTF-8 | |
329 | Narzędzia Gita do pracy z repozytoriami mercuriala. | |
330 | ||
331 | %package p4 | |
332 | Summary: Git tools for working with Perforce depots | |
333 | Summary(pl.UTF-8): Narzędzia Gita do pracy z magazynami Perforce'a | |
334 | Group: Development/Tools | |
335 | Requires: %{name} = %{version}-%{release} | |
336 | ||
337 | %description p4 | |
338 | Git tools for working with Perforce depots. | |
339 | ||
340 | %description p4 -l pl.UTF-8 | |
341 | Narzędzia Gita do pracy z magazynami Perforce'a. | |
342 | ||
343 | %package svn | |
344 | Summary: Subversion support for Git | |
345 | Summary(pl.UTF-8): Obsługa Subversion dla Gita | |
346 | Group: Development/Tools | |
347 | Requires: %{name} = %{version}-%{release} | |
348 | Requires: perl-Encode | |
349 | Requires: perl-Term-ReadKey | |
350 | ||
351 | %description svn | |
352 | Subversion support for Git. | |
353 | ||
354 | %description svn -l pl.UTF-8 | |
355 | Obsługa Subversion dla Gita. | |
356 | ||
357 | %package email | |
358 | Summary: Git tools for sending email | |
359 | Summary(pl.UTF-8): Narzędzia Gita do wysyłania poczty | |
360 | Group: Development/Tools | |
361 | Requires: %{name} = %{version}-%{release} | |
362 | ||
363 | %description email | |
364 | Git tools for sending email. | |
365 | ||
366 | %description email -l pl.UTF-8 | |
367 | Narzędzia Gita do wysyłania poczty. | |
368 | ||
369 | %package -n bash-completion-git | |
370 | Summary: bash-completion for git | |
371 | Summary(pl.UTF-8): bashowe uzupełnianie nazw dla gita | |
372 | Group: Applications/Shells | |
373 | Requires: %{name} = %{version}-%{release} | |
374 | Requires: bash-completion >= 2.0 | |
375 | %if "%{_rpmversion}" >= "5" | |
376 | BuildArch: noarch | |
377 | %endif | |
378 | ||
379 | %description -n bash-completion-git | |
380 | This package provides bash-completion for git. | |
381 | ||
382 | %description -n bash-completion-git -l pl.UTF-8 | |
383 | Pakiet ten dostarcza bashowe uzupełnianie nazw dla gita. | |
384 | ||
385 | %package -n perl-Git | |
386 | Summary: Perl interface to the Git version control system | |
387 | Summary(pl.UTF-8): Perlowy interfejs do systemu kontroli wersji Git | |
388 | Group: Development/Languages/Perl | |
389 | Obsoletes: perl-git-core | |
390 | ||
391 | %description -n perl-Git | |
392 | This module provides Perl scripts easy way to interface the Git | |
393 | version control system. The modules have an easy and well-tested way | |
394 | to call arbitrary Git commands; in the future, the interface will also | |
395 | provide specialized methods for doing easily operations which are not | |
396 | totally trivial to do over the generic command interface. | |
397 | ||
398 | %description -n perl-Git -l pl.UTF-8 | |
399 | Ten moduł umożliwia skryptom Perla współpracę z systemem kontroli | |
400 | wersji Git. W łatwy i dobrze przetestowany sposób pozwala wywoływać | |
401 | dowolne polecenia Gita; w przyszłości interfejs udostępni także | |
402 | specjalne metody do łatwego wykonywania operacji nietrywialnych do | |
403 | wykonania przy użyciu ogólnego interfejsu poleceń. | |
404 | ||
405 | %package -n gnome-keyring-git-core | |
406 | Summary: GNOME Keyring authentication provider for Git | |
407 | Summary(pl.UTF-8): Moduł uwierzytelniający GNOME Keyring dla Git | |
408 | Group: X11/Applications | |
409 | Requires: %{name} = %{version}-%{release} | |
410 | ||
411 | %description -n gnome-keyring-git-core | |
412 | Authentication provider module for Git which allows git client to | |
413 | authenticate using GNOME Keyring. | |
414 | ||
415 | %description -n gnome-keyring-git-core -l pl.UTF-8 | |
416 | Moduł uwierzytelniający dla Subversion pozwalający klientom git | |
417 | uwierzytelniać się przy użyciu mechanizmu GNOME Keyring. | |
418 | ||
419 | %prep | |
420 | %setup -q -n git-%{version} | |
421 | %patch0 -p1 | |
422 | %patch1 -p0 | |
423 | %patch2 -p1 | |
424 | %patch3 -p1 | |
425 | %patch4 -p1 | |
426 | ||
427 | %{__rm} {Documentation/technical,contrib/emacs,contrib/credential/gnome-keyring}/.gitignore | |
428 | ||
429 | %build | |
430 | %{__aclocal} | |
431 | %{__autoconf} | |
432 | %configure \ | |
433 | --sysconfdir=%{_sysconfdir}/git-core \ | |
434 | %{?with_pcre:--with-libpcre} \ | |
435 | --with-openssl | |
436 | ||
437 | echo "BLK_SHA1=1" >> config.mak | |
438 | ||
439 | %{__make} \ | |
440 | INSTALLDIRS=vendor \ | |
441 | GITWEB_CONFIG="%{webappdir}/gitweb.conf" \ | |
442 | GITWEB_PROJECTROOT="/var/lib/git" \ | |
443 | GITWEB_CSS="/gitweb/gitweb.css" \ | |
444 | GITWEB_LOGO="/gitweb/git-logo.png" \ | |
445 | GITWEB_FAVICON="/gitweb/git-favicon.png" \ | |
446 | V=1 | |
447 | ||
448 | %{__make} -C contrib/subtree | |
449 | ||
450 | %if %{with gnome_keyring} | |
451 | %{__make} -C contrib/credential/gnome-keyring | |
452 | %endif | |
453 | ||
454 | %if %{with doc} | |
455 | %{__make} -C Documentation \ | |
456 | MAN_BASE_URL=file://%{_docdir}/%{name}-doc-%{version}/ \ | |
457 | V=1 | |
458 | %endif | |
459 | ||
460 | %if %{with tests} | |
461 | %if %{without tests_cvs} | |
462 | %{__rm} t/t*cvs*.sh || : | |
463 | %endif | |
464 | %{!?with_tests_svn:GIT_SKIP_TESTS='t91??'} %{__make} test | |
465 | %endif | |
466 | ||
467 | %install | |
468 | rm -rf $RPM_BUILD_ROOT | |
469 | install -d $RPM_BUILD_ROOT{%{_includedir}/%{name}/xdiff,%{_localstatedir}/lib/git} | |
470 | install -d $RPM_BUILD_ROOT{%{appdir},%{cgibindir},%{webappdir}} | |
471 | install -d $RPM_BUILD_ROOT/etc/{sysconfig/rc-inetd,rc.d/init.d} | |
472 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/%{name} | |
473 | cat << EOF > $RPM_BUILD_ROOT%{_sysconfdir}/git-core/gitconfig | |
474 | [init] | |
475 | templatedir = %{_sysconfdir}/%{name}/templates | |
476 | EOF | |
477 | ||
478 | %{__make} install \ | |
479 | INSTALLDIRS=vendor \ | |
480 | DESTDIR=$RPM_BUILD_ROOT | |
481 | ||
482 | %if %{with doc} | |
483 | %{__make} -C Documentation install \ | |
484 | DESTDIR=$RPM_BUILD_ROOT | |
485 | %endif | |
486 | ||
487 | # copy templates except sample hooks | |
488 | cp -a $RPM_BUILD_ROOT%{_datadir}/%{name}/templates $RPM_BUILD_ROOT%{_sysconfdir}/%{name} | |
489 | %{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/templates/hooks/*.sample | |
490 | ||
491 | # header files and lib | |
492 | cp -p *.h $RPM_BUILD_ROOT%{_includedir}/%{name} | |
493 | cp -a compat $RPM_BUILD_ROOT%{_includedir}/%{name} | |
494 | cp -p xdiff/*.h $RPM_BUILD_ROOT%{_includedir}/%{name}/xdiff | |
495 | install -d $RPM_BUILD_ROOT%{_includedir}/%{name}/block-sha1 | |
496 | cp -p block-sha1/sha1.h $RPM_BUILD_ROOT%{_includedir}/%{name}/block-sha1 | |
497 | cp -p libgit.a $RPM_BUILD_ROOT%{_libdir} | |
498 | cp -p xdiff/lib.a $RPM_BUILD_ROOT%{_libdir}/libgit_xdiff.a | |
499 | cp -p {Makefile,config.mak,config.mak.autogen,config.mak.uname} $RPM_BUILD_ROOT%{_includedir}/%{name} | |
500 | ||
501 | %{__make} -C contrib/subtree install \ | |
502 | libexecdir=%{_libdir}/%{name} \ | |
503 | DESTDIR=$RPM_BUILD_ROOT | |
504 | ||
505 | %if %{with doc} | |
506 | %{__make} -C contrib/subtree install-doc \ | |
507 | DESTDIR=$RPM_BUILD_ROOT | |
508 | %endif | |
509 | ||
510 | %if %{with gnome_keyring} | |
511 | install -p contrib/credential/gnome-keyring/git-credential-gnome-keyring $RPM_BUILD_ROOT%{_libdir}/%{name} | |
512 | # Remove built binary files, otherwise they will be installed in doc | |
513 | %{__make} -C contrib/credential/gnome-keyring clean | |
514 | %endif | |
515 | ||
516 | # bash completion | |
517 | install -d $RPM_BUILD_ROOT%{bash_compdir} | |
518 | cp -p contrib/completion/git-completion.bash $RPM_BUILD_ROOT%{bash_compdir}/git | |
519 | ||
520 | # Install git-prompt.sh | |
521 | install -d $RPM_BUILD_ROOT%{_datadir}/%{name}/contrib/completion | |
522 | cp -p contrib/completion/git-prompt.sh $RPM_BUILD_ROOT%{_datadir}/%{name}/contrib/completion | |
523 | ||
524 | # Install bzr and hg remote helpers from contrib | |
525 | install -p contrib/remote-helpers/git-remote-{bzr,hg} $RPM_BUILD_ROOT%{_libdir}/%{name} | |
526 | ||
527 | # gitweb | |
528 | mv $RPM_BUILD_ROOT{%{appdir},%{cgibindir}}/gitweb.cgi | |
529 | ln -s %{cgibindir}/gitweb.cgi $RPM_BUILD_ROOT%{appdir}/gitweb.cgi | |
530 | cp -p %{SOURCE1} $RPM_BUILD_ROOT%{webappdir}/gitweb.conf | |
531 | cp -p %{SOURCE7} $RPM_BUILD_ROOT%{webappdir}/gitolite.pl | |
532 | cp -p %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}/apache.conf | |
533 | cp -p %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}/httpd.conf | |
534 | cp -p %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/lighttpd.conf | |
535 | ||
536 | # gitview | |
537 | install -p contrib/gitview/gitview $RPM_BUILD_ROOT%{_bindir} | |
538 | ||
539 | # git-daemon related files | |
540 | cp -p %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/git-daemon | |
541 | cp -p %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/git-daemon | |
542 | install -p %{SOURCE6} $RPM_BUILD_ROOT/etc/rc.d/init.d/git-daemon | |
543 | ||
544 | # paths cleanup | |
545 | sed -e 's,@libdir@,%{_libdir},g' -i $RPM_BUILD_ROOT/etc/rc.d/init.d/git-daemon | |
546 | sed -e 's,@libdir@,%{_libdir},g' -i $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/git-daemon | |
547 | ||
548 | # hardlink | |
549 | ln -f $RPM_BUILD_ROOT%{_bindir}/{git,git-receive-pack} | |
550 | ln -f $RPM_BUILD_ROOT%{_bindir}/{git,git-upload-archive} | |
551 | ln -f $RPM_BUILD_ROOT{%{_libdir}/%{name},%{_bindir}}/git-shell | |
552 | ln -f $RPM_BUILD_ROOT{%{_libdir}/%{name},%{_bindir}}/git-upload-pack | |
553 | ||
554 | # remove unneeded files | |
555 | %{__rm} $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod | |
556 | %{__rm} $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Git/.packlist | |
557 | %py_postclean | |
558 | ||
559 | mv $RPM_BUILD_ROOT%{_localedir}/pt{_PT,} | |
560 | %find_lang git | |
561 | ||
562 | %clean | |
563 | rm -rf $RPM_BUILD_ROOT | |
564 | ||
565 | %post daemon-inetd | |
566 | %service -q rc-inetd reload | |
567 | ||
568 | %postun daemon-inetd | |
569 | if [ "$1" = "0" ]; then | |
570 | %service -q rc-inetd reload | |
571 | fi | |
572 | ||
573 | %post daemon-standalone | |
574 | /sbin/chkconfig --add git-daemon | |
575 | %service git-daemon restart "git-daemon" | |
576 | ||
577 | %preun daemon-standalone | |
578 | if [ "$1" = "0" ]; then | |
579 | %service git-daemon stop | |
580 | /sbin/chkconfig --del git-daemon | |
581 | fi | |
582 | ||
583 | %triggerin gitweb -- apache1 < 1.3.37-3, apache1-base | |
584 | %webapp_register apache %{webapp} | |
585 | ||
586 | %triggerun gitweb -- apache1 < 1.3.37-3, apache1-base | |
587 | %webapp_unregister apache %{webapp} | |
588 | ||
589 | %triggerin gitweb -- apache < 2.2.0, apache-base | |
590 | %webapp_register httpd %{webapp} | |
591 | ||
592 | %triggerun gitweb -- apache < 2.2.0, apache-base | |
593 | %webapp_unregister httpd %{webapp} | |
594 | ||
595 | %triggerin gitweb -- lighttpd | |
596 | %webapp_register lighttpd %{webapp} | |
597 | ||
598 | %triggerun gitweb -- lighttpd | |
599 | %webapp_unregister lighttpd %{webapp} | |
600 | ||
601 | %files -f git.lang | |
602 | %defattr(644,root,root,755) | |
603 | %doc README contrib | |
604 | %attr(755,root,root) %{_bindir}/git | |
605 | %attr(755,root,root) %{_bindir}/git-receive-pack | |
606 | %attr(755,root,root) %{_bindir}/git-shell | |
607 | %attr(755,root,root) %{_bindir}/git-upload-archive | |
608 | %attr(755,root,root) %{_bindir}/git-upload-pack | |
609 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name} | |
610 | ||
611 | %if %{with doc} | |
612 | %{_mandir}/man1/git-*.1* | |
613 | %exclude %{_mandir}/man1/git-archimport.1* | |
614 | %exclude %{_mandir}/man1/git-svn.1* | |
615 | %exclude %{_mandir}/man1/git-cvs*.1* | |
616 | %exclude %{_mandir}/man1/git-imap-send*.1* | |
617 | %exclude %{_mandir}/man1/*email*.1* | |
618 | %{_mandir}/man1/git.1* | |
619 | %{_mandir}/man1/gitremote-helpers.1* | |
620 | %{_mandir}/man5/gitattributes.5* | |
621 | %{_mandir}/man5/githooks.5* | |
622 | %{_mandir}/man5/gitignore.5* | |
623 | %{_mandir}/man5/gitmodules.5* | |
624 | %{_mandir}/man5/gitrepository-layout.5* | |
625 | %{_mandir}/man7/gitcli.7* | |
626 | %{_mandir}/man7/gitcore-tutorial.7* | |
627 | %{_mandir}/man7/gitcredentials.7* | |
628 | %{_mandir}/man7/gitdiffcore.7* | |
629 | %{_mandir}/man7/gitglossary.7* | |
630 | %{_mandir}/man7/gitnamespaces.7* | |
631 | %{_mandir}/man7/gitrevisions.7* | |
632 | %{_mandir}/man7/gittutorial-2.7* | |
633 | %{_mandir}/man7/gittutorial.7* | |
634 | %{_mandir}/man7/gitworkflows.7* | |
635 | %endif | |
636 | ||
637 | %dir %{_libdir}/%{name} | |
638 | %attr(755,root,root) %{_libdir}/%{name}/*-* | |
639 | %attr(755,root,root) %{_libdir}/%{name}/git | |
640 | %dir %{_libdir}/%{name}/mergetools | |
641 | %{_libdir}/%{name}/mergetools/* | |
642 | ||
643 | %{_datadir}/%{name} | |
644 | %{_localstatedir}/lib/git | |
645 | ||
646 | # subpackages | |
647 | %exclude %{_libdir}/%{name}/*email* | |
648 | %exclude %{_libdir}/%{name}/*p4* | |
649 | %exclude %{_libdir}/%{name}/git-archimport | |
650 | %exclude %{_libdir}/%{name}/git-cvs* | |
651 | %exclude %{_libdir}/%{name}/git-gui | |
652 | %exclude %{_libdir}/%{name}/git-imap-send | |
653 | %exclude %{_libdir}/%{name}/git-instaweb | |
654 | %exclude %{_libdir}/%{name}/git-remote-bzr | |
655 | %exclude %{_libdir}/%{name}/git-remote-hg | |
656 | %exclude %{_libdir}/%{name}/git-remote-testsvn | |
657 | %exclude %{_libdir}/%{name}/git-svn | |
658 | %exclude %{_libdir}/%{name}/mergetools/p4merge | |
659 | %if %{with gnome_keyring} | |
660 | %exclude %{_libdir}/%{name}/git-credential-gnome-keyring | |
661 | %endif | |
662 | ||
663 | %if %{with doc} | |
664 | %files doc | |
665 | %defattr(644,root,root,755) | |
666 | %doc Documentation/RelNotes* | |
667 | %doc Documentation/*.html Documentation/howto Documentation/technical | |
668 | %endif | |
669 | ||
670 | %files daemon-inetd | |
671 | %defattr(644,root,root,755) | |
672 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/git-daemon | |
673 | ||
674 | %files daemon-standalone | |
675 | %defattr(644,root,root,755) | |
676 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/git-daemon | |
677 | %attr(754,root, root) /etc/rc.d/init.d/git-daemon | |
678 | ||
679 | %files devel | |
680 | %defattr(644,root,root,755) | |
681 | %{_includedir}/%{name} | |
682 | %{_libdir}/libgit.a | |
683 | %{_libdir}/libgit_xdiff.a | |
684 | ||
685 | %files gitk | |
686 | %defattr(644,root,root,755) | |
687 | %if %{with doc} | |
688 | %{_mandir}/man1/gitk.1* | |
689 | %endif | |
690 | %attr(755,root,root) %{_bindir}/gitk | |
691 | %dir %{_datadir}/gitk | |
692 | %dir %{_datadir}/gitk/lib | |
693 | %dir %{_datadir}/gitk/lib/msgs | |
694 | %lang(bg) %{_datadir}/gitk/lib/msgs/bg.msg | |
695 | %lang(de) %{_datadir}/gitk/lib/msgs/de.msg | |
696 | %lang(es) %{_datadir}/gitk/lib/msgs/es.msg | |
697 | %lang(fr) %{_datadir}/gitk/lib/msgs/fr.msg | |
698 | %lang(hu) %{_datadir}/gitk/lib/msgs/hu.msg | |
699 | %lang(it) %{_datadir}/gitk/lib/msgs/it.msg | |
700 | %lang(ja) %{_datadir}/gitk/lib/msgs/ja.msg | |
701 | %lang(pt_BR) %{_datadir}/gitk/lib/msgs/pt_br.msg | |
702 | %lang(ru) %{_datadir}/gitk/lib/msgs/ru.msg | |
703 | %lang(sv) %{_datadir}/gitk/lib/msgs/sv.msg | |
704 | ||
705 | %files gitweb | |
706 | %defattr(644,root,root,755) | |
707 | %doc gitweb/{README,INSTALL} | |
708 | %dir %{webappdir} | |
709 | %config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/apache.conf | |
710 | %config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/httpd.conf | |
711 | %config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/lighttpd.conf | |
712 | %config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/gitweb.conf | |
713 | %config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/gitolite.pl | |
714 | %attr(755,root,root) %{cgibindir}/gitweb.cgi | |
715 | %{appdir} | |
716 | %attr(755,root,root) %{_libdir}/%{name}/git-instaweb | |
717 | %if %{with doc} | |
718 | %{_mandir}/man1/gitweb.1* | |
719 | %{_mandir}/man5/gitweb.conf.5* | |
720 | %endif | |
721 | ||
722 | %files gitview | |
723 | %defattr(644,root,root,755) | |
724 | %doc contrib/gitview/gitview.txt | |
725 | %attr(755,root,root) %{_bindir}/gitview | |
726 | ||
727 | %files gui | |
728 | %defattr(644,root,root,755) | |
729 | %attr(755,root,root) %{_libdir}/%{name}/git-gui | |
730 | %dir %{_datadir}/git-gui | |
731 | %dir %{_datadir}/git-gui/lib | |
732 | %dir %{_datadir}/git-gui/lib/msgs | |
733 | %{_datadir}/git-gui/lib/git-gui.ico | |
734 | %{_datadir}/git-gui/lib/tclIndex | |
735 | %{_datadir}/git-gui/lib/*.js | |
736 | %{_datadir}/git-gui/lib/*.tcl | |
737 | %lang(bg) %{_datadir}/git-gui/lib/msgs/bg.msg | |
738 | %lang(de) %{_datadir}/git-gui/lib/msgs/de.msg | |
739 | %lang(el) %{_datadir}/git-gui/lib/msgs/el.msg | |
740 | %lang(fr) %{_datadir}/git-gui/lib/msgs/fr.msg | |
741 | %lang(hu) %{_datadir}/git-gui/lib/msgs/hu.msg | |
742 | %lang(it) %{_datadir}/git-gui/lib/msgs/it.msg | |
743 | %lang(ja) %{_datadir}/git-gui/lib/msgs/ja.msg | |
744 | %lang(nb) %{_datadir}/git-gui/lib/msgs/nb.msg | |
745 | %lang(pt_br) %{_datadir}/git-gui/lib/msgs/pt_br.msg | |
746 | %lang(ru) %{_datadir}/git-gui/lib/msgs/ru.msg | |
747 | %lang(sv) %{_datadir}/git-gui/lib/msgs/sv.msg | |
748 | %lang(zh_CN) %{_datadir}/git-gui/lib/msgs/zh_cn.msg | |
749 | ||
750 | %files arch | |
751 | %defattr(644,root,root,755) | |
752 | %attr(755,root,root) %{_libdir}/%{name}/git-archimport | |
753 | %if %{with doc} | |
754 | %{_mandir}/man1/git-archimport.1* | |
755 | %endif | |
756 | ||
757 | %files bzr | |
758 | %defattr(644,root,root,755) | |
759 | %attr(755,root,root) %{_libdir}/%{name}/git-remote-bzr | |
760 | ||
761 | %files cvs | |
762 | %defattr(644,root,root,755) | |
763 | %attr(755,root,root) %{_bindir}/git-cvsserver | |
764 | %attr(755,root,root) %{_libdir}/%{name}/git-cvs* | |
765 | %if %{with doc} | |
766 | %{_mandir}/man1/git-cvs*.1* | |
767 | %{_mandir}/man7/gitcvs-migration.7* | |
768 | %endif | |
769 | ||
770 | %files hg | |
771 | %defattr(644,root,root,755) | |
772 | %attr(755,root,root) %{_libdir}/%{name}/git-remote-hg | |
773 | ||
774 | %files p4 | |
775 | %defattr(644,root,root,755) | |
776 | %attr(755,root,root) %{_libdir}/%{name}/git-p4 | |
777 | %attr(755,root,root) %{_libdir}/%{name}/mergetools/p4merge | |
778 | ||
779 | %files svn | |
780 | %defattr(644,root,root,755) | |
781 | %attr(755,root,root) %{_libdir}/%{name}/git-svn | |
782 | %attr(755,root,root) %{_libdir}/%{name}/git-remote-testsvn | |
783 | %{perl_vendorlib}/Git/SVN | |
784 | %{perl_vendorlib}/Git/SVN.pm | |
785 | %if %{with doc} | |
786 | %{_mandir}/man1/git-svn.1* | |
787 | %endif | |
788 | ||
789 | %files email | |
790 | %defattr(644,root,root,755) | |
791 | %attr(755,root,root) %{_libdir}/%{name}/git-imap-send | |
792 | %attr(755,root,root) %{_libdir}/%{name}/*email* | |
793 | %if %{with doc} | |
794 | %{_mandir}/man1/*email*.1* | |
795 | %{_mandir}/man1/*imap-send*.1* | |
796 | %endif | |
797 | ||
798 | %files -n bash-completion-git | |
799 | %defattr(644,root,root,755) | |
800 | %{bash_compdir}/git | |
801 | ||
802 | %files -n perl-Git | |
803 | %defattr(644,root,root,755) | |
804 | %{perl_vendorlib}/Git.pm | |
805 | %dir %{perl_vendorlib}/Git | |
806 | %{perl_vendorlib}/Git/I18N.pm | |
807 | %{perl_vendorlib}/Git/IndexInfo.pm | |
808 | %{_mandir}/man3/Git*.3pm* | |
809 | ||
810 | %if %{with gnome_keyring} | |
811 | %files -n gnome-keyring-git-core | |
812 | %defattr(644,root,root,755) | |
813 | %attr(755,root,root) %{_libdir}/%{name}/git-credential-gnome-keyring | |
814 | %endif |