]> git.pld-linux.org Git - packages/cherokee.git/blame - cherokee.spec
- update upstart deps
[packages/cherokee.git] / cherokee.spec
CommitLineData
0f615d6e 1#
abf5f06b 2# TODO:
0f615d6e
JK
3# - think about moving modules to subpackages. At least, those with extra
4# dependencies.
d469ca68 5# - maybe there is no need to pack *.py (are *.pyc enough?)
01abcdff
JB
6#
7# Conditional build:
3319fba3 8%bcond_without geoip # without GeoIP support
56ea9d0b
JK
9%bcond_without mysql # without MySQL support
10%bcond_without ldap # without LDAP support
11%bcond_without ffmpeg # without ffmpeg support
01d41beb 12#
01d41beb 13Summary: Fast, Flexible and Lightweight Web server
56ec7482 14Summary(pl.UTF-8): Cherokee - serwer WWW
0e85b34f 15Name: cherokee
58fe2b83 16Version: 1.2.98
9b4b1cc3 17Release: 4
01d41beb 18License: GPL v2
8c503f01 19Group: Networking/Daemons
58fe2b83
JK
20Source0: http://www.cherokee-project.com/download/1.2/%{version}/%{name}-%{version}.tar.gz
21# Source0-md5: 21b01e7d45c0e82ecc0c4257a9c27feb
01d41beb
ER
22Source1: %{name}.init
23Source2: %{name}.sysconfig
ac2feb08 24Source3: %{name}.upstart
1bdedc57 25Patch0: %{name}-config.patch
769faa4b 26Patch1: %{name}-panic_path.patch
72ce7982 27URL: http://www.cherokee-project.com/
90a7df58 28%{?with_geoip:BuildRequires: GeoIP-devel}
1bdedc57
ER
29BuildRequires: autoconf
30BuildRequires: automake
56ea9d0b 31%{?with_ffmpeg:BuildRequires: ffmpeg-devel}
ca7698e4 32BuildRequires: gettext-devel
3319fba3 33BuildRequires: libtool
56ea9d0b
JK
34%{?with_mysql:BuildRequires: mysql-devel}
35%{?with_ldap:BuildRequires: openldap-devel}
abf5f06b 36BuildRequires: openssl-devel
cfbc51f9 37BuildRequires: pam-devel
01d41beb 38BuildRequires: pcre-devel
68df699b 39BuildRequires: php(fcgi)
cfbc51f9 40BuildRequires: pkgconfig
8c2165c6 41BuildRequires: python-docutils
3319fba3 42BuildRequires: rpm-pythonprov
ac2feb08 43BuildRequires: rpmbuild(macros) >= 1.561
cfbc51f9 44BuildRequires: zlib-devel
0d94535f 45Requires(post,preun): /sbin/chkconfig
1bdedc57
ER
46Requires(postun): /usr/sbin/groupdel
47Requires(postun): /usr/sbin/userdel
48Requires(pre): /bin/id
49Requires(pre): /usr/bin/getgid
50Requires(pre): /usr/sbin/groupadd
51Requires(pre): /usr/sbin/useradd
d8be9859 52Requires: %{name}-libs = %{version}-%{release}
0d94535f 53Requires: rc-scripts >= 0.4.3.0
e8c0b4db 54Suggests: %{name}-admin = %{version}-%{release}
68df699b 55Suggests: php(fcgi)
1bdedc57
ER
56Provides: group(cherokee)
57Provides: group(http)
58Provides: user(cherokee)
bdfcbc7b 59Provides: webserver
e4201e2f 60Provides: webserver(indexfile)
8c503f01 61BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
0e85b34f 62
01d41beb
ER
63%define _sysconfdir /etc/cherokee
64%define _wwwhome /home/services/%{name}
65%define _wwwroot %{_wwwhome}/html
66
0e85b34f 67%description
01d41beb
ER
68Cherokee is a flexible, very fast, lightweight Web server. It is
69implemented entirely in C, and has no dependencies beyond a standard C
a40f27e9 70library. It is embeddable and extensible with plug-ins. It supports
abf5f06b 71on-the-fly configuration by reading files or strings, TLS/SSL via
72OpenSSL, virtual hosts, authentication, cache friendly features, PHP,
73custom error management, and much more.
0e85b34f 74
fd499fdf 75%description -l pl.UTF-8
a40f27e9 76Cherokee to elastyczny, bardzo szybki i lekki serwer WWW. Jest
fd499fdf
JR
77zaimplementowany całkowicie w C i nie ma zależności poza standardową
78biblioteką C. Jest osadzalny i rozbudowywalny poprzez wtyczki.
79Obsługuje konfigurację w locie poprzez odczyt plików lub łańcuchów
abf5f06b 80znaków, TLS/SSL poprzez OpenSSL, hosty wirtualne, uwierzytelnianie,
81opcje związane z pamięcią podręczną, PHP, własne zarządzanie błędami i
82wiele więcej.
8c503f01 83
ac2feb08
JK
84%package upstart
85Summary: Upstart job description for the Cherokee web server
86Summary(pl.UTF-8): Opis zadania Upstart dla serwera Cherokee
87Group: Daemons
88Requires: %{name} = %{version}-%{release}
89Requires: upstart >= 0.6
90
91%description upstart
92Upstart job description for the Cherokee web server.
93
94%description upstart -l pl.UTF-8
95Opis zadania Upstart dla serwera WWW Cherokee.
96
e8c0b4db
JK
97%package admin
98Summary: Cherokee web server administration interface
99Summary(pl.UTF-8): Interfejs administracyjny serwera WWW Cherokee
100Group: Networking/Daemons
ca7698e4 101Requires: %{name} = %{version}-%{release}
e8c0b4db
JK
102Requires: python
103Requires: python-modules
d8be9859 104
e8c0b4db
JK
105%description admin
106Cherokee web server administration interface.
d8be9859 107
e8c0b4db
JK
108%description admin -l pl.UTF-8
109Interfejs administracyjny serwera WWW Cherokee.
d8be9859 110
0e85b34f 111%package devel
8c503f01 112Summary: Header files for Cherokee web server
56ec7482 113Summary(pl.UTF-8): Pliki nagłówkowe dla serwera WWW Cherokee
8c503f01 114Group: Development/Libraries
d8be9859 115Requires: %{name}-libs = %{version}-%{release}
0e85b34f 116
117%description devel
8c503f01
JB
118Header files for Cherokee web server.
119
fd499fdf
JR
120%description devel -l pl.UTF-8
121Pliki nagłówkowe dla serwera WWW Cherokee.
0e85b34f 122
e8c0b4db
JK
123%package libs
124Summary: Cherokee web server libraries
125Summary(pl.UTF-8): Biblioteki serwera WWW Cherokee
126Group: Libraries
127
128%description libs
129Cherokee web server libraries.
130
131%description libs -l pl.UTF-8
132Biblioteki serwera WWW Cherokee.
133
0e85b34f 134%prep
135%setup -q
1bdedc57
ER
136%patch0 -p1
137%patch1 -p1
0e85b34f 138
139%build
3319fba3 140%{__libtoolize}
1bdedc57
ER
141%{__aclocal} -I m4
142%{__autoconf}
143%{__autoheader}
144%{__automake}
0e85b34f 145%configure \
769faa4b 146 --with-php=/usr/bin/php.cgi \
cfbc51f9 147 --disable-static \
3319fba3 148 --enable-os-string="PLD Linux" \
3319fba3
KK
149 --sysconfdir=/etc \
150 --with-wwwroot=%{_wwwroot} \
abf5f06b 151 --with-wwwuser=cherokee \
152 --with-wwwgroup=http \
56ea9d0b
JK
153 %{!?with_geoip:--without-geoip} \
154 %{!?with_mysql:--without-mysql} \
155 %{!?with_ffmpeg:--without-ffmpeg} \
156 %{!?with_ldap:--without-ldap}
0e85b34f 157%{__make}
158
159%install
160rm -rf $RPM_BUILD_ROOT
ac2feb08 161install -d $RPM_BUILD_ROOT{/etc/{init,pam.d,sysconfig,rc.d/init.d},/var/log/%{name}}
8c503f01 162
223f9f35 163%{__make} -j1 install \
8c503f01
JB
164 DESTDIR=$RPM_BUILD_ROOT
165
01d41beb
ER
166install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
167install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
ac2feb08 168install %{SOURCE3} $RPM_BUILD_ROOT/etc/init/%{name}.conf
01d41beb 169
1bdedc57
ER
170# users don't need this
171mv $RPM_BUILD_ROOT{%{_bindir},%{_sbindir}}/cherokee-panic
1bdedc57 172
cfbc51f9
JB
173# modules dlopened by *.so
174rm -f $RPM_BUILD_ROOT%{_libdir}/cherokee/lib*.la
175
01d41beb
ER
176# unify manual dir
177rm -rf html
178mv $RPM_BUILD_ROOT%{_docdir}/%{name} html
179
3b7d94a5
JK
180# provided via %doc
181rm $RPM_BUILD_ROOT/etc/cherokee/cherokee.conf.perf_sample
182
d469ca68
JK
183# compile python modules, otherwise *.pyc may get generated on runtime
184# and stay after package removal
185%py_comp $RPM_BUILD_ROOT%{_datadir}/cherokee/admin/
186
769faa4b
JK
187# seems like this is not needed on Linux
188rm $RPM_BUILD_ROOT%{_bindir}/cherokee-macos-askpass
189
0bb5c2e0 190mv $RPM_BUILD_ROOT%{_localedir}/{sv_SE,sv}
3b7d94a5
JK
191%find_lang %{name}
192
d469ca68 193
8c503f01
JB
194%clean
195rm -rf $RPM_BUILD_ROOT
0e85b34f 196
1bdedc57
ER
197%pre
198%groupadd -g 161 cherokee
199%groupadd -g 51 http
200%useradd -u 161 -d %{_wwwhome} -c "Cherokee User" -g cherokee cherokee
201%addusertogroup cherokee http
202
01d41beb 203%post
01d41beb 204/sbin/chkconfig --add %{name}
c61a601c
ER
205%service %{name} restart "Cherokee webserver"
206exit 0
01d41beb
ER
207
208%preun
209if [ "$1" = "0" ]; then
210 %service %{name} stop
211 /sbin/chkconfig --del %{name}
212fi
213
1bdedc57 214%postun
1bdedc57 215if [ "$1" = "0" ]; then
c61a601c
ER
216 %userremove cherokee
217 %groupremove cherokee
1bdedc57
ER
218 %groupremove http
219fi
cfbc51f9 220
ac2feb08
JK
221%post upstart
222%upstart_post %{name}
223
224%postun upstart
225%upstart_postun %{name}
226
d8be9859
JB
227%post libs -p /sbin/ldconfig
228%postun libs -p /sbin/ldconfig
229
e8c0b4db 230%files
0e85b34f 231%defattr(644,root,root,755)
ac236727 232%doc AUTHORS ChangeLog html performance.conf.sample
0adbe1dc
ER
233%dir %attr(750,root,root) %{_sysconfdir}
234%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cherokee.conf
01d41beb 235
2911a3cb 236%config(noreplace) %verify(not md5 mtime size) /etc/pam.d/cherokee
01d41beb
ER
237%config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/cherokee
238%attr(754,root,root) /etc/rc.d/init.d/cherokee
239
ac236727 240%attr(755,root,root) %{_bindir}/CTK-run
01d41beb 241%attr(755,root,root) %{_bindir}/cget
72ce7982 242%attr(755,root,root) %{_bindir}/cherokee-tweak
01d41beb 243%attr(755,root,root) %{_sbindir}/cherokee
3319fba3
KK
244%attr(755,root,root) %{_sbindir}/cherokee-panic
245%attr(755,root,root) %{_sbindir}/cherokee-worker
01d41beb 246
0e85b34f 247%dir %{_libdir}/cherokee
1bdedc57 248%attr(755,root,root) %{_libdir}/cherokee/libplugin_admin.so
72ce7982 249%attr(755,root,root) %{_libdir}/cherokee/libplugin_and.so
abf5f06b 250%attr(755,root,root) %{_libdir}/cherokee/libplugin_authlist.so
251%attr(755,root,root) %{_libdir}/cherokee/libplugin_bind.so
01d41beb
ER
252%attr(755,root,root) %{_libdir}/cherokee/libplugin_cgi.so
253%attr(755,root,root) %{_libdir}/cherokee/libplugin_combined.so
254%attr(755,root,root) %{_libdir}/cherokee/libplugin_common.so
3319fba3 255%attr(755,root,root) %{_libdir}/cherokee/libplugin_custom_error.so
abf5f06b 256%attr(755,root,root) %{_libdir}/cherokee/libplugin_custom.so
56ea9d0b 257%{?with_mysql:%attr(755,root,root) %{_libdir}/cherokee/libplugin_dbslayer.so}
3319fba3 258%attr(755,root,root) %{_libdir}/cherokee/libplugin_deflate.so
72ce7982 259%attr(755,root,root) %{_libdir}/cherokee/libplugin_directory.so
01d41beb 260%attr(755,root,root) %{_libdir}/cherokee/libplugin_dirlist.so
58fe2b83 261%attr(755,root,root) %{_libdir}/cherokee/libplugin_drop.so
abf5f06b 262%attr(755,root,root) %{_libdir}/cherokee/libplugin_empty_gif.so
3319fba3 263%attr(755,root,root) %{_libdir}/cherokee/libplugin_error_nn.so
01d41beb 264%attr(755,root,root) %{_libdir}/cherokee/libplugin_error_redir.so
abf5f06b 265%attr(755,root,root) %{_libdir}/cherokee/libplugin_evhost.so
266%attr(755,root,root) %{_libdir}/cherokee/libplugin_exists.so
72ce7982 267%attr(755,root,root) %{_libdir}/cherokee/libplugin_extensions.so
769faa4b 268%attr(755,root,root) %{_libdir}/cherokee/libplugin_failover.so
8c2165c6 269%attr(755,root,root) %{_libdir}/cherokee/libplugin_fcgi.so
01d41beb 270%attr(755,root,root) %{_libdir}/cherokee/libplugin_file.so
abf5f06b 271%attr(755,root,root) %{_libdir}/cherokee/libplugin_from.so
272%attr(755,root,root) %{_libdir}/cherokee/libplugin_fullpath.so
0a169935 273%{?with_geoip:%attr(755,root,root) %{_libdir}/cherokee/libplugin_geoip.so}
01d41beb 274%attr(755,root,root) %{_libdir}/cherokee/libplugin_gzip.so
72ce7982 275%attr(755,root,root) %{_libdir}/cherokee/libplugin_header.so
01d41beb
ER
276%attr(755,root,root) %{_libdir}/cherokee/libplugin_htdigest.so
277%attr(755,root,root) %{_libdir}/cherokee/libplugin_htpasswd.so
abf5f06b 278%attr(755,root,root) %{_libdir}/cherokee/libplugin_ip_hash.so
56ea9d0b 279%{?with_ldap:%attr(755,root,root) %{_libdir}/cherokee/libplugin_ldap.so}
abf5f06b 280%attr(755,root,root) %{_libdir}/cherokee/libplugin_libssl.so
281%attr(755,root,root) %{_libdir}/cherokee/libplugin_method.so
56ea9d0b 282%{?with_mysql:%attr(755,root,root) %{_libdir}/cherokee/libplugin_mysql.so}
01d41beb 283%attr(755,root,root) %{_libdir}/cherokee/libplugin_ncsa.so
72ce7982
PZ
284%attr(755,root,root) %{_libdir}/cherokee/libplugin_not.so
285%attr(755,root,root) %{_libdir}/cherokee/libplugin_or.so
01d41beb 286%attr(755,root,root) %{_libdir}/cherokee/libplugin_pam.so
01d41beb 287%attr(755,root,root) %{_libdir}/cherokee/libplugin_plain.so
3b7d94a5
JK
288%attr(755,root,root) %{_libdir}/cherokee/libplugin_post_report.so
289%attr(755,root,root) %{_libdir}/cherokee/libplugin_post_track.so
3319fba3 290%attr(755,root,root) %{_libdir}/cherokee/libplugin_proxy.so
01d41beb 291%attr(755,root,root) %{_libdir}/cherokee/libplugin_redir.so
abf5f06b 292%attr(755,root,root) %{_libdir}/cherokee/libplugin_rehost.so
293%attr(755,root,root) %{_libdir}/cherokee/libplugin_render_rrd.so
72ce7982 294%attr(755,root,root) %{_libdir}/cherokee/libplugin_request.so
8c2165c6 295%attr(755,root,root) %{_libdir}/cherokee/libplugin_round_robin.so
abf5f06b 296%attr(755,root,root) %{_libdir}/cherokee/libplugin_rrd.so
8c2165c6 297%attr(755,root,root) %{_libdir}/cherokee/libplugin_scgi.so
abf5f06b 298%attr(755,root,root) %{_libdir}/cherokee/libplugin_secdownload.so
01d41beb 299%attr(755,root,root) %{_libdir}/cherokee/libplugin_server_info.so
abf5f06b 300%attr(755,root,root) %{_libdir}/cherokee/libplugin_ssi.so
7dfcc630 301%if %{with ffmpeg}
abf5f06b 302%attr(755,root,root) %{_libdir}/cherokee/libplugin_streaming.so
7dfcc630 303%endif
abf5f06b 304%attr(755,root,root) %{_libdir}/cherokee/libplugin_target_ip.so
2ff65984 305%attr(755,root,root) %{_libdir}/cherokee/libplugin_tls.so
3b7d94a5 306%attr(755,root,root) %{_libdir}/cherokee/libplugin_url_arg.so
abf5f06b 307%attr(755,root,root) %{_libdir}/cherokee/libplugin_uwsgi.so
ac236727 308%attr(755,root,root) %{_libdir}/cherokee/libplugin_v_or.so
abf5f06b 309%attr(755,root,root) %{_libdir}/cherokee/libplugin_wildcard.so
01d41beb 310
01d41beb 311%{_mandir}/man1/cget.1*
72ce7982 312%{_mandir}/man1/cherokee.1*
3319fba3
KK
313%{_mandir}/man1/cherokee-tweak.1*
314%{_mandir}/man1/cherokee-worker.1*
01d41beb 315
72ce7982 316%dir %{_datadir}/cherokee
72ce7982
PZ
317%{_datadir}/cherokee/deps
318%{_datadir}/cherokee/icons
72ce7982 319%{_datadir}/cherokee/themes
01d41beb
ER
320
321%dir %{_wwwhome}
0adbe1dc
ER
322%dir %{_wwwroot}
323%config(missingok) %{_wwwroot}/*
324
3319fba3 325%dir %attr(750,cherokee,logs) /var/log/%{name}
0e85b34f 326
0bb5c2e0
JK
327%dir %attr(771,root,cherokee) /var/lib/%{name}
328%dir %attr(771,cherokee,cherokee) /var/lib/%{name}/graphs
329%dir %attr(771,cherokee,cherokee) /var/lib/%{name}/graphs/images
330
ac2feb08
JK
331%files upstart
332%defattr(644,root,root,755)
333%config(noreplace) %verify(not md5 mtime size) /etc/init/%{name}.conf
334
e8c0b4db
JK
335%files admin -f %{name}.lang
336%defattr(644,root,root,755)
337%attr(755,root,root) %{_sbindir}/cherokee-admin
769faa4b 338%attr(755,root,root) %{_bindir}/cherokee-admin-launcher
e8c0b4db 339%{_mandir}/man1/cherokee-admin.1*
769faa4b 340%{_mandir}/man1/cherokee-admin-launcher.1*
e8c0b4db
JK
341%dir %{_datadir}/cherokee/admin
342%{_datadir}/cherokee/admin/cherokee.conf.sample
343%{_datadir}/cherokee/admin/performance.conf.sample
344%{_datadir}/cherokee/admin/*.html
345%attr(755,root,root) %{_datadir}/cherokee/admin/*.py
d469ca68 346%{_datadir}/cherokee/admin/*.pyc
e8c0b4db 347%{_datadir}/cherokee/admin/static
d469ca68
JK
348%dir %{_datadir}/cherokee/admin/CTK
349%dir %{_datadir}/cherokee/admin/CTK/CTK
350%{_datadir}/cherokee/admin/CTK/CTK/*.py
351%{_datadir}/cherokee/admin/CTK/CTK/*.pyc
352%{_datadir}/cherokee/admin/CTK/static
353%dir %{_datadir}/cherokee/admin/plugins
354%{_datadir}/cherokee/admin/plugins/*.py
355%{_datadir}/cherokee/admin/plugins/*.pyc
356%dir %{_datadir}/cherokee/admin/wizards
357%{_datadir}/cherokee/admin/wizards/*.py
358%{_datadir}/cherokee/admin/wizards/*.pyc
ac236727
JK
359%dir %{_datadir}/cherokee/admin/market
360%{_datadir}/cherokee/admin/market/*.py
361%{_datadir}/cherokee/admin/market/*.pyc
769faa4b
JK
362%dir %{_datadir}/cherokee/admin/icons
363%{_datadir}/cherokee/admin/icons/*.png
364%{_datadir}/cherokee/admin/icons/*.svg
e8c0b4db 365
d8be9859
JB
366%files libs
367%defattr(644,root,root,755)
368%attr(755,root,root) %{_libdir}/libcherokee-base.so.*.*.*
369%attr(755,root,root) %ghost %{_libdir}/libcherokee-base.so.0
370%attr(755,root,root) %{_libdir}/libcherokee-client.so.*.*.*
371%attr(755,root,root) %ghost %{_libdir}/libcherokee-client.so.0
d8be9859
JB
372%attr(755,root,root) %{_libdir}/libcherokee-server.so.*.*.*
373%attr(755,root,root) %ghost %{_libdir}/libcherokee-server.so.0
374
0e85b34f 375%files devel
8c503f01 376%defattr(644,root,root,755)
0e85b34f 377%attr(755,root,root) %{_bindir}/cherokee-config
72ce7982 378%attr(755,root,root) %{_libdir}/libcherokee-base.so
72ce7982 379%attr(755,root,root) %{_libdir}/libcherokee-client.so
72ce7982 380%attr(755,root,root) %{_libdir}/libcherokee-server.so
d8be9859
JB
381%{_libdir}/libcherokee-base.la
382%{_libdir}/libcherokee-client.la
d8be9859 383%{_libdir}/libcherokee-server.la
8c503f01
JB
384%{_includedir}/cherokee
385%{_pkgconfigdir}/cherokee.pc
386%{_aclocaldir}/cherokee.m4
387%{_mandir}/man1/cherokee-config.1*
This page took 0.104311 seconds and 4 git commands to generate.