]> git.pld-linux.org Git - packages/cgit.git/blame - cgit.spec
- added lua support
[packages/cgit.git] / cgit.spec
CommitLineData
bf1ce868 1Summary: cgit - a fast webinterface to git
da36549f 2Summary(pl.UTF-8): cgit - szybki interfejs WWW do gita
bf1ce868 3Name: cgit
08d38ec4 4Version: 0.10
33b562e6 5Release: 2
bf1ce868
AG
6License: GPL v2
7Group: Development/Tools
eda47dc4 8Source0: http://git.zx2c4.com/cgit/snapshot/%{name}-%{version}.tar.xz
08d38ec4 9# Source0-md5: 19944c17ecea1b1d1944718ce8ce6b61
bf1ce868
AG
10Source1: %{name}.conf
11Source2: %{name}-repo.conf
6e601396 12Source3: %{name}-apache.conf
ca7782e7 13Patch0: %{name}-system-git.patch
33b562e6 14Patch1: %{name}-lua.patch
eda47dc4 15URL: http://git.zx2c4.com/cgit/about/
08d38ec4 16BuildRequires: git-core-devel >= 1.8.5
33b562e6 17BuildRequires: lua-devel >= 5.0
bf1ce868 18BuildRequires: openssl-devel
77429544 19BuildConflicts: zlib-devel = 1.2.5-1
bf1ce868
AG
20Requires: webapps
21BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23%define webapp cgit
24%define webappdir %{_sysconfdir}/webapps/%{webapp}
25%define appdir %{_datadir}/%{webapp}
26%define cgibindir %{_prefix}/lib/cgi-bin
27
eda47dc4
KK
28%define _noautoreqfiles %{_libdir}/cgit/filters
29
bf1ce868
AG
30%description
31Cgit is a CGI application implemented in C: it's basically (yet)
da36549f 32another git command, used to generate HTML. Cgit is not forking: all
bf1ce868 33git operations are performed by linking with libgit.a. It uses a
da36549f 34built-in cache: the generated HTML is stored on disk for the benefit
bf1ce868
AG
35of later requests.
36
37%description -l pl.UTF-8
da36549f
JB
38Cgit to napisana w C aplikacja CGI - zasadniczo jest to (kolejny)
39interfejs do gita, generujący kod HTML. Cgit jest aplikacją
bf1ce868
AG
40nieforkującą - wszystkie operacje na repozytoriach wykonywane są z
41użyciem biblioteki. Aplikacja ta korzysta z cache - wygenerowany kod
da36549f 42HTML zapisany jest na dysku dla kolejnych żądań.
bf1ce868
AG
43
44%prep
45%setup -q
46%patch0 -p1
33b562e6 47%patch1 -p1
eda47dc4 48cp %{_includedir}/git-core/{Makefile,config.*} git
bf1ce868
AG
49
50%build
51%{__make} \
eda47dc4 52 V=1 \
bf1ce868
AG
53 CC="%{__cc}" \
54 CFLAGS="%{rpmcflags} -I/usr/include/git-core" \
55 LDFLAGS="%{rpmldflags}" \
6815c324 56 LIBDIR=%{_libdir} \
bf1ce868 57 CGIT_CONFIG="%{webappdir}/%{webapp}.conf" \
08d38ec4 58 CGIT_SCRIPT_PATH="%{cgibindir}"
bf1ce868
AG
59
60%install
61rm -rf $RPM_BUILD_ROOT
62
eda47dc4
KK
63# The same CFLAGS as in %build stage has to be passed to avoid
64# "new build flags" logic in Makefile
bf1ce868 65%{__make} install \
08d38ec4 66 V=1 \
bf1ce868 67 DESTDIR=$RPM_BUILD_ROOT \
08d38ec4 68 prefix=%{_prefix} \
eda47dc4
KK
69 CFLAGS="%{rpmcflags} -I/usr/include/git-core" \
70 CGIT_CONFIG="%{webappdir}/%{webapp}.conf" \
1807596b 71 CGIT_DATA_PATH="%{appdir}" \
08d38ec4 72 CGIT_SCRIPT_PATH="%{cgibindir}"
bf1ce868 73
bf1ce868
AG
74# cache
75install -d $RPM_BUILD_ROOT/var/cache/cgit
76
77# webapp stuff
78install -d $RPM_BUILD_ROOT%{webappdir}
79install %{SOURCE1} $RPM_BUILD_ROOT%{webappdir}
80install %{SOURCE2} $RPM_BUILD_ROOT%{webappdir}
81install %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/apache.conf
08d38ec4 82install %{SOURCE3} $RPM_BUILD_ROOT%{webappdir}/httpd.conf
bf1ce868
AG
83
84%clean
85rm -rf $RPM_BUILD_ROOT
86
87%triggerin -- apache1 < 1.3.37-3, apache1-base
88%webapp_register apache %{webapp}
89
90%triggerun -- apache1 < 1.3.37-3, apache1-base
91%webapp_unregister apache %{webapp}
92
6e601396 93%triggerin -- apache-base
bf1ce868
AG
94%webapp_register httpd %{webapp}
95
6e601396 96%triggerun -- apache-base
bf1ce868
AG
97%webapp_unregister httpd %{webapp}
98
99%files
100%defattr(644,root,root,755)
101%doc README cgitrc.5.txt
102%dir %{webappdir}
103%config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/cgit.conf
104%config(noreplace) %verify(not md5 mtime size) %attr(640,root,http) %{webappdir}/cgit-repo.conf
105%config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/apache.conf
106%config(noreplace) %verify(not md5 mtime size) %attr(640,root,root) %{webappdir}/httpd.conf
107%attr(755,root,root) %{cgibindir}/cgit.cgi
108%attr(770,root,http) /var/cache/cgit
109%{appdir}
579c7c9d
JR
110%dir %{_prefix}/lib/cgit
111%dir %{_prefix}/lib/cgit/filters
eda47dc4 112%attr(755,root,root) %{_prefix}/lib/cgit/filters/about-formatting.sh
579c7c9d 113%attr(755,root,root) %{_prefix}/lib/cgit/filters/commit-links.sh
33b562e6 114%attr(655,root,root) %{_prefix}/lib/cgit/filters/email-gravatar.lua
08d38ec4 115%attr(755,root,root) %{_prefix}/lib/cgit/filters/email-gravatar.py
33b562e6 116%attr(655,root,root) %{_prefix}/lib/cgit/filters/simple-authentication.lua
08d38ec4 117%attr(755,root,root) %{_prefix}/lib/cgit/filters/syntax-highlighting.py
579c7c9d 118%attr(755,root,root) %{_prefix}/lib/cgit/filters/syntax-highlighting.sh
33b562e6
ŁK
119%dir %{_prefix}/lib/cgit/filters/html-converters
120%attr(755,root,root) %{_prefix}/lib/cgit/filters/html-converters/man2html
121%attr(755,root,root) %{_prefix}/lib/cgit/filters/html-converters/md2html
122%attr(755,root,root) %{_prefix}/lib/cgit/filters/html-converters/rst2html
123%attr(755,root,root) %{_prefix}/lib/cgit/filters/html-converters/txt2html
124%dir %{_prefix}/lib/cgit/filters/html-converters/resources
125%attr(755,root,root) %{_prefix}/lib/cgit/filters/html-converters/resources/markdown.pl
126%attr(655,root,root) %{_prefix}/lib/cgit/filters/html-converters/resources/rst-template.txt
This page took 0.066947 seconds and 4 git commands to generate.