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