]> git.pld-linux.org Git - packages/squid.git/blob - squid.spec
- updated more patches
[packages/squid.git] / squid.spec
1 # TODO
2 # - REVIEW patches and configuration
3 # - use /usr/lib/cgi-bin instead of /home/services
4 # - ZPH TOS -
5 # For this to work correctly, you will need to patch your linux
6 # kernel with the TOS preserving ZPH patch.
7 # The kernel patch can be downloaded from http://zph.bratcheda.org
8 #
9 # Conditional build:
10 %bcond_with     combined_log    # enables apache-like combined log format
11 #
12 Summary:        SQUID Internet Object Cache
13 Summary(es.UTF-8):      proxy/cache para WWW/FTP/gopher
14 Summary(pl.UTF-8):      Uniwersalny serwer proxy-cache
15 Summary(pt_BR.UTF-8):   Cache Squid de objetos Internet
16 Summary(ru.UTF-8):      Squid - кэш объектов Internet
17 Summary(uk.UTF-8):      Squid - кеш об'єктів Internet
18 Summary(zh_CN.UTF-8):   SQUID 高速缓冲代理服务器
19 Name:           squid
20 Version:        3.0.STABLE9
21 # review patches before stable release
22 Release:        0.1
23 Epoch:          7
24 License:        GPL v2
25 Group:          Networking/Daemons
26 Source0:        http://www.squid-cache.org/Versions/v3/3.0/%{name}-%{version}.tar.bz2
27 # Source0-md5:  4009abfbf33d86f40db3ec4280716a0e
28 # http://www.squid-cache.org/Doc/FAQ/FAQ.tar.gz
29 Source1:        %{name}-FAQ.tar.gz
30 # Source1-md5:  cb9a955f8cda9cc166e086fccd412a43
31 Source2:        %{name}.init
32 Source3:        %{name}.sysconfig
33 # http://squid-docs.sourceforge.net/latest/zip-files/book-full-html.zip
34 Source4:        http://squid-docs.sourceforge.net/latest/zip-files/book-full-html.zip
35 # Source4-md5:  4f3b6dab1de9cbb847df89d8b417378a
36 Source5:        %{name}.conf.patch
37 Source6:        %{name}.logrotate
38 Source7:        %{name}.pamd
39 # Bug fixes from Squid home page, please include URL
40 # lets have fun - there is no patches... yet:)
41 # Other patches:
42 # http://zph.bratcheda.org/
43 Patch0:         %{name}_hit_miss_mark.patch
44 Patch1:         %{name}-fhs.patch
45 Patch2:         %{name}-location.patch
46 Patch4:         %{name}-libnsl_fixes.patch
47 Patch5:         %{name}-crash-on-ENOSPC.patch
48 Patch6:         %{name}-newssl.patch
49 Patch7:         %{name}-empty-referer.patch
50 Patch8:         %{name}-2.5.STABLE4-apache-like-combined-log.patch
51 Patch9:         %{name}-auth_on_acceleration.patch
52 Patch10:        %{name}-ppc-m32.patch
53 URL:            http://www.squid-cache.org/
54 BuildRequires:  autoconf
55 BuildRequires:  automake
56 BuildRequires:  cyrus-sasl-devel >= 2.1.0
57 BuildRequires:  db-devel
58 BuildRequires:  libltdl-devel
59 BuildRequires:  openldap-devel >= 2.3.0
60 BuildRequires:  openssl-devel >= 0.9.7d
61 BuildRequires:  pam-devel
62 BuildRequires:  perl-base
63 BuildRequires:  rpmbuild(macros) >= 1.268
64 BuildRequires:  sed >= 4.0
65 BuildRequires:  unzip
66 Requires(post): /bin/hostname
67 Requires(post): fileutils
68 Requires(post): findutils
69 Requires(post): grep
70 Requires(post,preun):   /sbin/chkconfig
71 Requires(postun):       /usr/sbin/groupdel
72 Requires(postun):       /usr/sbin/userdel
73 Requires(pre):  /bin/id
74 Requires(pre):  /usr/bin/getgid
75 Requires(pre):  /usr/lib/rpm/user_group.sh
76 Requires(pre):  /usr/sbin/groupadd
77 Requires(pre):  /usr/sbin/useradd
78 Requires:       rc-scripts >= 0.2.0
79 Requires:       setup >= 2.4.6
80 Provides:       group(squid)
81 # epoll enabled by default:
82 Requires:       uname(release) >= 2.6
83 Provides:       user(squid)
84 Conflicts:      logrotate < 3.7-4
85 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
86
87 %define         _libexecdir     %{_libdir}/%{name}
88 %define         _sysconfdir     /etc/%{name}
89 %define         _cgidir         /home/services/httpd/cgi-bin
90
91 %description
92 Squid is a high-performance proxy caching server for web clients,
93 supporting FTP, gopher, and HTTP data objects. Unlike traditional
94 caching software, Squid handles all requests in a single,
95 non-blocking, I/O-driven process. Squid keeps meta data and especially
96 hot objects cached in RAM, caches DNS lookups, supports non-blocking
97 DNS lookups, and implements negative caching of failed requests. If
98 you are tight on memory, check out the NOVM version of this package.
99 Squid supports SSL, extensive access controls, and full request
100 logging. By using the lightweight Internet Cache Protocol, Squid
101 caches can be arranged in a hierarchy or mesh for additional bandwidth
102 savings. Squid consists of a main server program squid, a Domain Name
103 System lookup program dnsserver, a program for retrieving FTP data
104 ftpget, and some management and client tools. When squid starts up, it
105 spawns a configurable number of dnsserver processes, each of which can
106 perform a single, blocking Domain Name System (DNS) lookup. This
107 reduces the amount of time the cache waits for DNS lookups. Squid is
108 derived from the ARPA-funded Harvest project.
109
110 %description -l es.UTF-8
111 Squid es un servidor proxy con caché de alto desempeño para clientes
112 web, soportando FTP, gopher y HTTP. Diferentemente de softwares
113 tradicionales de caché squid manipula todas las requisiciones en un
114 único proceso sin bloqueos, direccionado a E/S. Mantienen metadatos y
115 objetos frecuentemente pedidos en uno caché en memoria RAM. Hace caché
116 de resoluciones DNS, soporta resoluciones DNS sin bloqueo y implementa
117 un caché negativo de requisiciones que fallen. Si tiene poca memoria
118 da un vistazo en la versión NOVM de este paquete. También soporta SSL,
119 controles extensivos de acceso y registro (log) completo de las
120 requisiciones. Usando el ligero Protocolo de Caches Internet (ICP)
121 puede ser usado en una jerarquía de servidores para mayor ahorro de la
122 banda de comunicación. Está compuesto del programa squid (servidor
123 principal), del programa dnsserver (para resolución DNS), del programa
124 ftpget (para transmisiones ftp) y otras herramientas clientes y para
125 administración. Cuando squid se inicia, dispara un número configurable
126 de procesos dnsserver, cada uno pudiendo ejecutar solamente una
127 resolución DNS con poder de bloquear. Esto reduce el tiempo que el
128 caché espera por resoluciones DNS. Fue derivado del proyecto Harvest,
129 financiado por la ARPA.
130
131 %description -l pl.UTF-8
132 Squid jest wysoce wydajnym serwerem proxy-cache dla przeglądarek WWW,
133 klientów FTP i gopher. Squid przechowuje najczęściej pobierane dane w
134 pamięci RAM i zapamiętuje odwołania do DNS. Squid oferuje wsparcie dla
135 SSL, rozbudowaną kontrolę dostępu oraz pełne rejestrowanie pobieranych
136 danych. Dzięki użyciu protokołu ICP (Internet Cache Protocol), serwer
137 squid można łączyć w hierarchię, zwiększając ich efektywność. Pakiet
138 squid obejmuje: główny program serwera squid, program dostarczający
139 informacji z DNS dnsserver, program odbierający dane FTP ftpget, oraz
140 pomocnicze programy do zarządzania. Squid wywodzi się ze
141 sponsorowanego przez ARPA projektu Harvest.
142
143 %description -l pt_BR.UTF-8
144 O Squid é um servidor proxy com cache de alta performance para
145 clientes web, suportando FTP, gopher e HTTP. Diferentemente de
146 softwares tradicionais de cache o squid manipula todas as requisições
147 em um único processo sem bloqueios, direcionado a E/S.
148
149 Mantém meta dados e objetos freqüentemente pedidos num cache em
150 memória RAM. Faz cache de resoluções DNS, suporta resoluções DNS sem
151 bloqueio e implementa um cache negativo de requisições que falharem.
152 Se você tem pouca memória dê uma olhada na versão NOVM deste pacote.
153
154 Também suporta SSL, controles extensivos de acesso e registro (log)
155 completo das requisições. Usando o leve Protocolo de Caches Internet
156 (ICP) ele pode ser usado em uma hierarquia de servidores para maior
157 economia de banda de comunicação.
158
159 Ele consiste do programa squid (servidor principal), do programa
160 dnsserver (para resolução DNS), do programa ftpget (para transmissões
161 ftp) e outras ferramentas clientes e para gerenciamento. Quando o
162 squid é inicializado ele dispara um número configurável de processos
163 dnsserver, cada um podendo executar somente uma resolução DNS
164 bloqueante. Isto reduz o tempo que o cache espera por resoluções DNS.
165
166 Foi derivado do projeto Harvest, financiado pela ARPA.
167
168 %description -l ru.UTF-8
169 Squid - это высокопроизводительный кэширующий прокси-сервер для
170 клиентов web, поддерживающий объекты данных типа FTP, gopher и HTTP. В
171 отличие от традиционных кэширующих программ, Squid обрабатывает все
172 запросы при помощи одного неблокирующегося, управляемого
173 вводом-выводом процесса.
174
175 Этот пакет имеет встроенную поддержку базы данных сетевых ICMP-проб
176 (Netdb).
177
178 %description -l uk.UTF-8
179 Squid - це кешуючий проксі-сервер для web-клієнтів, що підтримує
180 об'єкти даних типу FTP, gopher та HTTP. На відміну від традиційних
181 кешуючих програм, Squid обробляє всі запити за допомогою одного
182 неблокуючого, керованого вводом-виводом процесу.
183
184 Цей пакет має вбудовану підтримку бази даних мережевих ICMP-проб
185 (Netdb).
186
187 %package cachemgr
188 Summary:        CGI script for Squid management
189 Summary(pl.UTF-8):      Skrypt CGI do zarządzania Squidem przez WWW
190 Group:          Networking/Admin
191 Requires:       %{name} = %{epoch}:%{version}-%{release}
192 Requires:       webserver
193
194 %description cachemgr
195 Cachemgr.cgi is a CGI script that allows administrator to chceck
196 various informations about Squid via WWW.
197
198 %description cachemgr -l pl.UTF-8
199 Cachemgr.cgi jest skryptem CGI, który pozwala administratorowi
200 zapoznać się z informacjami o pracy Squida poprzez WWW.
201
202 %package ldap_auth
203 Summary:        LDAP authentication helper for Squid
204 Summary(pl.UTF-8):      Obsługa uwierzytelniania LDAP dla squida
205 Group:          Networking/Admin
206 Requires:       %{name} = %{epoch}:%{version}-%{release}
207
208 %description ldap_auth
209 This Squid helper allows authentication against LDAP directories using
210 the "simple authentication" (plain-text).
211
212 %description ldap_auth -l pl.UTF-8
213 Pakiet ten pozwala na uwierzytelnianie przez LDAP za pomocą prostego
214 uwierzytelniania (otwartym tekstem).
215
216 %package pam_auth
217 Summary:        PAM authentication helper for Squid
218 Summary(pl.UTF-8):      Obsługa uwierzytelniania PAM dla squida
219 Group:          Networking/Admin
220 Requires:       %{name} = %{epoch}:%{version}-%{release}
221 Requires:       pam >= 0.77.3
222
223 %description pam_auth
224 This program authenticates users against a PAM configured
225 authentication service "squid". This allows you to authenticate Squid
226 users to any authentication source for which you have a PAM module.
227
228 %description pam_auth -l pl.UTF-8
229 Program ten pozwala na uwierzytelnianie użytkowników squida w dowolnym
230 źródle posiadającym moduł PAM.
231
232 %package smb_auth
233 Summary:        SMB authentication helper for Squid
234 Summary(pl.UTF-8):      Obsługa uwierzytelniania SMB dla squida
235 Group:          Networking/Admin
236 Requires:       %{name} = %{epoch}:%{version}-%{release}
237
238 %description smb_auth
239 This is a proxy authentication module. With smb_auth you can
240 authenticate proxy users against an SMB server like Windows NT or
241 Samba.
242
243 %description smb_auth -l pl.UTF-8
244 To jest moduł uwierzytelniania proxy. Przy pomocy smb_auth można
245 uwierzytelniać użytkowników proxy na serwerach SMB, jak Windows NT czy
246 Samba.
247
248 %package msnt_auth
249 Summary:        MSNT domain authentication helper for Squid
250 Summary(pl.UTF-8):      Obsługa uwierzytelniania w domenie MSNT dla squida
251 Group:          Networking/Admin
252 Requires:       %{name} = %{epoch}:%{version}-%{release}
253
254 %description msnt_auth
255 This is an authentication module for the Squid proxy server to
256 authenticate users on an NT domain.
257
258 %description msnt_auth -l pl.UTF-8
259 Jest to moduł uwierzytelniania proxy, który pozwala na
260 uwierzytelnianie użytkowników proxy w domenie NT.
261
262 %package yp_auth
263 Summary:        YP authentication helper for Squid
264 Summary(pl.UTF-8):      Obsługa uwierzytelniania YP dla squida
265 Group:          Networking/Admin
266 Requires:       %{name} = %{epoch}:%{version}-%{release}
267
268 %description yp_auth
269 This is an authentication module for the Squid proxy server to
270 authenticate users on YP.
271
272 %description yp_auth -l pl.UTF-8
273 Jest to moduł uwierzytelniania proxy, który pozwala na
274 uwierzytelnianie użytkowników proxy poprzez YP.
275
276 %package ncsa_auth
277 Summary:        NCSA httpd style authentication helper for Squid
278 Summary(pl.UTF-8):      Obsługa uwierzytelniania NCSA httpd dla squida
279 Group:          Networking/Admin
280 Requires:       %{name} = %{epoch}:%{version}-%{release}
281
282 %description ncsa_auth
283 This module uses a NCSA httpd style password file for authentication.
284
285 %description ncsa_auth -l pl.UTF-8
286 Moduł uwierzytelniania proxy używający pliku haseł jak w NCSA httpd.
287
288 %package sasl_auth
289 Summary:        SASL authentication helper for Squid
290 Summary(pl.UTF-8):      Obsługa uwierzytelniania SASL dla squida
291 Group:          Networking/Admin
292 Requires:       %{name} = %{epoch}:%{version}-%{release}
293
294 %description sasl_auth
295 This is an authentication module for the Squid proxy server to
296 authenticate users via SASL.
297
298 %description sasl_auth -l pl.UTF-8
299 Jest to moduł uwierzytelniania proxy, który pozwala na
300 uwierzytelnianie użytkowników proxy poprzez SASL.
301
302 %package getpwname_auth
303 Summary:        getpwname authentication helper for Squid
304 Summary(pl.UTF-8):      Obsługa uwierzytelniania getpwname dla squida
305 Group:          Networking/Admin
306 Requires:       %{name} = %{epoch}:%{version}-%{release}
307
308 %description getpwname_auth
309 This is an authentication module for the Squid proxy server to
310 authenticate users using getpwname.
311
312 %description getpwname_auth -l pl.UTF-8
313 Jest to moduł uwierzytelniania proxy, który pozwala na
314 uwierzytelnianie użytkowników proxy poprzez getpwname.
315
316 %package passwd_auth
317 Summary:        passwd authentication helper for Squid
318 Summary(pl.UTF-8):      Obsługa uwierzytelniania passwd dla squida
319 Group:          Networking/Admin
320 Requires:       %{name} = %{epoch}:%{version}-%{release}
321
322 %description passwd_auth
323 This is an authentication module for the Squid proxy server to
324 authenticate users with separate passwd file.
325
326 %description passwd_auth -l pl.UTF-8
327 Jest to moduł uwierzytelniania proxy, który pozwala na
328 uwierzytelnianie użytkowników proxy poprzez oddzielny plik passwd.
329
330 %package ntlm_auth
331 Summary:        NTLM authentication helper for Squid
332 Summary(pl.UTF-8):      Obsługa uwierzytelniania NTLM dla squida
333 Group:          Networking/Admin
334 Requires:       %{name} = %{epoch}:%{version}-%{release}
335
336 %description ntlm_auth
337 This is an authentication module for the Squid proxy server to
338 authenticate users on NTLM.
339
340 %description ntlm_auth -l pl.UTF-8
341 Jest to moduł uwierzytelniania proxy, który pozwala na
342 uwierzytelnianie użytkowników proxy poprzez NTLM.
343
344 %package digest_ldap_auth
345 Summary:        LDAP authentication helper for Squid
346 Summary(pl.UTF-8):      Obsługa uwierzytelniania LDAP dla squida
347 Group:          Networking/Admin
348 Requires:       %{name} = %{epoch}:%{version}-%{release}
349
350 %description digest_ldap_auth
351 This is an authentication module for the Squid proxy server to
352 authenticate users on LDAP.
353
354 %description digest_ldap_auth -l pl.UTF-8
355 Jest to moduł uwierzytelniania proxy, który pozwala na
356 uwierzytelnianie użytkowników proxy poprzez LDAP.
357
358 %package ip_acl
359 Summary:        IP external ACL helper for Squid
360 Summary(pl.UTF-8):      Wsparcie kontroli dostępu przez IP dla squida
361 Group:          Networking/Admin
362 Requires:       %{name} = %{epoch}:%{version}-%{release}
363
364 %description ip_acl
365 This is an external ACL module for the Squid proxy server to limit
366 access for users based on IP address.
367
368 %description ip_acl -l pl.UTF-8
369 Jest to moduł kontroli dostępu (ACL) do proxy, który pozwala na
370 ograniczenie dostępu użytkowników proxy na podstawie ich adresu IP.
371
372 %package ldap_acl
373 Summary:        LDAP group external ACL helper for Squid
374 Summary(pl.UTF-8):      Wsparcie kontroli dostępu przez grupy LDAP dla squida
375 Group:          Networking/Admin
376 Requires:       %{name} = %{epoch}:%{version}-%{release}
377
378 %description ldap_acl
379 This is an external ACL module for the Squid proxy server to limit
380 access for users based on LDAP group membership.
381
382 %description ldap_acl -l pl.UTF-8
383 Jest to moduł kontroli dostępu (ACL) do proxy, który pozwala na
384 ograniczenie dostępu użytkowników proxy na podstawie ich
385 przynależności do grup LDAP.
386
387 %package unix_acl
388 Summary:        UNIX group external ACL helper for Squid
389 Summary(pl.UTF-8):      Wsparcie kontroli dostępu przez grupy UNIX dla squida
390 Group:          Networking/Admin
391 Requires:       %{name} = %{epoch}:%{version}-%{release}
392
393 %description unix_acl
394 This is an external ACL module for the Squid proxy server to limit
395 access for users based on UNIX group membership.
396
397 %description unix_acl -l pl.UTF-8
398 Jest to moduł kontroli dostępu (ACL) do proxy, który pozwala na
399 ograniczenie dostępu użytkowników proxy na podstawie ich
400 przynależności do grup UNIX.
401
402 %package wbinfo_acl
403 Summary:        NT domain group external ACL helper for Squid
404 Summary(pl.UTF-8):      Wsparcie kontroli dostępu przez grupy w domenie NT dla squida
405 Group:          Networking/Admin
406 Requires:       %{name} = %{epoch}:%{version}-%{release}
407
408 %description wbinfo_acl
409 This is an external ACL module for the Squid proxy server to limit
410 access for users based on NT domain group membership using wbinfo.
411
412 %description wbinfo_acl -l pl.UTF-8
413 Jest to moduł kontroli dostępu (ACL) do proxy, który pozwala na
414 ograniczenie dostępu użytkowników proxy na podstawie ich
415 przynależności do grup w domenie NT przy użyciu wbinfo.
416
417 %package session_acl
418 Summary:        Squid session tracking external acl group helper
419 Group:          Networking/Admin
420 Requires:       %{name} = %{epoch}:%{version}-%{release}
421
422 %description session_acl
423 This helper maintains a concept of sessions by monitoring requests and
424 timing out sessions if no requests have been seen for the idle timeout
425 timer.
426
427 %package scripts
428 Summary:        Perl scripts for Squid
429 Summary(pl.UTF-8):      Skrypty perlowe dla Squida
430 Group:          Networking/Admin
431 Requires:       %{name} = %{epoch}:%{version}-%{release}
432
433 %description scripts
434 This package contains Perl scripts and contributed programs for Squid.
435
436 %description scripts -l pl.UTF-8
437 Ten pakiet zawiera skrypty perlowe i dodatkowe programy dla Squida.
438
439 %prep
440 %setup -q -a1 -a4
441 # Bug fixes from Squid home page:
442
443 # Other patches:
444 %patch0 -p1
445 %patch1 -p1
446 %patch2 -p1
447 %patch4 -p1
448 %patch5 -p1
449 #%patch6 -p1
450 #%patch7 -p1
451 %{?with_combined_log:%patch8 -p1}
452 %patch9 -p1
453 %ifarch ppc
454 %patch10 -p1
455 %endif
456
457 %{__sed} -i -e '1s#!.*bin/perl#!%{__perl}#' {contrib,scripts,helpers/*/*}/*.pl
458
459 %build
460 %{__libtoolize}
461 %{__aclocal}
462 %{__autoconf}
463 %{__autoheader}
464 %{__automake}
465 %configure \
466         --datadir=%{_datadir}/squid \
467         --enable-arp-acl \
468         --enable-auth="basic,digest,negotiate,ntlm" \
469         --enable-basic-auth-helpers="LDAP,MSNT,NCSA,PAM,SASL,SMB,YP,getpwnam,multi-domain-NTLM" \
470         --enable-cache-digests \
471         --enable-coss-aio-ops \
472         --enable-delay-pools \
473         --enable-digest-auth-helpers="ldap,password" \
474         --enable-err-language=English \
475         --enable-esi \
476         --enable-external-acl-helpers="ip_user,ldap_group,session,unix_group,wbinfo_group" \
477         --enable-follow-x-forwarded-for \
478         --enable-forward-log \
479         --enable-forw-via-db \
480         --enable-htcp \
481         --enable-icap-client \
482         --enable-icmp \
483         --enable-kill-parent-hack \
484         --enable-large-cache-files \
485         --enable-linux-netfilter \
486         --enable-linux-tproxy \
487         --enable-multicast-miss \
488         --enable-ntlm-auth-helpers="SMB,fakeauth,no_check" \
489         --enable-ntlm-fail-open \
490         --enable-referer-log \
491         --enable-removal-policies="heap,lru" \
492         --enable-snmp \
493         --enable-ssl \
494         --enable-storeio="aufs,diskd,null,ufs" \
495         --enable-useragent-log \
496         --enable-x-accelerator-vary \
497         --localstatedir=/var \
498         --sysconfdir=%{_sysconfdir} \
499         --with-auth-on-acceleration \
500         --with-large-files \
501         --with-maxfd=32768 \
502         --with-pthreads \
503         --enable-zph-qos
504
505 %{__make}
506
507 %install
508 rm -rf $RPM_BUILD_ROOT
509 install -d $RPM_BUILD_ROOT%{_cgidir} \
510         $RPM_BUILD_ROOT/etc/{pam.d,rc.d/init.d,security,sysconfig,logrotate.d} \
511         $RPM_BUILD_ROOT{%{_sbindir},%{_bindir},%{_libexecdir}/contrib} \
512         $RPM_BUILD_ROOT%{_mandir}/man8 \
513         $RPM_BUILD_ROOT%{_datadir}/squid \
514         $RPM_BUILD_ROOT/var/{cache,log{,/archive}}/squid
515
516 %{__make} install \
517         DESTDIR=$RPM_BUILD_ROOT
518
519 cp -a contrib/*.pl $RPM_BUILD_ROOT%{_libexecdir}/contrib
520 install scripts/*.pl $RPM_BUILD_ROOT%{_libexecdir}
521
522 install %{SOURCE7} $RPM_BUILD_ROOT/etc/pam.d/squid
523 touch $RPM_BUILD_ROOT/etc/security/blacklist.squid
524
525 mv -f $RPM_BUILD_ROOT%{_libdir}/squid/cachemgr.cgi $RPM_BUILD_ROOT%{_cgidir}
526
527 cd $RPM_BUILD_ROOT/etc/squid
528 cp -f squid.conf{,.default}
529 %{__patch} -p0 < %{SOURCE5}
530 rm -f *~ *.orig
531 cd -
532
533 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/squid
534 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/squid
535 install %{SOURCE6} $RPM_BUILD_ROOT/etc/logrotate.d/squid
536
537 touch $RPM_BUILD_ROOT/var/log/squid/{access,cache,store}.log
538
539 # These two files start squid. They are replaced by /etc/rc.d/init.d script.
540 rm -f $RPM_BUILD_ROOT%{_bindir}/R*
541
542 # cp, to have re-entrant install
543 rm -rf docs
544 cp -a doc docs
545 # dunno why, but manual is not installed
546 mv docs/squid.8 $RPM_BUILD_ROOT%{_mandir}/man8
547 # We don't want Makefiles as docs...
548 rm -f docs/Makefile*
549
550 # We don't like message: rpm found unpackaged files ...
551 rm -f $RPM_BUILD_ROOT/etc/squid/msntauth.conf.default \
552         $RPM_BUILD_ROOT/etc/squid/squid.conf.orig
553
554 > $RPM_BUILD_ROOT/var/cache/squid/netdb_state
555 > $RPM_BUILD_ROOT/var/cache/squid/swap.state
556 > $RPM_BUILD_ROOT/var/cache/squid/swap.state.clean
557 > $RPM_BUILD_ROOT/var/cache/squid/swap.state.last-clean
558
559 %clean
560 rm -rf $RPM_BUILD_ROOT
561
562 %pre
563 %groupadd -g 91 squid
564 %useradd -o -u 91 -s /bin/false -g squid -c "SQUID http caching daemon" -d /var/cache/squid squid
565 %addusertogroup stats squid
566
567 [ -L %{_datadir}/squid/errors ] && rm -f %{_datadir}/squid/errors || :
568
569 %post
570 if ! grep -q "^visible_hostname" /etc/squid/squid.conf; then
571         hostname=`/bin/hostname -f 2>/dev/null` || hostname='localhost'
572         echo visible_hostname $hostname >> /etc/squid/squid.conf
573 fi
574
575 /sbin/chkconfig --add squid
576 if [ "$1" = "1" ]; then
577         /sbin/service squid init >&2
578 fi
579 %service squid restart
580
581 %preun
582 if [ "$1" = "0" ]; then
583         /sbin/chkconfig --del squid
584         %service squid stop
585
586         # nuke squid cache if uninstalling
587         rm -rf /var/cache/squid/??
588 fi
589
590 %postun
591 if [ "$1" = "0" ]; then
592         %userremove squid
593         %groupremove squid
594 fi
595
596 %triggerpostun -- squid < 7:2.5.STABLE7-5
597 %addusertogroup stats squid
598
599 %files
600 %defattr(644,root,root,755)
601 %doc CONTRIBUTORS COPYRIGHT CREDITS README ChangeLog QUICKSTART RELEASENOTES.html SPONSORS
602 %doc docs/* src/mib.txt FAQ*.html book-full.html
603 %attr(755,root,root) %{_bindir}/squidclient
604 %attr(755,root,root) %{_libexecdir}/diskd
605 # YES, it has to be suid root, it sends ICMP packets.
606 %attr(4754,root,squid) %{_libexecdir}/pinger
607 %attr(755,root,root) %{_libexecdir}/unlinkd
608 %attr(755,root,root) %{_libexecdir}/fakeauth_auth
609 %attr(755,root,root) %{_sbindir}/*
610
611 %dir %{_sysconfdir}
612
613 %attr(754,root,root) /etc/rc.d/init.d/squid
614 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/squid
615 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/squid
616 %attr(640,root,squid) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/squid.conf
617 %attr(640,root,squid) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/mime.conf
618 %attr(640,root,root) %{_sysconfdir}/mime.conf.default
619 %attr(640,root,root) %{_sysconfdir}/squid.conf.default
620
621 %dir %{_datadir}/squid
622 %dir %{_datadir}/squid/errors
623 %{_datadir}/squid/icons
624 %{_datadir}/squid/mib.txt
625 %lang(am) %{_datadir}/squid/errors/Armenian
626 %lang(az) %{_datadir}/squid/errors/Azerbaijani
627 %lang(bg) %{_datadir}/squid/errors/Bulgarian
628 %lang(ca) %{_datadir}/squid/errors/Catalan
629 %lang(cs) %{_datadir}/squid/errors/Czech
630 %lang(da) %{_datadir}/squid/errors/Danish
631 %lang(nl) %{_datadir}/squid/errors/Dutch
632 %{_datadir}/squid/errors/English
633 %lang(et) %{_datadir}/squid/errors/Estonian
634 %lang(fi) %{_datadir}/squid/errors/Finnish
635 %lang(fr) %{_datadir}/squid/errors/French
636 %lang(de) %{_datadir}/squid/errors/German
637 %lang(el) %{_datadir}/squid/errors/Greek
638 %lang(he) %{_datadir}/squid/errors/Hebrew
639 %lang(hu) %{_datadir}/squid/errors/Hungarian
640 %lang(it) %{_datadir}/squid/errors/Italian
641 %lang(ja) %{_datadir}/squid/errors/Japanese
642 %lang(ko) %{_datadir}/squid/errors/Korean
643 %lang(lt) %{_datadir}/squid/errors/Lithuanian
644 %lang(pl) %{_datadir}/squid/errors/Polish
645 %lang(pt) %{_datadir}/squid/errors/Portuguese
646 %lang(ro) %{_datadir}/squid/errors/Romanian
647 %lang(ru) %{_datadir}/squid/errors/Russian-1251
648 %lang(ru) %{_datadir}/squid/errors/Russian-koi8-r
649 %lang(zh_CN) %{_datadir}/squid/errors/Simplify_Chinese
650 %lang(sk) %{_datadir}/squid/errors/Slovak
651 %lang(es) %{_datadir}/squid/errors/Spanish
652 %lang(sr) %{_datadir}/squid/errors/Serbian
653 %lang(sv) %{_datadir}/squid/errors/Swedish
654 %lang(zh_TW) %{_datadir}/squid/errors/Traditional_Chinese
655 %lang(tr) %{_datadir}/squid/errors/Turkish
656 %lang(uk) %{_datadir}/squid/errors/Ukrainian*
657 %dir %{_libexecdir}
658
659 %attr(770,root,squid) %dir /var/log/archive/squid
660 %attr(770,root,squid) %dir /var/log/squid
661 %attr(660,root,squid) %ghost /var/log/squid/*
662
663 %attr(770,root,squid) %dir /var/cache/squid
664 %ghost /var/cache/squid/netdb_state
665 %ghost /var/cache/squid/swap.state
666 %ghost /var/cache/squid/swap.state.clean
667 %ghost /var/cache/squid/swap.state.last-clean
668 %{_mandir}/man8/squid.8*
669
670 %files cachemgr
671 %defattr(644,root,root,755)
672 %attr(640,root,squid) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/cachemgr.conf
673 %attr(755,root,root) %{_cgidir}/*
674 %{_mandir}/man8/cachemgr.cgi.8*
675
676 %files ldap_auth
677 %defattr(644,root,root,755)
678 %doc helpers/basic_auth/LDAP/README
679 %attr(755,root,root) %{_libexecdir}/%{name}_ldap_auth
680 %{_mandir}/man8/%{name}_ldap_auth.*
681
682 %files pam_auth
683 %defattr(644,root,root,755)
684 %doc helpers/basic_auth/PAM/pam_auth.c
685 %config(noreplace) /etc/pam.d/squid
686 %config(noreplace) /etc/security/blacklist.squid
687 %attr(755,root,root) %{_libexecdir}/pam_auth
688 %{_mandir}/man8/pam_auth.8*
689
690 %files smb_auth
691 %defattr(644,root,root,755)
692 %doc helpers/basic_auth/SMB/{README,ChangeLog,smb_auth.sh}
693 %doc helpers/basic_auth/multi-domain-NTLM/*
694 %attr(755,root,root) %{_libexecdir}/smb_auth*
695
696 %files msnt_auth
697 %defattr(644,root,root,755)
698 %doc helpers/basic_auth/MSNT/README*
699 %attr(755,root,root) %{_libexecdir}/msnt_auth
700 %attr(640,root,squid) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/msntauth.conf
701
702 %files yp_auth
703 %defattr(644,root,root,755)
704 %attr(755,root,root) %{_libexecdir}/yp_auth
705
706 %files ncsa_auth
707 %defattr(644,root,root,755)
708 %attr(755,root,root) %{_libexecdir}/ncsa_auth
709 %{_mandir}/man8/ncsa_auth.8*
710
711 %files sasl_auth
712 %defattr(644,root,root,755)
713 %doc helpers/basic_auth/SASL/{README,squid_sasl*}
714 %attr(755,root,root) %{_libexecdir}/sasl_auth
715
716 %files getpwname_auth
717 %defattr(644,root,root,755)
718 %attr(755,root,root) %{_libexecdir}/getpwname_auth
719
720 %files passwd_auth
721 %defattr(644,root,root,755)
722 %attr(755,root,root) %{_libexecdir}/digest_pw_auth
723
724 %files ntlm_auth
725 %defattr(644,root,root,755)
726 %doc helpers/ntlm_auth/no_check/{README*,no_check.pl}
727 %attr(755,root,root) %{_libexecdir}/ntlm_auth
728
729 %files digest_ldap_auth
730 %defattr(644,root,root,755)
731 %attr(755,root,root) %{_libexecdir}/digest_ldap_auth
732
733 %files ip_acl
734 %defattr(644,root,root,755)
735 %doc helpers/external_acl/ip_user/{README,example*}
736 %attr(755,root,root) %{_libexecdir}/ip_user_check
737
738 %files ldap_acl
739 %defattr(644,root,root,755)
740 %attr(755,root,root) %{_libexecdir}/squid_ldap_group
741 %{_mandir}/man8/%{name}_ldap_group.*
742
743 %files unix_acl
744 %defattr(644,root,root,755)
745 %doc helpers/external_acl/unix_group/README
746 %attr(755,root,root) %{_libexecdir}/squid_unix_group
747 %{_mandir}/man8/%{name}_unix_group.*
748
749 %files wbinfo_acl
750 %defattr(644,root,root,755)
751 %attr(755,root,root) %{_libexecdir}/wbinfo_group.pl
752
753 %files session_acl
754 %defattr(644,root,root,755)
755 %attr(755,root,root) %{_libexecdir}/squid_session
756 %{_mandir}/man8/%{name}_session.8*
757
758 %files scripts
759 %defattr(644,root,root,755)
760 %attr(755,root,root) %{_libexecdir}/*.pl
761 %attr(755,root,root) %{_libexecdir}/contrib
This page took 0.112739 seconds and 4 git commands to generate.