]>
Commit | Line | Data |
---|---|---|
6139e54a ER |
1 | # TODO: |
2 | # - build/install java ext ? | |
3 | # - perl BRs | |
daf27ba0 | 4 | # - remove obsolete /etc/cups/certs (trigger?) |
7be5c8e8 JB |
5 | # |
6 | # Conditional build: | |
373aff1e | 7 | %bcond_with gnutls # use GNU TLS for SSL/TLS support (instead of OpenSSL) |
ceddaf82 | 8 | %bcond_without dnssd |
373aff1e KK |
9 | %bcond_without php # don't build PHP extension |
10 | %bcond_without perl # don't build Perl extension | |
ceddaf82 AM |
11 | %bcond_without java |
12 | %bcond_without python | |
373aff1e | 13 | %bcond_without static_libs # don't build static library |
7be5c8e8 | 14 | # |
7be5c8e8 | 15 | %include /usr/lib/rpm/macros.perl |
ef5fe709 | 16 | %define pdir CUPS |
fb328468 | 17 | Summary: Common Unix Printing System |
fb3b4f59 ER |
18 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa |
19 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão | |
346112e3 | 20 | Name: cups |
ceddaf82 AM |
21 | Version: 1.3.0 |
22 | Release: 1 | |
e73da052 | 23 | Epoch: 1 |
346112e3 | 24 | License: GPL/LGPL |
0366ccc3 | 25 | Group: Applications/Printing |
ceddaf82 AM |
26 | Source0: http://dl.sourceforge.net/cups/%{name}-%{version}-source.tar.bz2 |
27 | # Source0-md5: ae2855d5d1ab5b5fcbb8a2613cefec14 | |
168e60c2 | 28 | Source1: %{name}.init |
fd7e4ff1 | 29 | Source2: %{name}.pamd |
fd4436b5 | 30 | Source3: %{name}.logrotate |
60e0cb5a | 31 | Source4: %{name}.mailto.conf |
25dfe94f JB |
32 | Patch0: %{name}-config.patch |
33 | Patch1: %{name}-lp-lpr.patch | |
34 | Patch2: %{name}-options.patch | |
73a0798d | 35 | Patch3: %{name}-man_pages_linking.patch |
f75e41c7 | 36 | Patch4: %{name}-nostrip.patch |
428f33ff KK |
37 | Patch5: %{name}-templates.patch |
38 | Patch6: %{name}-certs_FHS.patch | |
ceddaf82 | 39 | Patch7: %{name}-direct_usb.patch |
fb328468 | 40 | URL: http://www.cups.org/ |
daf27ba0 | 41 | BuildRequires: acl-devel |
e73da052 | 42 | BuildRequires: autoconf |
43 | BuildRequires: automake | |
ceddaf82 | 44 | %{?with_dnssd:BuildRequires: avahi-compat-libdns_sd-devel} |
e809c01b | 45 | BuildRequires: dbus-devel |
ceddaf82 | 46 | BuildRequires: glibc-headers |
373aff1e | 47 | %{?with_gnutls:BuildRequires: gnutls-devel} |
ceddaf82 | 48 | BuildRequires: krb5-devel |
aa509eeb | 49 | BuildRequires: libjpeg-devel |
30d7d426 | 50 | BuildRequires: libpng-devel |
21ee9950 | 51 | BuildRequires: libstdc++-devel |
30d7d426 | 52 | BuildRequires: libtiff-devel |
dc0f13b3 | 53 | BuildRequires: openldap-devel |
c7103aaa | 54 | BuildRequires: openslp-devel |
373aff1e | 55 | %{!?with_gnutls:BuildRequires: openssl-devel} |
8bdc526e | 56 | BuildRequires: pam-devel |
752c3387 | 57 | %{?with_php:BuildRequires: php-devel >= 4:5.0.0} |
3219126a | 58 | BuildRequires: pkgconfig |
559b7094 | 59 | BuildRequires: rpm-perlprov |
4fc96bcd | 60 | BuildRequires: rpmbuild(macros) >= 1.344 |
9e9d05b7 | 61 | Requires(post,preun): /sbin/chkconfig |
39956f63 | 62 | Requires: %{name}-libs = %{epoch}:%{version}-%{release} |
6bd9c7f7 | 63 | Requires: pam >= 0.77.3 |
a73a2669 | 64 | Requires: rc-scripts |
09af927c PZ |
65 | Obsoletes: printingdaemon |
66 | Provides: printingdaemon | |
a73a2669 | 67 | Conflicts: ghostscript < 7.05.4 |
bc4f9e5b | 68 | Conflicts: logrotate < 3.7.4 |
91331aef | 69 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
346112e3 | 70 | |
82f3f074 JK |
71 | %define _ulibdir %{_prefix}/lib |
72 | ||
fb328468 | 73 | %description |
dd843423 | 74 | CUPS provides a portable printing layer for UNIX-based operating |
8bff8fce MP |
75 | systems. It has been developed by Easy Software Products to promote a |
76 | standard printing solution for all UNIX vendors and users. CUPS | |
77 | provides the System V and Berkeley command-line interfaces. CUPS uses | |
78 | the Internet Printing Protocol ("IPP") as the basis for managing print | |
79 | jobs and queues. The Line Printer Daemon ("LPD") Server Message Block | |
80 | ("SMB"), and AppSocket (a.k.a. JetDirect) protocols are also supported | |
81 | with reduced functionality. CUPS adds network printer browsing and | |
82 | PostScript Printer Description ("PPD") based printing options to | |
83 | support real-world printing under UNIX. | |
346112e3 | 84 | |
2f78071d JR |
85 | %description -l pl.UTF-8 |
86 | CUPS dostarcza standardowy poziom drukowania dla systemów uniksowych. | |
87 | CUPS używa protokołu IPP - Internet Printint Protocol jako podstawy do | |
88 | zarządzania zadaniami i kolejkami druku. W ograniczonym zakresie | |
89 | obsługiwane są także protokoły LPD (Line Printer Daemon), SMB (Server | |
90 | Message Block) i AppSocket (znany także jako JetDirect). CUPS | |
91 | udostępnia przeglądanie drukarek sieciowych i opcje drukowania oparte | |
92 | na PPD (PostScript Printer Description) do obsługi rzeczywistych | |
bc9f5ffe | 93 | drukarek. |
30d7d426 | 94 | |
2f78071d JR |
95 | %description -l pt_BR.UTF-8 |
96 | O sistema Unix de impressão (CUPS) fornece uma camada de impressão | |
97 | portável para os sistemas operacionais baseados no UNIX®. | |
4644dd52 | 98 | |
6ebf74dd | 99 | %package lib |
fd7e4ff1 | 100 | Summary: Common Unix Printing System Libraries |
fb3b4f59 ER |
101 | Summary(pl.UTF-8): Biblioteki dla CUPS |
102 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - bibliotecas para uso em clientes cups | |
52835768 | 103 | Group: Libraries |
6ebf74dd | 104 | Provides: %{name}-libs = %{epoch}:%{version}-%{release} |
a73a2669 | 105 | Obsoletes: cups-libs |
bf6c7747 | 106 | Obsoletes: libcups1 |
fd7e4ff1 | 107 | |
6ebf74dd | 108 | %description lib |
9625f17f JB |
109 | Common Unix Printing System Libraries. |
110 | ||
2f78071d | 111 | %description lib -l pl.UTF-8 |
9625f17f | 112 | Biblioteki dla CUPS. |
fd7e4ff1 | 113 | |
2f78071d | 114 | %description lib -l pt_BR.UTF-8 |
6ebf74dd AF |
115 | Bibliotecas CUPS requeridas pelos clientes CUPS. |
116 | ||
2da56f05 SZ |
117 | %package clients |
118 | Summary: Common Unix Printing System Clients | |
fb3b4f59 | 119 | Summary(pl.UTF-8): Aplikacje klienckie dla CUPS |
2da56f05 | 120 | Group: Applications/Printing |
e055e440 | 121 | Requires: %{name}-libs = %{epoch}:%{version}-%{release} |
09af927c PZ |
122 | Obsoletes: printingclient |
123 | Provides: printingclient | |
2da56f05 SZ |
124 | |
125 | %description clients | |
126 | Common Unix Printing System Clients. | |
127 | ||
2f78071d | 128 | %description clients -l pl.UTF-8 |
2da56f05 SZ |
129 | Aplikacje klienckie dla CUPS. |
130 | ||
6ebf74dd AF |
131 | %package image-lib |
132 | Summary: Common Unix Printing System Libraries - images manipulation | |
fb3b4f59 ER |
133 | Summary(pl.UTF-8): Biblioteki dla CUPS - obsługa formatów graficznych |
134 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - bibliotecas para uso em clientes cups | |
52835768 | 135 | Group: Libraries |
039c735c | 136 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
6ebf74dd AF |
137 | Obsoletes: libcups1 |
138 | ||
139 | %description image-lib | |
257636d7 | 140 | Common Unix Printing System Libraries - images manipalation. |
6ebf74dd | 141 | |
2f78071d JR |
142 | %description image-lib -l pl.UTF-8 |
143 | Biblioteki dla CUPS - obsługa formatów graficznych. | |
6ebf74dd | 144 | |
2f78071d | 145 | %description image-lib -l pt_BR.UTF-8 |
4644dd52 | 146 | Bibliotecas CUPS requeridas pelos clientes CUPS. |
147 | ||
980a97fe | 148 | %package devel |
149 | Summary: Common Unix Printing System development files | |
fb3b4f59 ER |
150 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa - pliki nagłówkowe |
151 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - ambiente de desenvolvimento | |
980a97fe | 152 | Group: Development/Libraries |
cd99fdf9 JB |
153 | Requires: %{name}-image-lib = %{epoch}:%{version}-%{release} |
154 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} | |
950cc25f KK |
155 | %{?with_gnutls:Requires: gnutls-devel} |
156 | %{!?with_gnutls:Requires: openssl-devel} | |
717a8d25 | 157 | Requires: zlib-devel |
bf6c7747 | 158 | Obsoletes: libcups1-devel |
980a97fe | 159 | |
160 | %description devel | |
9625f17f | 161 | Common Unix Printing System development files. |
980a97fe | 162 | |
2f78071d JR |
163 | %description devel -l pl.UTF-8 |
164 | Ogólny system druku dla Uniksa - pliki nagłówkowe. | |
8bdc526e | 165 | |
2f78071d JR |
166 | %description devel -l pt_BR.UTF-8 |
167 | Este pacote é um adicional que contem um ambiente de desenvolvimento | |
168 | para a criação de suporte a novas impressoras e novos serviços ao | |
4644dd52 | 169 | CUPS. |
170 | ||
980a97fe | 171 | %package static |
172 | Summary: Common Unix Printing System static libraries | |
fb3b4f59 ER |
173 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa - biblioteki statyczne |
174 | Summary(pt_BR.UTF-8): Common Unix Printing System - bibliotecas estáticas | |
980a97fe | 175 | Group: Development/Libraries |
cd99fdf9 | 176 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
980a97fe | 177 | |
178 | %description static | |
8bdc526e | 179 | Common Unix Printing System static libraries. |
980a97fe | 180 | |
2f78071d JR |
181 | %description static -l pl.UTF-8 |
182 | Ogólny system druku dla Uniksa - biblioteki statyczne. | |
8bdc526e | 183 | |
2f78071d JR |
184 | %description static -l pt_BR.UTF-8 |
185 | Bibliotecas estáticas para desenvolvimento de programas que usam as | |
4644dd52 | 186 | bibliotecas do CUPS. |
187 | ||
2e2308c6 | 188 | %package -n perl-cups |
7be5c8e8 | 189 | Summary: Perl module for CUPS |
fb3b4f59 | 190 | Summary(pl.UTF-8): Moduł Perla CUPS |
7be5c8e8 | 191 | Group: Development/Languages/Perl |
cd99fdf9 | 192 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
2e2308c6 AF |
193 | |
194 | %description -n perl-cups | |
7be5c8e8 JB |
195 | Perl module for Common Unix Printing System. |
196 | ||
2f78071d JR |
197 | %description -n perl-cups -l pl.UTF-8 |
198 | Moduł Perla do ogólnego systemu druku dla Uniksa. | |
2e2308c6 AF |
199 | |
200 | %package -n php-cups | |
201 | Summary: PHP module for CUPS | |
fb3b4f59 | 202 | Summary(pl.UTF-8): Moduł PHP CUPS |
7be5c8e8 | 203 | Group: Development/Languages/PHP |
cd99fdf9 | 204 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
ed486845 | 205 | %{?requires_php_extension} |
786665a9 | 206 | Requires: /etc/php/conf.d |
752c3387 | 207 | Requires: php-common >= 4:5.0.0 |
2e2308c6 AF |
208 | |
209 | %description -n php-cups | |
210 | PHP module for Common Unix Printing System. | |
211 | ||
2f78071d JR |
212 | %description -n php-cups -l pl.UTF-8 |
213 | Moduł PHP do ogólnego systemu druku dla Uniksa. | |
7be5c8e8 | 214 | |
25aeafb8 | 215 | %package backend-usb |
0f8ac12d | 216 | Summary: USB backend for CUPS |
fb3b4f59 | 217 | Summary(pl.UTF-8): Backend USB dla CUPS-a |
0f8ac12d | 218 | Group: Applications/Printing |
cd99fdf9 | 219 | Requires: %{name} = %{epoch}:%{version}-%{release} |
0f8ac12d AF |
220 | |
221 | %description backend-usb | |
222 | This package allow CUPS printing on USB printers. | |
223 | ||
2f78071d JR |
224 | %description backend-usb -l pl.UTF-8 |
225 | Ten pakiet umożliwia drukowanie z poziomu CUPS-a na drukarkach USB. | |
71ac0ea6 | 226 | |
25aeafb8 | 227 | %package backend-serial |
71ac0ea6 | 228 | Summary: Serial port backend for CUPS |
fb3b4f59 | 229 | Summary(pl.UTF-8): Backend obsługujący porty szeregowe dla CUPS-a |
0f8ac12d | 230 | Group: Applications/Printing |
cd99fdf9 | 231 | Requires: %{name} = %{epoch}:%{version}-%{release} |
0f8ac12d AF |
232 | |
233 | %description backend-serial | |
71ac0ea6 JB |
234 | This package allow CUPS printing on printers connected by serial |
235 | ports. | |
236 | ||
2f78071d JR |
237 | %description backend-serial -l pl.UTF-8 |
238 | Ten pakiet umożliwia drukowanie z poziomu CUPS-a na drukarkach | |
239 | podłączonych do portów szeregowych. | |
0f8ac12d | 240 | |
25aeafb8 | 241 | %package backend-parallel |
71ac0ea6 | 242 | Summary: Parallel port backend for CUPS |
fb3b4f59 | 243 | Summary(pl.UTF-8): Backend obsługujący porty równoległe dla CUPS-a |
0f8ac12d | 244 | Group: Applications/Printing |
cd99fdf9 | 245 | Requires: %{name} = %{epoch}:%{version}-%{release} |
0f8ac12d AF |
246 | |
247 | %description backend-parallel | |
71ac0ea6 JB |
248 | This package allow CUPS printing on printers connected by parallel |
249 | ports. | |
250 | ||
2f78071d JR |
251 | %description backend-parallel -l pl.UTF-8 |
252 | Ten pakiet umożliwia drukowanie z poziomu CUPS-a na drukarkach | |
253 | podłączonych do portów równoległych. | |
0f8ac12d | 254 | |
346112e3 | 255 | %prep |
735a5048 | 256 | %setup -q |
73a0798d | 257 | %patch0 -p1 |
8bdc526e | 258 | %patch1 -p1 |
25dfe94f | 259 | %patch2 -p1 |
73a0798d | 260 | %patch3 -p1 |
f75e41c7 | 261 | %patch4 -p1 |
653cdc22 | 262 | %patch5 -p1 |
428f33ff | 263 | %patch6 -p1 |
ceddaf82 | 264 | %patch7 -p1 |
8bdc526e | 265 | |
346112e3 | 266 | %build |
daf27ba0 | 267 | %{__aclocal} -I config-scripts |
0b9d4622 | 268 | %{__autoconf} |
c6f4ebff | 269 | %configure \ |
82f3f074 | 270 | --libdir=%{_ulibdir} \ |
8d2025a2 | 271 | --enable-shared \ |
ceddaf82 AM |
272 | --with-cups-user=lp \ |
273 | --with-cups-group=sys \ | |
274 | --with-system-groups=sys \ | |
275 | --with-printcap=/etc/printcap \ | |
373aff1e | 276 | %{?with_static_libs:--enable-static} \ |
faa66800 | 277 | --enable-ssl \ |
373aff1e KK |
278 | --%{?with_gnutls:dis}%{!?with_gnutls:en}able-openssl \ |
279 | --%{!?with_gnutls:dis}%{?with_gnutls:en}able-gnutls \ | |
ceddaf82 | 280 | --%{!?with_dnssd:dis}%{?with_dnssd:en}able-dnssd \ |
faa66800 | 281 | --disable-cdsassl \ |
e809c01b | 282 | --enable-dbus \ |
d110f6af | 283 | %{?debug:--enable-debug} \ |
373aff1e | 284 | --with-docdir=%{_ulibdir}/%{name}/cgi-bin \ |
ceddaf82 AM |
285 | --with-config-file-perm=0640 \ |
286 | --with-log-file-perm=0640 \ | |
287 | %{?with_dnssd:--with-dnssd-libs=x} \ | |
288 | %{?with_dnssd:--with-dnssd-includes=x} \ | |
289 | %{?with_php:--with-php} \ | |
290 | %{?with_perl:--with-perl} \ | |
291 | %{?with_java:--with-java} \ | |
292 | %{?with_php:--with-python} | |
373aff1e | 293 | |
346112e3 | 294 | %{__make} |
7be5c8e8 | 295 | |
cad7b106 | 296 | %{__perl} -pi -e 's#-I\.\.\/\.\.#-I../.. -I../../cups#g' scripting/php/Makefile |
e809c01b | 297 | %{?with_php:%{__make} -C scripting/php PHPCONFIG=%{_bindir}/php-config} |
7be5c8e8 | 298 | |
f07e6182 | 299 | %if %{with perl} |
2e2308c6 | 300 | cd scripting/perl |
7be5c8e8 JB |
301 | %{__perl} -pi -e 's@-lcups@-L../../cups $1@' Makefile.PL |
302 | %{__perl} Makefile.PL \ | |
303 | INSTALLDIRS=vendor \ | |
304 | OPTIMIZE="%{rpmcflags} -I../.." | |
305 | # avoid rpaths generated by MakeMaker | |
cad7b106 | 306 | %{__perl} -pi -e 's@LD_RUN_PATH="\$\(LD_RUN_PATH\)" @@' Makefile |
7be5c8e8 JB |
307 | |
308 | %{__make} | |
2e2308c6 AF |
309 | cd ../.. |
310 | %endif | |
346112e3 | 311 | |
312 | %install | |
313 | rm -rf $RPM_BUILD_ROOT | |
a73a2669 | 314 | install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,pam.d,logrotate.d,security} \ |
428f33ff | 315 | $RPM_BUILD_ROOT/var/run/cups \ |
38f5ddf3 | 316 | $RPM_BUILD_ROOT/var/log/{,archive/}cups |
fd7e4ff1 | 317 | |
6133c494 | 318 | %{__make} install \ |
e827011a AM |
319 | BUILDROOT=$RPM_BUILD_ROOT \ |
320 | CUPS_USER=$(id -u) \ | |
321 | CUPS_GROUP=$(id -g) | |
fd7e4ff1 | 322 | |
82f3f074 JK |
323 | if [ "%{_lib}" != "lib" ] ; then |
324 | install -d $RPM_BUILD_ROOT%{_libdir} | |
325 | mv $RPM_BUILD_ROOT%{_ulibdir}/*.so* $RPM_BUILD_ROOT%{_libdir} | |
e3bfc8b9 | 326 | mv $RPM_BUILD_ROOT%{_ulibdir}/*.a $RPM_BUILD_ROOT%{_libdir} |
82f3f074 JK |
327 | fi |
328 | ||
f07e6182 | 329 | %if %{with php} |
2e2308c6 | 330 | %{__make} -C scripting/php install \ |
4fc96bcd ER |
331 | PHPDIR=$RPM_BUILD_ROOT%{php_extensiondir} |
332 | install -d $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d | |
333 | cat > $RPM_BUILD_ROOT%{php_sysconfdir}/conf.d/phpcups.ini << EOF | |
e809c01b | 334 | ; Enable phpcups extension module |
752c3387 ER |
335 | extension=phpcups.so |
336 | EOF | |
2e2308c6 AF |
337 | %endif |
338 | ||
f07e6182 | 339 | %if %{with perl} |
653cdc22 | 340 | %{__make} -C scripting/perl install \ |
6133c494 | 341 | DESTDIR=$RPM_BUILD_ROOT |
2e2308c6 AF |
342 | %endif |
343 | ||
cad7b106 | 344 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
345 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/%{name} | |
346 | install %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name} | |
60e0cb5a | 347 | install %{SOURCE4} $RPM_BUILD_ROOT/etc/cups/mailto.conf |
45a67ab9 | 348 | |
de296a9f | 349 | gzip -9nf $RPM_BUILD_ROOT%{_datadir}/%{name}/model/*.ppd |
30d7d426 | 350 | |
4d897458 | 351 | touch $RPM_BUILD_ROOT/var/log/cups/{access_log,error_log,page_log} |
cad7b106 | 352 | touch $RPM_BUILD_ROOT/etc/security/blacklist.cups |
8d2025a2 | 353 | touch $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/{classes,printers,client}.conf |
679be76f | 354 | |
ef5fe709 ER |
355 | # windows drivers can be put there. |
356 | install -d $RPM_BUILD_ROOT%{_datadir}/cups/drivers | |
357 | ||
748a0bf9 ER |
358 | # dirs for gimp-print-cups-4.2.7-1 |
359 | install -d $RPM_BUILD_ROOT%{_datadir}/cups/model/{C,da,en_GB,fr,nb,pl,sv} | |
360 | ||
daf27ba0 | 361 | touch $RPM_BUILD_ROOT/var/cache/cups/help.index |
6139e54a | 362 | touch $RPM_BUILD_ROOT/var/cache/cups/{job,remote}.cache |
68e5a032 | 363 | touch $RPM_BUILD_ROOT/var/cache/cups/ppds.dat |
748a0bf9 | 364 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/cups/ssl |
ef5fe709 | 365 | |
eea94f34 | 366 | # links to enable/disable (compatibility!) |
748a0bf9 ER |
367 | ln -s accept $RPM_BUILD_ROOT%{_sbindir}/enable |
368 | ln -s accept $RPM_BUILD_ROOT%{_sbindir}/disable | |
eea94f34 | 369 | |
2e2308c6 | 370 | # check-files cleanup |
0ce3cd57 | 371 | rm -rf $RPM_BUILD_ROOT%{_mandir}/{,es/,fr/}cat? |
748a0bf9 | 372 | rm -rf $RPM_BUILD_ROOT/''etc/{init.d,rc?.d}/* |
54906e64 | 373 | rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/cupsd.conf.default |
679be76f | 374 | |
9625f17f JB |
375 | %clean |
376 | rm -rf $RPM_BUILD_ROOT | |
377 | ||
168e60c2 | 378 | %post |
8a24ec7f | 379 | /sbin/chkconfig --add cups |
a73a2669 | 380 | %service cups restart "cups daemon" |
fb328468 | 381 | |
168e60c2 | 382 | %preun |
fd7e4ff1 | 383 | if [ "$1" = "0" ]; then |
a73a2669 | 384 | %service cups stop |
fd7e4ff1 | 385 | /sbin/chkconfig --del cups |
386 | fi | |
168e60c2 | 387 | |
19e8d1ed | 388 | %post lib -p /sbin/ldconfig |
389 | %postun lib -p /sbin/ldconfig | |
390 | %post image-lib -p /sbin/ldconfig | |
391 | %postun image-lib -p /sbin/ldconfig | |
8bdc526e | 392 | |
752c3387 | 393 | %post -n php-cups |
572f9a81 | 394 | %php_webserver_restart |
752c3387 ER |
395 | |
396 | %postun -n php-cups | |
397 | if [ "$1" = 0 ]; then | |
572f9a81 | 398 | %php_webserver_restart |
752c3387 ER |
399 | fi |
400 | ||
fd7e4ff1 | 401 | %files |
346112e3 | 402 | %defattr(644,root,root,755) |
05d8dec5 | 403 | #%doc *.gz doc/*.html doc/*.css doc/images |
4c209b1f | 404 | %doc *.txt |
39956f63 | 405 | %attr(640,root,root) %config %verify(not md5 mtime size) /etc/pam.d/* |
8bdc526e | 406 | %attr(754,root,root) /etc/rc.d/init.d/cups |
e809c01b | 407 | /etc/dbus-1/system.d/cups.conf |
6139e54a | 408 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/classes.conf |
39956f63 | 409 | %attr(640,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/cupsd.conf |
daf27ba0 | 410 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/printers.conf |
60e0cb5a | 411 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/mailto.conf |
39956f63 ER |
412 | %attr(640,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.convs |
413 | %attr(640,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.types | |
cd29fb20 | 414 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.cups |
4017839a | 415 | %dir %attr(700,root,lp) %{_sysconfdir}/%{name}/ssl |
934a05d8 | 416 | %dir %{_sysconfdir}/%{name}/interfaces |
6139e54a | 417 | %dir %attr(755,root,lp) %{_sysconfdir}/%{name}/ppd |
39956f63 | 418 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name} |
fd7e4ff1 | 419 | %attr(4755,lp,root) %{_bindir}/lppasswd |
3ddab923 | 420 | %attr(755,root,root) %{_bindir}/cupstestppd |
e809c01b | 421 | %attr(755,root,root) %{_bindir}/cupstestdsc |
ceddaf82 | 422 | %attr(755,root,root) %{_sbindir}/cupsctl |
daf27ba0 | 423 | %attr(755,root,root) %{_sbindir}/cupsd |
ceddaf82 | 424 | %attr(755,root,root) %{_sbindir}/cupsfilter |
daf27ba0 | 425 | |
82f3f074 JK |
426 | %dir %{_ulibdir}/cups |
427 | %dir %{_ulibdir}/cups/* | |
daf27ba0 KK |
428 | %{_ulibdir}/cups/cgi-bin/help |
429 | %{_ulibdir}/cups/cgi-bin/images | |
430 | %attr(755,root,root) %{_ulibdir}/cups/cgi-bin/*.cgi | |
431 | %{_ulibdir}/cups/cgi-bin/*.css | |
432 | %{_ulibdir}/cups/cgi-bin/*.html | |
433 | %{_ulibdir}/cups/cgi-bin/*.ico | |
434 | %{_ulibdir}/cups/cgi-bin/*.txt | |
21212dc8 | 435 | %lang(de) %{_ulibdir}/cups/cgi-bin/de |
daf27ba0 | 436 | %lang(es) %{_ulibdir}/cups/cgi-bin/es |
ce6b0d52 | 437 | %lang(et) %{_ulibdir}/cups/cgi-bin/et |
6692ed4f | 438 | %lang(fr) %{_ulibdir}/cups/cgi-bin/fr |
ceddaf82 | 439 | %lang(he) %{_ulibdir}/cups/cgi-bin/he |
03e64605 | 440 | %lang(it) %{_ulibdir}/cups/cgi-bin/it |
daf27ba0 KK |
441 | %lang(ja) %{_ulibdir}/cups/cgi-bin/ja |
442 | %lang(pl) %{_ulibdir}/cups/cgi-bin/pl | |
443 | %lang(sv) %{_ulibdir}/cups/cgi-bin/sv | |
2717f059 | 444 | %lang(zh_TW) %{_ulibdir}/cups/cgi-bin/zh_TW |
daf27ba0 | 445 | |
82f3f074 JK |
446 | %exclude %{_ulibdir}/cups/backend/usb |
447 | %exclude %{_ulibdir}/cups/backend/serial | |
448 | %exclude %{_ulibdir}/cups/backend/parallel | |
daf27ba0 KK |
449 | %attr(755,root,root) %{_ulibdir}/cups/backend/* |
450 | %attr(755,root,root) %{_ulibdir}/cups/daemon/* | |
451 | %attr(755,root,root) %{_ulibdir}/cups/filter/* | |
452 | %attr(755,root,root) %{_ulibdir}/cups/monitor/* | |
453 | %attr(755,root,root) %{_ulibdir}/cups/notifier/* | |
454 | ||
54906e64 ER |
455 | %dir %{_datadir}/cups |
456 | %{_datadir}/cups/banners | |
457 | %{_datadir}/cups/charmaps | |
458 | %{_datadir}/cups/charsets | |
459 | %{_datadir}/cups/data | |
6139e54a | 460 | %{_datadir}/cups/drivers |
54906e64 | 461 | %{_datadir}/cups/fonts |
748a0bf9 ER |
462 | %dir %{_datadir}/cups/model |
463 | %{_datadir}/cups/model/*.ppd.gz | |
464 | # dirs for gimp-print-cups-4.2.7-1 | |
465 | %dir %{_datadir}/cups/model/C | |
466 | %lang(da) %dir %{_datadir}/cups/model/da | |
467 | %lang(en_GB) %dir %{_datadir}/cups/model/en_GB | |
468 | %lang(fr) %dir %{_datadir}/cups/model/fr | |
469 | %lang(nb) %dir %{_datadir}/cups/model/nb | |
470 | %lang(pl) %dir %{_datadir}/cups/model/pl | |
471 | %lang(sv) %dir %{_datadir}/cups/model/sv | |
472 | ||
54906e64 ER |
473 | %dir %{_datadir}/cups/templates |
474 | %{_datadir}/cups/templates/*.tmpl | |
21212dc8 | 475 | %lang(de) %{_datadir}/cups/templates/de |
54906e64 | 476 | %lang(es) %{_datadir}/cups/templates/es |
ce6b0d52 | 477 | %lang(et) %{_datadir}/cups/templates/et |
6692ed4f | 478 | %lang(fr) %{_datadir}/cups/templates/fr |
ceddaf82 | 479 | %lang(he) %{_datadir}/cups/templates/he |
03e64605 | 480 | %lang(it) %{_datadir}/cups/templates/it |
54906e64 ER |
481 | %lang(ja) %{_datadir}/cups/templates/ja |
482 | %lang(pl) %{_datadir}/cups/templates/pl | |
483 | %lang(sv) %{_datadir}/cups/templates/sv | |
2717f059 | 484 | %lang(zh_TW) %{_datadir}/cups/templates/zh_TW |
e809c01b | 485 | %{_mandir}/man7/backend.7* |
c1555e94 | 486 | %{_mandir}/man1/cupstestppd.1* |
e809c01b AM |
487 | %{_mandir}/man1/cupstestdsc.1* |
488 | %{_mandir}/man7/filter.7* | |
0366ccc3 | 489 | %{_mandir}/man1/lppasswd.1* |
2bb4485b | 490 | %{_mandir}/man[58]/* |
ceddaf82 | 491 | %lang(da) %{_datadir}/locale/da/cups_da.po |
217f5641 | 492 | %lang(de) %{_datadir}/locale/de/cups_de.po |
e809c01b | 493 | %lang(es) %{_datadir}/locale/es/cups_es.po |
ce6b0d52 | 494 | %lang(et) %{_datadir}/locale/et/cups_et.po |
ceddaf82 | 495 | %lang(fi) %{_datadir}/locale/fi/cups_fi.po |
6692ed4f | 496 | %lang(fr) %{_datadir}/locale/fr/cups_fr.po |
ceddaf82 | 497 | %lang(he) %{_datadir}/locale/he/cups_he.po |
03e64605 | 498 | %lang(it) %{_datadir}/locale/it/cups_it.po |
ceddaf82 | 499 | %lang(ko) %{_datadir}/locale/ko/cups_ko.po |
e809c01b | 500 | %lang(ja) %{_datadir}/locale/ja/cups_ja.po |
ceddaf82 | 501 | %lang(nl) %{_datadir}/locale/nl/cups_nl.po |
af3419b3 | 502 | #%lang(no) %{_datadir}/locale/no/cups_no.po |
cc4221f2 | 503 | %lang(pl) %{_datadir}/locale/pl/cups_pl.po |
ceddaf82 AM |
504 | %lang(pt) %{_datadir}/locale/pt/cups_pt.po |
505 | %lang(pt_BR) %{_datadir}/locale/pt_BR/cups_pt_BR.po | |
af3419b3 | 506 | #%lang(pt_PT) %{_datadir}/locale/pt_PT/cups_pt_PT.po |
ceddaf82 | 507 | %lang(ru) %{_datadir}/locale/ru/cups_ru.po |
e809c01b | 508 | %lang(sv) %{_datadir}/locale/sv/cups_sv.po |
af3419b3 | 509 | #%lang(zh) %{_datadir}/locale/zh/cups_zh.po |
2717f059 | 510 | %lang(zh_TW) %{_datadir}/locale/zh_TW/cups_zh_TW.po |
daf27ba0 KK |
511 | |
512 | %dir %attr(775,root,lp) /var/cache/cups | |
428f33ff KK |
513 | %dir %attr(755,root,lp) /var/lib/cups |
514 | %dir %attr(511,lp,sys) /var/lib/cups/certs | |
6139e54a | 515 | %dir %attr(755,root,lp) /var/run/cups |
daf27ba0 KK |
516 | %dir %attr(710,root,lp) /var/spool/cups |
517 | %dir %attr(1770,root,lp) /var/spool/cups/tmp | |
68e5a032 | 518 | %attr(600,lp,lp) %ghost /var/cache/cups/help.index |
6139e54a | 519 | %attr(640,root,lp) %ghost /var/cache/cups/job.cache |
68e5a032 | 520 | %attr(600,lp,lp) %ghost /var/cache/cups/ppds.dat |
6139e54a | 521 | %attr(640,root,lp) %ghost /var/cache/cups/remote.cache |
081a50cb | 522 | %attr(750,root,logs) %dir /var/log/archive/cups |
40183055 JK |
523 | %attr(750,root,logs) %dir /var/log/cups |
524 | %attr(640,root,logs) %ghost /var/log/cups/access_log | |
525 | %attr(640,root,logs) %ghost /var/log/cups/error_log | |
526 | %attr(640,root,logs) %ghost /var/log/cups/page_log | |
980a97fe | 527 | |
6ebf74dd AF |
528 | %files lib |
529 | %defattr(644,root,root,755) | |
3c247a25 | 530 | %dir %attr(755,root,lp) %{_sysconfdir}/%{name} |
6ebf74dd AF |
531 | %attr(755,root,root) %{_libdir}/libcups.so.* |
532 | ||
2da56f05 SZ |
533 | %files clients |
534 | %defattr(644,root,root,755) | |
8d2025a2 | 535 | %attr(644,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/client.conf |
2da56f05 | 536 | %attr(755,root,root) %{_bindir}/cancel |
2da56f05 SZ |
537 | %attr(755,root,root) %{_bindir}/lp |
538 | %attr(755,root,root) %{_bindir}/lpoptions | |
539 | %attr(755,root,root) %{_bindir}/lpq | |
540 | %attr(755,root,root) %{_bindir}/lpr | |
541 | %attr(755,root,root) %{_bindir}/lprm | |
542 | %attr(755,root,root) %{_bindir}/lpstat | |
501ef07e AM |
543 | %attr(755,root,root) %{_sbindir}/accept |
544 | %attr(755,root,root) %{_sbindir}/cupsaddsmb | |
eea94f34 | 545 | %attr(755,root,root) %{_sbindir}/cupsenable |
546 | %attr(755,root,root) %{_sbindir}/cupsdisable | |
547 | %attr(755,root,root) %{_sbindir}/disable | |
548 | %attr(755,root,root) %{_sbindir}/enable | |
501ef07e AM |
549 | %attr(755,root,root) %{_sbindir}/lpadmin |
550 | %attr(755,root,root) %{_sbindir}/lpc | |
551 | %attr(755,root,root) %{_sbindir}/lpinfo | |
552 | %attr(755,root,root) %{_sbindir}/lpmove | |
553 | %attr(755,root,root) %{_sbindir}/reject | |
93040bdf | 554 | %{_mandir}/man1/cancel.1* |
0366ccc3 AF |
555 | %{_mandir}/man1/lp.1* |
556 | %{_mandir}/man1/lpoptions.1* | |
557 | %{_mandir}/man1/lpq.1* | |
558 | %{_mandir}/man1/lpr.1* | |
559 | %{_mandir}/man1/lprm.1* | |
560 | %{_mandir}/man1/lpstat.1* | |
e809c01b AM |
561 | #%lang(fr) %{_mandir}/fr/man1/cancel.1* |
562 | #%lang(fr) %{_mandir}/fr/man1/lp.1* | |
563 | #%lang(fr) %{_mandir}/fr/man1/lpoptions.1* | |
564 | #%lang(fr) %{_mandir}/fr/man1/lpq.1* | |
565 | #%lang(fr) %{_mandir}/fr/man1/lpr.1* | |
566 | #%lang(fr) %{_mandir}/fr/man1/lprm.1* | |
567 | #%lang(fr) %{_mandir}/fr/man1/lpstat.1* | |
568 | #%lang(es) %{_mandir}/es/man1/lp.1* | |
569 | #%lang(es) %{_mandir}/es/man1/lpoptions.1* | |
570 | #%lang(es) %{_mandir}/es/man1/lpq.1* | |
571 | #%lang(es) %{_mandir}/es/man1/lpr.1* | |
572 | #%lang(es) %{_mandir}/es/man1/lprm.1* | |
573 | #%lang(es) %{_mandir}/es/man1/lpstat.1* | |
2da56f05 | 574 | |
6ebf74dd | 575 | %files image-lib |
fd7e4ff1 | 576 | %defattr(644,root,root,755) |
6ebf74dd | 577 | %attr(755,root,root) %{_libdir}/libcupsimage.so.* |
fd7e4ff1 | 578 | |
980a97fe | 579 | %files devel |
580 | %defattr(644,root,root,755) | |
6e2c2519 | 581 | %attr(755,root,root) %{_bindir}/cups-config |
980a97fe | 582 | %{_includedir}/cups |
fd7e4ff1 | 583 | %{_libdir}/lib*.so |
835fcb44 | 584 | %{_mandir}/man1/cups-config* |
6ebf74dd | 585 | %{_mandir}/man3/* |
e809c01b AM |
586 | #%lang(fr) %{_mandir}/fr/man1/cups-config* |
587 | #%lang(es) %{_mandir}/es/man1/cups-config* | |
980a97fe | 588 | |
373aff1e | 589 | %if %{with static_libs} |
8d2025a2 AM |
590 | %files static |
591 | %defattr(644,root,root,755) | |
592 | %{_libdir}/*.a | |
373aff1e | 593 | %endif |
2e2308c6 | 594 | |
f07e6182 | 595 | %if %{with perl} |
2e2308c6 AF |
596 | %files -n perl-cups |
597 | %defattr(644,root,root,755) | |
598 | %{perl_vendorarch}/*.pm | |
599 | %dir %{perl_vendorarch}/auto/CUPS | |
600 | %{perl_vendorarch}/auto/CUPS/*.bs | |
601 | %{perl_vendorarch}/auto/CUPS/autosplit.ix | |
602 | %attr(755,root,root) %{perl_vendorarch}/auto/CUPS/*.so | |
83bc4a43 | 603 | %endif |
2e2308c6 | 604 | |
f07e6182 | 605 | %if %{with php} |
2e2308c6 AF |
606 | %files -n php-cups |
607 | %defattr(644,root,root,755) | |
44b3e11b | 608 | %doc scripting/php/README |
4fc96bcd ER |
609 | %attr(755,root,root) %{php_extensiondir}/* |
610 | %config(noreplace) %verify(not md5 mtime size) %{php_sysconfdir}/conf.d/phpcups.ini | |
83bc4a43 | 611 | %endif |
0f8ac12d AF |
612 | |
613 | %files backend-usb | |
614 | %defattr(644,root,root,755) | |
82f3f074 | 615 | %attr(755,root,root) %{_ulibdir}/cups/backend/usb |
0f8ac12d AF |
616 | |
617 | %files backend-serial | |
618 | %defattr(644,root,root,755) | |
82f3f074 | 619 | %attr(755,root,root) %{_ulibdir}/cups/backend/serial |
0f8ac12d AF |
620 | |
621 | %files backend-parallel | |
622 | %defattr(644,root,root,755) | |
82f3f074 | 623 | %attr(755,root,root) %{_ulibdir}/cups/backend/parallel |