]> git.pld-linux.org Git - packages/git-core.git/blame - git-core.spec
up to 2.44.0
[packages/git-core.git] / git-core.spec
CommitLineData
84013e7c 1#
891d0b05 2# Conditional build:
20b80b37
JB
3%bcond_without tests # test suite
4%bcond_with tests_cvs # tests which use CVS
5%bcond_without tests_svn # tests which use subversion
6%bcond_without doc # building/packaging docs/manuals (takes some time)
0643d0ea 7%bcond_without pcre # perl-compatible regexes support
20b80b37
JB
8%bcond_without libsecret # libsecret credentials support
9%bcond_without tk # Tcl/Tk interface
cdeb0400 10
f1c525f8 11# for AC: --without doc --without tests
7ad420b5 12
479de23d
AM
13Summary: Distributed version control system focused on speed, effectivity and usability
14Summary(pl.UTF-8): Rozproszony system śledzenia treści skupiony na szybkości, wydajności i użyteczności
51c3b977 15Name: git-core
15a923a7 16Version: 2.44.0
67fbe349 17Release: 1
51c3b977 18License: GPL v2
19Group: Development/Tools
eee65439 20Source0: https://www.kernel.org/pub/software/scm/git/git-%{version}.tar.xz
15a923a7 21# Source0-md5: 7e4eb7c45e9ba7c90fa51deeea49732f
be2ccf99 22Source1: %{name}-gitweb.conf
814a047c 23Source2: %{name}-gitweb-httpd.conf
51ce768a
KK
24Source3: %{name}-gitweb-lighttpd.conf
25Source4: %{name}.sysconfig
26Source5: %{name}.inet
27Source6: %{name}.init
642ee6ff 28Source7: gitolite.pl
0aa13f22
JP
29Patch0: %{name}-key-bindings.patch
30Patch1: %{name}-sysconfdir.patch
31Patch2: cherry-picked-commitlog.patch
e699dd89 32URL: http://git-scm.com/
fdf2ed38 33BuildRequires: autoconf >= 2.59
11856720 34BuildRequires: automake
51c3b977 35BuildRequires: curl-devel
115484e9 36BuildRequires: expat-devel
2ece97c6
ER
37%if "%{pld_release}" == "ac"
38BuildRequires: gettext-devel
39%else
25a92afd 40BuildRequires: gettext-tools
2ece97c6 41%endif
f1c525f8 42%if %{with libsecret}
20b80b37
JB
43BuildRequires: glib2-devel >= 2.0
44%endif
20b80b37
JB
45%if %{with libsecret}
46BuildRequires: libsecret-devel
cecb5b67 47%endif
51c3b977 48BuildRequires: openssl-devel
d5e39597 49%{?with_pcre:BuildRequires: pcre2-8-devel}
0f1e5795 50BuildRequires: perl-Error > 0.15
561578e1 51BuildRequires: perl-MailTools
51c3b977 52BuildRequires: perl-base
f1c525f8 53%if %{with libsecret}
20b80b37
JB
54BuildRequires: pkgconfig
55%endif
b4f8bcbb 56BuildRequires: python3-devel
0a79dbf8 57BuildRequires: rpm-build >= 4.6
89a476f8 58BuildRequires: rpm-perlprov >= 4.1-13
c841a4fc 59BuildRequires: rpm-pythonprov
760a71de 60BuildRequires: rpmbuild(macros) >= 1.752
8754353c 61BuildRequires: tar >= 1:1.22
7d9cd7eb 62%if %{with tk}
1db22c36
JB
63# wish
64BuildRequires: tk
8754353c 65BuildRequires: xz
7d9cd7eb 66%endif
51c3b977 67BuildRequires: zlib-devel
08cc92d7
ER
68%if %{with doc}
69BuildRequires: asciidoc >= 7.1.2-3
c841a4fc 70BuildRequires: docbook-dtd45-xml
08cc92d7
ER
71BuildRequires: xmlto
72%endif
2c50f007 73%if %{with tests}
e3a3567e 74BuildRequires: openssh-clients
e460872a
JB
75BuildRequires: perl-CGI
76BuildRequires: perl-Digest-MD5
77BuildRequires: perl-Encode
78BuildRequires: perl-Time-HiRes
db032591 79%if %{with tests_cvs}
dfed7e92 80# tests failed sometimes when using nserver/cvsnt client so enforce pure cvs here
3554b1a3 81BuildRequires: cvs-gnu-client < 1.13
2c0376c9 82BuildRequires: cvs-gnu-client >= 1.12
db032591 83%endif
ef4eeb6d
KK
84%if %{with tests_svn}
85BuildRequires: perl-subversion
86BuildRequires: subversion
87%endif
1b3085ff 88Conflicts: pdksh < 5.2.14-46
2c50f007 89%endif
23c8c456 90# git-sh-setup: sane_grep
3f245fc5 91Requires: grep
23c8c456
ER
92# git-pull: printf
93Requires: coreutils
3f245fc5 94Requires: sed
26361b03 95Suggests: git-core-cvs
0d2db069 96Suggests: git-core-p4
26361b03 97Suggests: git-core-svn
d82521ea 98Suggests: less
9e9faf95 99Suggests: openssh-clients
e7120917 100Suggests: perl-Git = %{version}-%{release}
d82521ea 101Suggests: rsync
6769cb97
JB
102Obsoletes: git-core-gitview < 2.12.1
103Obsoletes: python-Git < 1.8.5
f4018182 104Conflicts: perl-Git < %{version}
51c3b977 105BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
106
19936745
AM
107# html docs have links to txt files
108%define _noautocompressdoc *.txt
109
e7120917 110# do not generate perl dependency, git add -p support is optional
27399cc4
ER
111# skip dependency generation from templates
112%define _noautoreqfiles %{_libexecdir}/%{name}/git-add--interactive %{_datadir}/%{name}/templates
e7120917 113
be2ccf99
AG
114%define webapp gitweb
115%define webappdir %{_sysconfdir}/webapps/%{webapp}
116%define appdir %{_datadir}/%{webapp}
117%define cgibindir %{_prefix}/lib/cgi-bin
ee14b8db 118%define gitcoredir %{_libexecdir}/%{name}
be2ccf99 119
51c3b977 120%description
121"git" can mean anything, depending on your mood.
122
d52424f5 123- random three-letter combination that is pronounceable, and not
124 actually used by any common UNIX command. The fact that it is a
125 mispronunciation of "get" may or may not be relevant.
126- stupid. contemptible and despicable. simple. Take your pick from the
127 dictionary of slang.
128- "global information tracker": you're in a good mood, and it actually
129 works for you. Angels sing, and a light suddenly fills the room.
130- "goddamn idiotic truckload of sh*t": when it breaks
51c3b977 131
c751087d 132This is a stupid (but extremely fast) directory content manager. It
51c3b977 133doesn't do a whole lot, but what it 'does' do is track directory
134contents efficiently.
135
ea061c99
JR
136%description -l pl.UTF-8
137"git" może oznaczać cokolwiek, w zależności od nastroju.
138
d52424f5 139- losową kombinację trzech liter, która jest wymawialna i właściwie
140 nie używana przez żadne popularne polecenie uniksowe. Fakt, że jest to
141 błędna pisownia słowa "get" może mieć lub nie mieć znaczenia.
142- głupi, pogardliwy, prosty. Można wybrać ze słownika slangu.
143- "global information tracker" (narzędzie do globalnego śledzenia
144 informacji) - jeśli jesteśmy w dobrym nastroju i git akurat działa.
145 Anioły śpiewają, a światło niespodziewanie wypełnia pokój.
146- "goddamn idiotic truckload of sh*t" (przeklęty idiotyczny ładunek
147 g*) - kiedy się zepsuje.
ea061c99
JR
148
149Jest to prymitywny (ale bardzo szybki) zarządca treści słownikowej.
150Nie robi wiele, ale to, co "robi", to wydajne śledzenie zawartości
c751087d
JB
151katalogu.
152
a8655d02
ER
153%package doc
154Summary: Documentation for git-core
155Summary(pl.UTF-8): Dokumentacja do git-core
156Group: Documentation
f0d8046b 157BuildArch: noarch
a8655d02
ER
158
159%description doc
160Documentation for git-core.
161
162%description doc -l pl.UTF-8
163Dokumentacja do git-core.
164
b11ada2c
AG
165%package daemon-inetd
166Summary: Files necessary to run git-daemon as an inetd service
5db07614 167Summary(pl.UTF-8): Pliki niezbędne do uruchomienia git-daemona w trybie usługi inetd
b11ada2c
AG
168Group: Networking/Daemons
169Requires: %{name} = %{version}-%{release}
170Requires: setup >= 2.4.11-1
48eb8e3a
JB
171Provides: git-core-daemon = %{version}-%{release}
172Obsoletes: git-core-daemon <= %{version}-%{release}
173Obsoletes: git-core-daemon-standalone <= %{version}-%{release}
b11ada2c
AG
174
175%description daemon-inetd
176Git-daemon is a really simple TCP git daemon that can serve git
177repositories. This package provides all necessarry files to run
178git-daemon as an inetd service.
179
180%description daemon-inetd -l pl.UTF-8
5db07614
JB
181Git-daemon to prosty demon git korzystający z protokołu TCP do
182udostępniania repozytoriów git. Ten pakiet dostarcza pliki potrzebne
183do uruchomienia git-demona w trybie usługi inetd.
b11ada2c
AG
184
185%package daemon-standalone
186Summary: Files necessary to run git-daemon as a standalone service
5db07614 187Summary(pl.UTF-8): Pliki niezbędne do uruchomienia git-daemona w trybie usługi samodzielnej
b11ada2c
AG
188Group: Networking/Daemons
189Requires: %{name} = %{version}-%{release}
48eb8e3a
JB
190Provides: git-core-daemon = %{version}-%{release}
191Obsoletes: git-core-daemon <= %{version}-%{release}
192Obsoletes: git-core-daemon-inetd <= %{version}-%{release}
b11ada2c
AG
193
194%description daemon-standalone
195Git-daemon is a really simple TCP git daemon that can serve git
196repositories. This package provides all necessarry files to run
197git-daemon as an standalone service.
198
199%description daemon-standalone -l pl.UTF-8
5db07614
JB
200Git-daemon to prosty demon git korzystający z protokołu TCP do
201udostępniania repozytoriów git. Ten pakiet dostarcza pliki potrzebne
202do uruchomienia git-daemona w trybie usługi samodzielnej.
b11ada2c 203
e3cefa79 204%package devel
8bed7625
JB
205Summary: Git library with header files
206Summary(pl.UTF-8): Biblioteka Gita oraz pliki nagłówkowe
66a7f095 207Group: Development/Libraries
d52424f5 208Requires: zlib-devel
e3cefa79 209
210%description devel
8bed7625 211Git library with header files.
66a7f095 212
ea061c99 213%description devel -l pl.UTF-8
8bed7625 214Biblioteka Gita oraz pliki nagłówkowe.
e3cefa79 215
91396e2e
AG
216%package gitk
217Summary: Tcl/Tk interface to the Git version control system
218Summary(pl.UTF-8): Napisany w Tcl/Tk interfejs do systemu kontroli wersji Git
219Group: Development/Tools
220Requires: %{name} = %{version}-%{release}
221Requires: tk
f0d8046b 222BuildArch: noarch
91396e2e
AG
223
224%description gitk
1fcd08a6
JB
225gitk displays changes in a repository or a selected set of commits.
226This includes visualizing the commit graph, showing information
227related to each commit, and the files in the trees of each revision.
91396e2e
AG
228
229Historically, gitk was the first repository browser. It's written in
04fdf912 230Tcl/Tk and started off in a separate repository but was later merged
91396e2e
AG
231into the main git repository.
232
233%description gitk -l pl.UTF-8
1fcd08a6
JB
234gitk wyświetla zmiany w repozytorium lub wybranym zbiorze commitów.
235Oznacza to wizualizację grafu commitów, wyświetlanie informacji
236związanych z każdym z commitów oraz listę plików dla każdej rewizji.
91396e2e 237
1fcd08a6 238Z historycznego punktu widzenia gitk był pierwszą przeglądarką
02059138
ER
239repozytorium git. Napisany jest w Tcl/Tk i początkowo był rozwijany w
240osobnym repozytorium, ale z czasem został włączony do głównego
2712fe7b 241repozytorium gita.
91396e2e 242
be2ccf99
AG
243%package gitweb
244Summary: Web frontend to git
41b5f4b1 245Summary(pl.UTF-8): Frontend WWW do gita
be2ccf99
AG
246Group: Development/Tools
247Requires: %{name} = %{version}-%{release}
248Requires: webapps
666cda7c 249Requires: webserver(access)
51ce768a
KK
250Requires: webserver(alias)
251Requires: webserver(cgi)
93a30d5e 252Suggests: webserver(setenv)
be2ccf99
AG
253
254%description gitweb
255This package provides a web interface for browsing git repositories.
256
257%description gitweb -l pl.UTF-8
2712fe7b 258Pakiet ten dostarcza interfejs WWW do przeglądania repozytoriów gita.
be2ccf99 259
f9871074
AG
260%package gui
261Summary: Tcl/Tk interface to the Git version control system
262Summary(pl.UTF-8): Napisany w Tcl/Tk interfejs do systemu kontroli wersji Git
263Group: Development/Tools
264Requires: %{name} = %{version}-%{release}
265Requires: tk
d4106757 266Requires: xdg-utils
531b434f 267Suggests: meld
f9871074
AG
268
269%description gui
270Displays changes in a repository or a selected set of commits. This
271includes visualizing the commit graph, showing information related to
272each commit, and the files in the trees of each revision.
273
274Historically, gitk was the first repository browser. It's written in
275Tcl/Tk and started off in a separate repository but was later merged
276into the main git repository.
277
278%description gui -l pl.UTF-8
279Wyświetla zmiany w repozytorium lub wybranym zbiorze commitów. Oznacza
280to wizualizację grafu commitów, wyświetlanie informacji związanych z
281każdym z commitów oraz listę plików dla każdej rewizji.
282
283Z punktu widzenia historii, gitk był pierwszą przeglądarką
284repozytorium git. Napisany jest w Tcl/Tk i początkowo był rozwijany w
285osobnym repozytorium, ale z czasem został włączony do głównego
286repozytorium gita.
287
e5fa8af5
JB
288%package arch
289Summary: Git tools for importing Arch repositories
290Summary(pl.UTF-8): Narzędzia Gita do importowania repozytoriów Archa
291Group: Development/Tools
292Requires: %{name} = %{version}-%{release}
293Requires: tla
294
295%description arch
296Git tools for importing Arch repositories.
297
298%description arch -l pl.UTF-8
299Narzędzia Gita do importowania repozytoriów Archa.
300
e5fa8af5
JB
301%package cvs
302Summary: CVS support for Git
303Summary(pl.UTF-8): Obsługa CVS dla Gita
304Group: Development/Tools
305Requires: %{name} = %{version}-%{release}
306Requires: cvsps >= 2.1-2
307Requires: rcs
308
309%description cvs
310CVS support for Git.
311
312%description cvs -l pl.UTF-8
313Obsługa CVS dla Gita.
314
0d2db069
ER
315%package p4
316Summary: Git tools for working with Perforce depots
e5fa8af5 317Summary(pl.UTF-8): Narzędzia Gita do pracy z magazynami Perforce'a
0d2db069
ER
318Group: Development/Tools
319Requires: %{name} = %{version}-%{release}
320
321%description p4
322Git tools for working with Perforce depots.
323
e5fa8af5
JB
324%description p4 -l pl.UTF-8
325Narzędzia Gita do pracy z magazynami Perforce'a.
326
2c0376c9
AM
327%package svn
328Summary: Subversion support for Git
41b5f4b1 329Summary(pl.UTF-8): Obsługa Subversion dla Gita
2c0376c9
AM
330Group: Development/Tools
331Requires: %{name} = %{version}-%{release}
daccfb39 332Requires: perl-Encode
4ea37765 333Requires: perl-Term-ReadKey
f05d9c9e 334Requires: perl-modules
2c0376c9
AM
335
336%description svn
337Subversion support for Git.
338
339%description svn -l pl.UTF-8
41b5f4b1 340Obsługa Subversion dla Gita.
2c0376c9 341
d82521ea
ER
342%package email
343Summary: Git tools for sending email
41b5f4b1 344Summary(pl.UTF-8): Narzędzia Gita do wysyłania poczty
d82521ea
ER
345Group: Development/Tools
346Requires: %{name} = %{version}-%{release}
561578e1
JP
347Requires: perl-Error
348Requires: perl-MailTools
77b23c69 349Suggests: perl-Net-SMTP-SSL
d82521ea
ER
350
351%description email
352Git tools for sending email.
353
41b5f4b1
JB
354%description email -l pl.UTF-8
355Narzędzia Gita do wysyłania poczty.
356
e1871bee
JP
357%package scalar
358Summary: A tool for managing large Git repositories
359Summary(pl.UTF-8): Narzędzie do zarządzania dużymi repozytoriami Git
360Group: Development/Tools
361Requires: %{name} = %{version}-%{release}
362
363%description scalar
364Scalar is a repository management tool that optimizes Git for use in
365large repositories. Scalar improves performance by configuring
366advanced Git settings, maintaining repositories in the background, and
367helping to reduce data sent across the network.
368
369%description scalar -l pl.UTF-8
370Scalar jest narzędziem do zarządzania repozytorium Git
371zoptymalizowanym pod kątem dużych repozytoriów. Scalar poprawia
372wydajność poprzez konfigurację zaawansowanych ustawień Git,
373utrzymywanie repozytoriów w tle oraz pomagając zredukować ilość
374danych wysyłanych po sieci.
375
f2c1983d
AG
376%package -n bash-completion-git
377Summary: bash-completion for git
2712fe7b 378Summary(pl.UTF-8): bashowe uzupełnianie nazw dla gita
02059138 379Group: Applications/Shells
cdeb0400 380Requires: %{name} = %{version}-%{release}
2c4dbd79 381Requires: bash-completion >= 1:2.0
f0d8046b 382BuildArch: noarch
f2c1983d
AG
383
384%description -n bash-completion-git
385This package provides bash-completion for git.
386
387%description -n bash-completion-git -l pl.UTF-8
5383e3af 388Pakiet ten dostarcza bashowe uzupełnianie nazw dla gita.
f2c1983d 389
3dc01deb 390%package -n perl-Git
5d7220ad 391Summary: Perl interface to the Git version control system
3f8032f4 392Summary(pl.UTF-8): Perlowy interfejs do systemu kontroli wersji Git
5d7220ad 393Group: Development/Languages/Perl
6f4be518 394Requires: perl-Error
6769cb97 395Obsoletes: perl-git-core < 1.4.3.5
f0d8046b 396BuildArch: noarch
5d7220ad 397
3dc01deb 398%description -n perl-Git
5d7220ad
AM
399This module provides Perl scripts easy way to interface the Git
400version control system. The modules have an easy and well-tested way
401to call arbitrary Git commands; in the future, the interface will also
402provide specialized methods for doing easily operations which are not
403totally trivial to do over the generic command interface.
404
ea061c99
JR
405%description -n perl-Git -l pl.UTF-8
406Ten moduł umożliwia skryptom Perla współpracę z systemem kontroli
08cc92d7
ER
407wersji Git. W łatwy i dobrze przetestowany sposób pozwala wywoływać
408dowolne polecenia Gita; w przyszłości interfejs udostępni także
409specjalne metody do łatwego wykonywania operacji nietrywialnych do
410wykonania przy użyciu ogólnego interfejsu poleceń.
7eef96e1 411
20b80b37
JB
412%package credential-libsecret
413Summary: GNOME authentication provider for Git using libsecret
414Summary(pl.UTF-8): Moduł uwierzytelniający GNOME dla Gita wykorzystujący libsecret
415Group: X11/Applications
416URL: http://git-scm.com/docs/gitcredentials.html
417Requires: %{name} = %{version}-%{release}
f1c525f8 418Obsoletes: gnome-keyring-git-core < 2.41.0
20b80b37
JB
419
420%description credential-libsecret
421Authentication provider module for Git which allows git client to
422authenticate using GNOME libsecret.
423
424You need to register it with:
425- git config --global credential.helper libsecret
426
427%description credential-libsecret -l pl.UTF-8
428Moduł uwierzytelniający dla Gita pozwalający klientom git
429uwierzytelniać się przy użyciu mechanizmu GNOME libsecret.
430
431Moduł trzeba zarejestrować poleceniem:
432- git config --global credential.helper libsecret
433
d500b766
JP
434%package -n zsh-completion-git
435Summary: Zsh completion for git command
436Summary(pl.UTF-8): Dopełnianie parametrów komendy git dla powłoki zsh
437Group: Applications/Shells
438Requires: %{name} = %{version}-%{release}
439Requires: bash-completion-git = %{version}-%{release}
440Requires: zsh
441BuildArch: noarch
442
443%description -n zsh-completion-git
444Zsh completion for git command.
445
446%description -n zsh-completion-git -l pl.UTF-8
447Dopełnianie parametrów komendy git dla powłoki zsh.
448
51c3b977 449%prep
5013f7fc 450%setup -q -n git-%{version}
0aa13f22
JP
451%patch0 -p0
452%patch1 -p1
d12d8532 453%patch2 -p1
a1036d06 454
ab67970b
AM
455# we build things in contrib but want to have it clean for doc purporses, too
456cp -a contrib contrib-doc
457
a1036d06 458%build
11856720
AM
459%{__aclocal}
460%{__autoconf}
461%configure \
d12d8532 462 --sysconfdir=%{_sysconfdir}/git-core \
d5e39597 463 %{?with_pcre:--with-libpcre2} \
b4f8bcbb
JP
464 --with-openssl \
465 --with-python="%{__python3}"
51c3b977 466
7cfee1ba
KK
467echo "BLK_SHA1=1" >> config.mak
468
b69112f7 469%{__make} \
be2ccf99
AG
470 GITWEB_CONFIG="%{webappdir}/gitweb.conf" \
471 GITWEB_PROJECTROOT="/var/lib/git" \
472 GITWEB_CSS="/gitweb/gitweb.css" \
473 GITWEB_LOGO="/gitweb/git-logo.png" \
f74aede9 474 GITWEB_FAVICON="/gitweb/git-favicon.png" \
6fa8665e
JP
475 NO_PERL_CPAN_FALLBACKS=1 \
476 perllibdir=%{perl_vendorlib} \
f74aede9 477 V=1
27b79a12 478
d1d05a7a
ER
479%{__make} -C contrib/subtree
480
20b80b37
JB
481%if %{with libsecret}
482%{__make} -C contrib/credential/libsecret \
483 CC="%{__cc}" \
484 CFLAGS="%{rpmcflags} -Wall" \
485 LDFLAGS="%{rpmldflags}"
0643d0ea
ER
486%endif
487
83b9a8cd 488%if %{with doc}
6fa8665e 489%{__make} doc \
83b9a8cd
ER
490 MAN_BASE_URL=file://%{_docdir}/%{name}-doc-%{version}/ \
491 V=1
492%endif
7fdeb28c 493
db032591
AM
494%if %{with tests}
495%if %{without tests_cvs}
8bed7625 496%{__rm} t/t*cvs*.sh || :
db032591 497%endif
13b76b20
JP
498%if %{without tests_svn}
499GIT_SKIP_TESTS="$GIT_SKIP_TESTS t91??"
500%endif
501export GIT_SKIP_TESTS
017b037c
JB
502%{__make} test \
503 NO_PERL_CPAN_FALLBACKS=1
db032591 504%endif
6c0d6e05 505
51c3b977 506%install
507rm -rf $RPM_BUILD_ROOT
6fa8665e 508install -d $RPM_BUILD_ROOT{%{_includedir}/%{name}/xdiff,%{_libdir},%{_localstatedir}/lib/git}
be2ccf99 509install -d $RPM_BUILD_ROOT{%{appdir},%{cgibindir},%{webappdir}}
5db07614 510install -d $RPM_BUILD_ROOT/etc/{sysconfig/rc-inetd,rc.d/init.d}
cdeb0400 511install -d $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
d12d8532
KK
512cat << EOF > $RPM_BUILD_ROOT%{_sysconfdir}/git-core/gitconfig
513[init]
cdeb0400 514 templatedir = %{_sysconfdir}/%{name}/templates
d12d8532 515EOF
c751087d 516
51c3b977 517%{__make} install \
6fa8665e
JP
518 DESTDIR=$RPM_BUILD_ROOT \
519 NO_PERL_CPAN_FALLBACKS=1 \
520 perllibdir=%{perl_vendorlib}
51c3b977 521
08cc92d7 522%if %{with doc}
6fa8665e 523%{__make} install-doc \
7fdeb28c 524 DESTDIR=$RPM_BUILD_ROOT
08cc92d7 525%endif
7fdeb28c 526
d12d8532
KK
527# copy templates except sample hooks
528cp -a $RPM_BUILD_ROOT%{_datadir}/%{name}/templates $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
529%{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/templates/hooks/*.sample
530
1f25da6d 531# header files and lib
cdeb0400 532cp -p *.h $RPM_BUILD_ROOT%{_includedir}/%{name}
31b26a50 533cp -a compat $RPM_BUILD_ROOT%{_includedir}/%{name}
cdeb0400 534cp -p xdiff/*.h $RPM_BUILD_ROOT%{_includedir}/%{name}/xdiff
95341e74
KK
535install -d $RPM_BUILD_ROOT%{_includedir}/%{name}/block-sha1
536cp -p block-sha1/sha1.h $RPM_BUILD_ROOT%{_includedir}/%{name}/block-sha1
cdeb0400
ER
537cp -p libgit.a $RPM_BUILD_ROOT%{_libdir}
538cp -p xdiff/lib.a $RPM_BUILD_ROOT%{_libdir}/libgit_xdiff.a
95341e74 539cp -p {Makefile,config.mak,config.mak.autogen,config.mak.uname} $RPM_BUILD_ROOT%{_includedir}/%{name}
e3cefa79 540
d1d05a7a 541%{__make} -C contrib/subtree install \
348dee00 542 libexecdir=%{gitcoredir} \
d1d05a7a
ER
543 DESTDIR=$RPM_BUILD_ROOT
544
545%if %{with doc}
e6bf5c7d 546%{__make} -C contrib/subtree install-man \
d1d05a7a
ER
547 DESTDIR=$RPM_BUILD_ROOT
548%endif
549
20b80b37
JB
550%if %{with libsecret}
551install -p contrib/credential/libsecret/git-credential-libsecret $RPM_BUILD_ROOT%{gitcoredir}
552%endif
553
f2c1983d 554# bash completion
3102984c
ER
555install -d $RPM_BUILD_ROOT%{bash_compdir}
556cp -p contrib/completion/git-completion.bash $RPM_BUILD_ROOT%{bash_compdir}/git
d500b766
JP
557install -d $RPM_BUILD_ROOT%{zsh_compdir}
558cp -p contrib/completion/git-completion.zsh $RPM_BUILD_ROOT%{zsh_compdir}/_git
559sed -i -e "1 a zstyle ':completion:*:*:git:*' script %{bash_compdir}/git" $RPM_BUILD_ROOT%{zsh_compdir}/_git
f2c1983d 560
b0d443ea
ER
561# Install git-prompt.sh
562install -d $RPM_BUILD_ROOT%{_datadir}/%{name}/contrib/completion
563cp -p contrib/completion/git-prompt.sh $RPM_BUILD_ROOT%{_datadir}/%{name}/contrib/completion
564
be2ccf99 565# gitweb
20b80b37 566%{__mv} $RPM_BUILD_ROOT{%{appdir},%{cgibindir}}/gitweb.cgi
93a30d5e 567ln -s %{cgibindir}/gitweb.cgi $RPM_BUILD_ROOT%{appdir}/gitweb.cgi
cdeb0400 568cp -p %{SOURCE1} $RPM_BUILD_ROOT%{webappdir}/gitweb.conf
642ee6ff 569cp -p %{SOURCE7} $RPM_BUILD_ROOT%{webappdir}/gitolite.pl
cdeb0400 570cp -p %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}/apache.conf
814a047c 571cp -p %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}/httpd.conf
cdeb0400 572cp -p %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/lighttpd.conf
be2ccf99 573
b11ada2c 574# git-daemon related files
e43aceaa
ER
575cp -p %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/git-daemon
576cp -p %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/git-daemon
51ce768a 577install -p %{SOURCE6} $RPM_BUILD_ROOT/etc/rc.d/init.d/git-daemon
b11ada2c 578
bf7a9a54 579# paths cleanup
6743dd7e
ER
580sed -e 's,@libdir@/git-core,%{gitcoredir},g' -i $RPM_BUILD_ROOT/etc/rc.d/init.d/git-daemon
581sed -e 's,@libdir@/git-core,%{gitcoredir},g' -i $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/git-daemon
bf7a9a54 582
698b79f9
ER
583# same file, link
584ln -sf git $RPM_BUILD_ROOT%{_bindir}/git-receive-pack
585ln -sf git $RPM_BUILD_ROOT%{_bindir}/git-upload-archive
6aec1d92
ER
586ln -sf ../..%{gitcoredir}/git-shell $RPM_BUILD_ROOT%{_bindir}/git-shell
587ln -sf ../..%{gitcoredir}/git-upload-pack $RPM_BUILD_ROOT%{_bindir}/git-upload-pack
588ln -sf ../..%{gitcoredir}/git $RPM_BUILD_ROOT%{_bindir}/git
698b79f9
ER
589
590# convert all hardlinks to symlinks, as rpm fails to calculate it properly
591# requiring excessive free space when it may not be available
592# https://bugs.launchpad.net/pld-linux/+bug/1176337
593find $RPM_BUILD_ROOT%{gitcoredir} -samefile $RPM_BUILD_ROOT%{gitcoredir}/git > files
594for f in $(cat files); do
595 f=${f#$RPM_BUILD_ROOT%{gitcoredir}/}
596 test $f = git && continue
597 ln -snf git $RPM_BUILD_ROOT%{gitcoredir}/$f
598done
599
600# few others
601ln -snf git-gui $RPM_BUILD_ROOT%{gitcoredir}/git-citool
602ln -snf git-remote-http $RPM_BUILD_ROOT%{gitcoredir}/git-remote-https
603ln -snf git-remote-http $RPM_BUILD_ROOT%{gitcoredir}/git-remote-ftp
604ln -snf git-remote-http $RPM_BUILD_ROOT%{gitcoredir}/git-remote-ftps
4e9fd7a9 605
20b80b37 606%{__mv} $RPM_BUILD_ROOT%{_localedir}/pt{_PT,}
fdf2ed38
JB
607%find_lang git
608
51c3b977 609%clean
610rm -rf $RPM_BUILD_ROOT
611
21f26c1e
JP
612%post
613if [ ! -f /etc/shells ]; then
614 echo "%{_bindir}/git-shell" >> /etc/shells
615else
616 grep -q '^%{_bindir}/git-shell$' /etc/shells || echo "%{_bindir}/git-shell" >> /etc/shells
617fi
618
619%preun
620if [ "$1" = "0" ]; then
621 umask 022
622 grep -v '^%{_bindir}/git-shell$' /etc/shells > /etc/shells.new
623 mv -f /etc/shells.new /etc/shells
624fi
625
b11ada2c
AG
626%post daemon-inetd
627%service -q rc-inetd reload
628
629%postun daemon-inetd
630if [ "$1" = "0" ]; then
631 %service -q rc-inetd reload
632fi
633
634%post daemon-standalone
635/sbin/chkconfig --add git-daemon
636%service git-daemon restart "git-daemon"
637
638%preun daemon-standalone
639if [ "$1" = "0" ]; then
640 %service git-daemon stop
641 /sbin/chkconfig --del git-daemon
642fi
643
be2ccf99
AG
644%triggerin gitweb -- apache1 < 1.3.37-3, apache1-base
645%webapp_register apache %{webapp}
646
647%triggerun gitweb -- apache1 < 1.3.37-3, apache1-base
648%webapp_unregister apache %{webapp}
649
814a047c 650%triggerin gitweb -- apache < 2.2.0, apache-base
be2ccf99
AG
651%webapp_register httpd %{webapp}
652
814a047c 653%triggerun gitweb -- apache < 2.2.0, apache-base
be2ccf99
AG
654%webapp_unregister httpd %{webapp}
655
51ce768a
KK
656%triggerin gitweb -- lighttpd
657%webapp_register lighttpd %{webapp}
658
659%triggerun gitweb -- lighttpd
660%webapp_unregister lighttpd %{webapp}
661
fdf2ed38 662%files -f git.lang
51c3b977 663%defattr(644,root,root,755)
a824ba4f 664%doc README.md contrib-doc
a8655d02 665%attr(755,root,root) %{_bindir}/git
44ee5525
ER
666%attr(755,root,root) %{_bindir}/git-receive-pack
667%attr(755,root,root) %{_bindir}/git-shell
668%attr(755,root,root) %{_bindir}/git-upload-archive
669%attr(755,root,root) %{_bindir}/git-upload-pack
cdeb0400 670%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}
a8655d02 671
08cc92d7 672%if %{with doc}
0afd37aa 673%{_mandir}/man1/git-*.1*
dbde9893 674%exclude %{_mandir}/man1/git-archimport.1*
2c0376c9
AM
675%exclude %{_mandir}/man1/git-svn.1*
676%exclude %{_mandir}/man1/git-cvs*.1*
cfe5bf90
JB
677%exclude %{_mandir}/man1/git-imap-send.1*
678%exclude %{_mandir}/man1/git-p4.1*
679%exclude %{_mandir}/man1/git-send-email.1*
a48d28b8 680%{_mandir}/man1/git.1*
0afd37aa 681%{_mandir}/man5/gitattributes.5*
37741341 682%{_mandir}/man5/gitformat-*.5*
a48d28b8 683%{_mandir}/man5/githooks.5*
0afd37aa 684%{_mandir}/man5/gitignore.5*
eee65439 685%{_mandir}/man5/gitmailmap.5*
785b167d 686%{_mandir}/man5/gitmodules.5*
37741341 687%{_mandir}/man5/gitprotocol-*.5*
a48d28b8
AG
688%{_mandir}/man5/gitrepository-layout.5*
689%{_mandir}/man7/gitcli.7*
690%{_mandir}/man7/gitcore-tutorial.7*
fdf2ed38 691%{_mandir}/man7/gitcredentials.7*
a48d28b8 692%{_mandir}/man7/gitdiffcore.7*
ab67970b 693%{_mandir}/man7/giteveryday.7*
f07f1df6 694%{_mandir}/man7/gitfaq.7*
a48d28b8 695%{_mandir}/man7/gitglossary.7*
60b58680 696%{_mandir}/man7/gitnamespaces.7*
dab2f9ca 697%{_mandir}/man7/gitremote-helpers.7*
f16e8911 698%{_mandir}/man7/gitrevisions.7*
d5e39597 699%{_mandir}/man7/gitsubmodules.7*
a48d28b8
AG
700%{_mandir}/man7/gittutorial-2.7*
701%{_mandir}/man7/gittutorial.7*
670fe4d6 702%{_mandir}/man7/gitworkflows.7*
08cc92d7 703%endif
a8655d02 704
348dee00
ER
705%dir %{gitcoredir}
706%attr(755,root,root) %{gitcoredir}/*-*
707%attr(755,root,root) %{gitcoredir}/git
708%dir %{gitcoredir}/mergetools
709%{gitcoredir}/mergetools/*
a8655d02 710
0d2db069
ER
711%{_datadir}/%{name}
712%{_localstatedir}/lib/git
713
714# subpackages
348dee00
ER
715%exclude %{gitcoredir}/*email*
716%exclude %{gitcoredir}/*p4*
717%exclude %{gitcoredir}/git-archimport
6fbf4942 718%exclude %{gitcoredir}/git-citool
348dee00
ER
719%exclude %{gitcoredir}/git-cvs*
720%exclude %{gitcoredir}/git-gui
721%exclude %{gitcoredir}/git-imap-send
722%exclude %{gitcoredir}/git-instaweb
348dee00
ER
723%exclude %{gitcoredir}/git-svn
724%exclude %{gitcoredir}/mergetools/p4merge
20b80b37
JB
725%if %{with libsecret}
726%exclude %{gitcoredir}/git-credential-libsecret
727%endif
e3cefa79 728
a8655d02
ER
729%if %{with doc}
730%files doc
778b89a7 731%defattr(644,root,root,755)
a8655d02
ER
732%doc Documentation/RelNotes*
733%doc Documentation/*.html Documentation/howto Documentation/technical
734%endif
735
b11ada2c
AG
736%files daemon-inetd
737%defattr(644,root,root,755)
738%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/git-daemon
739
740%files daemon-standalone
741%defattr(644,root,root,755)
742%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/git-daemon
743%attr(754,root, root) /etc/rc.d/init.d/git-daemon
744
e3cefa79 745%files devel
3ff86e9e 746%defattr(644,root,root,755)
cdeb0400 747%{_includedir}/%{name}
5db07614 748%{_libdir}/libgit.a
eaf5c40c 749%{_libdir}/libgit_xdiff.a
5d7220ad 750
7d9cd7eb 751%if %{with tk}
91396e2e
AG
752%files gitk
753%defattr(644,root,root,755)
08cc92d7 754%if %{with doc}
91396e2e 755%{_mandir}/man1/gitk.1*
08cc92d7
ER
756%endif
757%attr(755,root,root) %{_bindir}/gitk
9fa88d97
AM
758%dir %{_datadir}/gitk
759%dir %{_datadir}/gitk/lib
760%dir %{_datadir}/gitk/lib/msgs
5d132744 761%lang(bg) %{_datadir}/gitk/lib/msgs/bg.msg
6cc57eea 762%lang(ca) %{_datadir}/gitk/lib/msgs/ca.msg
3b243bbe 763%lang(de) %{_datadir}/gitk/lib/msgs/de.msg
f9871074 764%lang(es) %{_datadir}/gitk/lib/msgs/es.msg
778b89a7
AM
765%lang(fr) %{_datadir}/gitk/lib/msgs/fr.msg
766%lang(hu) %{_datadir}/gitk/lib/msgs/hu.msg
3b243bbe 767%lang(it) %{_datadir}/gitk/lib/msgs/it.msg
469258c9 768%lang(ja) %{_datadir}/gitk/lib/msgs/ja.msg
3ed82b68 769%lang(pt_BR) %{_datadir}/gitk/lib/msgs/pt_br.msg
22105a2f 770%lang(pt_PT) %{_datadir}/gitk/lib/msgs/pt_pt.msg
95998f97 771%lang(ru) %{_datadir}/gitk/lib/msgs/ru.msg
f9871074 772%lang(sv) %{_datadir}/gitk/lib/msgs/sv.msg
1adc1f85 773%lang(vi) %{_datadir}/gitk/lib/msgs/vi.msg
6a0ecca2 774%lang(zh_CN) %{_datadir}/gitk/lib/msgs/zh_cn.msg
7d9cd7eb 775%endif
91396e2e 776
be2ccf99
AG
777%files gitweb
778%defattr(644,root,root,755)
779%doc gitweb/{README,INSTALL}
780%dir %{webappdir}
be2ccf99
AG
781%config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/apache.conf
782%config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/httpd.conf
51ce768a 783%config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/lighttpd.conf
642ee6ff 784%config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/gitweb.conf
9611d914 785%config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/gitolite.pl
be2ccf99
AG
786%attr(755,root,root) %{cgibindir}/gitweb.cgi
787%{appdir}
348dee00 788%attr(755,root,root) %{gitcoredir}/git-instaweb
93a30d5e 789%if %{with doc}
0c582eb3
AM
790%{_mandir}/man1/gitweb.1*
791%{_mandir}/man5/gitweb.conf.5*
93a30d5e 792%endif
be2ccf99 793
7d9cd7eb 794%if %{with tk}
f9871074
AG
795%files gui
796%defattr(644,root,root,755)
6fbf4942 797%attr(755,root,root) %{gitcoredir}/git-citool
348dee00 798%attr(755,root,root) %{gitcoredir}/git-gui
f9871074
AG
799%dir %{_datadir}/git-gui
800%dir %{_datadir}/git-gui/lib
801%dir %{_datadir}/git-gui/lib/msgs
802%{_datadir}/git-gui/lib/git-gui.ico
803%{_datadir}/git-gui/lib/tclIndex
804%{_datadir}/git-gui/lib/*.js
805%{_datadir}/git-gui/lib/*.tcl
5d132744 806%lang(bg) %{_datadir}/git-gui/lib/msgs/bg.msg
f9871074 807%lang(de) %{_datadir}/git-gui/lib/msgs/de.msg
469258c9 808%lang(el) %{_datadir}/git-gui/lib/msgs/el.msg
f9871074
AG
809%lang(fr) %{_datadir}/git-gui/lib/msgs/fr.msg
810%lang(hu) %{_datadir}/git-gui/lib/msgs/hu.msg
811%lang(it) %{_datadir}/git-gui/lib/msgs/it.msg
812%lang(ja) %{_datadir}/git-gui/lib/msgs/ja.msg
670fe4d6 813%lang(nb) %{_datadir}/git-gui/lib/msgs/nb.msg
345fc12f 814%lang(pt) %{_datadir}/git-gui/lib/msgs/pt_pt.msg
10343d09 815%lang(pt_BR) %{_datadir}/git-gui/lib/msgs/pt_br.msg
f9871074
AG
816%lang(ru) %{_datadir}/git-gui/lib/msgs/ru.msg
817%lang(sv) %{_datadir}/git-gui/lib/msgs/sv.msg
6cc57eea 818%lang(vi) %{_datadir}/git-gui/lib/msgs/vi.msg
35cbc54f 819%lang(zh_CN) %{_datadir}/git-gui/lib/msgs/zh_cn.msg
7d9cd7eb 820%endif
f9871074 821
e5fa8af5
JB
822%files arch
823%defattr(644,root,root,755)
348dee00 824%attr(755,root,root) %{gitcoredir}/git-archimport
e5fa8af5
JB
825%if %{with doc}
826%{_mandir}/man1/git-archimport.1*
827%endif
828
e5fa8af5
JB
829%files cvs
830%defattr(644,root,root,755)
831%attr(755,root,root) %{_bindir}/git-cvsserver
348dee00 832%attr(755,root,root) %{gitcoredir}/git-cvs*
e5fa8af5
JB
833%if %{with doc}
834%{_mandir}/man1/git-cvs*.1*
835%{_mandir}/man7/gitcvs-migration.7*
836%endif
837
0d2db069
ER
838%files p4
839%defattr(644,root,root,755)
348dee00
ER
840%attr(755,root,root) %{gitcoredir}/git-p4
841%attr(755,root,root) %{gitcoredir}/mergetools/p4merge
cfe5bf90
JB
842%if %{with doc}
843%{_mandir}/man1/git-p4.1*
844%endif
0d2db069 845
2c0376c9
AM
846%files svn
847%defattr(644,root,root,755)
348dee00 848%attr(755,root,root) %{gitcoredir}/git-svn
b5884c73 849%{perl_vendorlib}/Git/SVN
bbceff2c 850%{perl_vendorlib}/Git/SVN.pm
2c0376c9
AM
851%if %{with doc}
852%{_mandir}/man1/git-svn.1*
853%endif
854
d82521ea
ER
855%files email
856%defattr(644,root,root,755)
348dee00 857%attr(755,root,root) %{gitcoredir}/git-imap-send
cfe5bf90 858%attr(755,root,root) %{gitcoredir}/git-send-email
d82521ea 859%if %{with doc}
cfe5bf90
JB
860%{_mandir}/man1/git-imap-send.1*
861%{_mandir}/man1/git-send-email.1*
d82521ea
ER
862%endif
863
e1871bee
JP
864%files scalar
865%defattr(644,root,root,755)
866%attr(755,root,root) %{_bindir}/scalar
867%attr(755,root,root) %{gitcoredir}/scalar
868%if %{with doc}
869%{_mandir}/man1/scalar.1*
870%endif
871
f2c1983d
AG
872%files -n bash-completion-git
873%defattr(644,root,root,755)
3102984c 874%{bash_compdir}/git
f2c1983d 875
3dc01deb 876%files -n perl-Git
5d7220ad 877%defattr(644,root,root,755)
3dc01deb 878%{perl_vendorlib}/Git.pm
b5884c73
KK
879%dir %{perl_vendorlib}/Git
880%{perl_vendorlib}/Git/I18N.pm
bbceff2c 881%{perl_vendorlib}/Git/IndexInfo.pm
6fa8665e 882%{perl_vendorlib}/Git/LoadCPAN.pm
499c2b98 883%{perl_vendorlib}/Git/Packet.pm
6fa8665e
JP
884%dir %{perl_vendorlib}/Git/LoadCPAN
885%{perl_vendorlib}/Git/LoadCPAN/Error.pm
886%dir %{perl_vendorlib}/Git/LoadCPAN/Mail
887%{perl_vendorlib}/Git/LoadCPAN/Mail/Address.pm
233261d9 888%{?with_doc:%{_mandir}/man3/Git.3pm*}
0643d0ea 889
20b80b37
JB
890%if %{with libsecret}
891%files credential-libsecret
892%defattr(644,root,root,755)
893%attr(755,root,root) %{gitcoredir}/git-credential-libsecret
894%endif
d500b766
JP
895
896%files -n zsh-completion-git
897%defattr(644,root,root,755)
898%{zsh_compdir}/_git
This page took 0.766145 seconds and 5 git commands to generate.