]>
Commit | Line | Data |
---|---|---|
3540b403 | 1 | # |
7be5c8e8 | 2 | # Conditional build: |
8196abcc | 3 | %bcond_without gnutls # use GNU TLS for SSL/TLS support |
a329855b | 4 | %bcond_with dnssd # DNS Service Discovery support via dns_sd API (obsoleted by Avahi patch) |
cdbbf080 | 5 | %bcond_without avahi # DNS Service Discovery support via Avahi |
9781b66d JB |
6 | %bcond_without gssapi # GSSAPI support |
7 | %bcond_with lspp # audit and SELinux label support (lspp patch) | |
8 | %bcond_with tcp_wrappers # tcp_wrappers/libwrap support | |
9781b66d | 9 | %bcond_without static_libs # static library |
10718067 | 10 | %bcond_without systemd # systemd |
70ba6cfc | 11 | |
fb3b4f59 ER |
12 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa |
13 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão | |
346112e3 | 14 | Name: cups |
fab640ee | 15 | Version: 2.4.8 |
f9e74891 | 16 | Release: 1 |
e73da052 | 17 | Epoch: 1 |
8196abcc | 18 | License: LGPL v2 (libraries), GPL v2 (the rest) |
0366ccc3 | 19 | Group: Applications/Printing |
fab640ee JR |
20 | Source0: https://github.com/OpenPrinting/cups/releases/download/v%{version}/cups-%{version}-source.tar.gz |
21 | # Source0-md5: 3fdd9a5249f090cd35e324246ef0e3e4 | |
168e60c2 | 22 | Source1: %{name}.init |
fd7e4ff1 | 23 | Source2: %{name}.pamd |
fd4436b5 | 24 | Source3: %{name}.logrotate |
60e0cb5a | 25 | Source4: %{name}.mailto.conf |
84d9a886 | 26 | Source5: %{name}-lpd.inetd |
19a74fff | 27 | Source6: %{name}-modprobe.conf |
33a3fa2f | 28 | Source7: %{name}.tmpfiles |
25dfe94f | 29 | Patch0: %{name}-config.patch |
25dfe94f | 30 | Patch2: %{name}-options.patch |
73a0798d | 31 | Patch3: %{name}-man_pages_linking.patch |
f75e41c7 | 32 | Patch4: %{name}-nostrip.patch |
efe7daa3 | 33 | Patch5: %{name}-certs_FHS.patch |
34 | Patch6: %{name}-direct_usb.patch | |
388c735f | 35 | Patch7: %{name}-no-polluted-krb5config.patch |
388c735f JR |
36 | Patch9: %{name}-verbose-compilation.patch |
37 | Patch10: %{name}-peercred.patch | |
2cd6a49c | 38 | Patch11: %{name}-usb.patch |
eea183cb | 39 | Patch12: %{name}-desktop.patch |
eac40fe0 KK |
40 | Patch15: reactivate_recommended_driver.patch |
41 | Patch16: read-embedded-options-from-incoming-postscript-and-add-to-ipp-attrs.patch | |
6df0c9a8 | 42 | Patch18: %{name}-final-content-type.patch |
b3b50933 AM |
43 | Patch102: cups-banners.patch |
44 | Patch103: cups-pid.patch | |
45 | Patch104: cups-eggcups.patch | |
46 | Patch105: cups-driverd-timeout.patch | |
b3b50933 AM |
47 | Patch107: cups-res_init.patch |
48 | Patch108: cups-filter-debug.patch | |
b3b50933 | 49 | Patch110: cups-dnssd-deviceid.patch |
a3be372f | 50 | |
b3b50933 AM |
51 | Patch113: cups-dymo-deviceid.patch |
52 | Patch114: cups-freebind.patch | |
53 | Patch115: cups-ipp-multifile.patch | |
54 | Patch116: cups-web-devices-timeout.patch | |
55 | Patch117: cups-lspp.patch | |
fab640ee | 56 | URL: https://openprinting.github.io/cups/ |
daf27ba0 | 57 | BuildRequires: acl-devel |
9781b66d | 58 | %{?with_lspp:BuildRequires: audit-libs-devel} |
a70a3fe3 | 59 | BuildRequires: autoconf >= 2.60 |
e73da052 | 60 | BuildRequires: automake |
9fc3c00d TP |
61 | %{?with_dnssd:BuildRequires: avahi-compat-libdns_sd-devel} |
62 | %{?with_avahi:BuildRequires: avahi-devel} | |
e809c01b | 63 | BuildRequires: dbus-devel |
ceddaf82 | 64 | BuildRequires: glibc-headers |
373aff1e | 65 | %{?with_gnutls:BuildRequires: gnutls-devel} |
cc8431ac | 66 | %{?with_gssapi:BuildRequires: heimdal-devel} |
d5391671 | 67 | BuildRequires: libpaper-devel |
9781b66d | 68 | %{?with_lspp:BuildRequires: libselinux-devel} |
21ee9950 | 69 | BuildRequires: libstdc++-devel |
9158c4a7 | 70 | BuildRequires: libusb-devel >= 1.0 |
9781b66d | 71 | %{?with_tcp_wrappers:BuildRequires: libwrap-devel} |
8bdc526e | 72 | BuildRequires: pam-devel |
3219126a | 73 | BuildRequires: pkgconfig |
cdbbf080 | 74 | BuildRequires: rpmbuild(macros) >= 1.641 |
10718067 | 75 | %{?with_systemd:BuildRequires: systemd-devel} |
a329855b | 76 | BuildRequires: zlib-devel |
9e9d05b7 | 77 | Requires(post,preun): /sbin/chkconfig |
b7adbbe1 | 78 | Requires(post,preun,postun): systemd-units >= 38 |
07168dc1 | 79 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
200bc650 | 80 | Requires: %{name}-ppdc = %{epoch}:%{version}-%{release} |
6bd9c7f7 | 81 | Requires: pam >= 0.77.3 |
a73a2669 | 82 | Requires: rc-scripts |
b7adbbe1 | 83 | Requires: systemd-units >= 38 |
cbfa6c41 | 84 | Suggests: ImageMagick-coder-pdf |
4a2b7af1 | 85 | Suggests: cups-filters |
60d4721a | 86 | Suggests: poppler-progs |
09af927c | 87 | Provides: printingdaemon |
1770fa4c | 88 | Obsoletes: printingdaemon |
a73a2669 | 89 | Conflicts: ghostscript < 7.05.4 |
96792ec6 | 90 | Conflicts: hplip < 3.13.11 |
9e79f779 | 91 | Conflicts: logrotate < 3.7-4 |
91331aef | 92 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
346112e3 | 93 | |
82f3f074 JK |
94 | %define _ulibdir %{_prefix}/lib |
95 | ||
fb328468 | 96 | %description |
dd843423 | 97 | CUPS provides a portable printing layer for UNIX-based operating |
8bff8fce MP |
98 | systems. It has been developed by Easy Software Products to promote a |
99 | standard printing solution for all UNIX vendors and users. CUPS | |
100 | provides the System V and Berkeley command-line interfaces. CUPS uses | |
101 | the Internet Printing Protocol ("IPP") as the basis for managing print | |
102 | jobs and queues. The Line Printer Daemon ("LPD") Server Message Block | |
103 | ("SMB"), and AppSocket (a.k.a. JetDirect) protocols are also supported | |
104 | with reduced functionality. CUPS adds network printer browsing and | |
105 | PostScript Printer Description ("PPD") based printing options to | |
106 | support real-world printing under UNIX. | |
346112e3 | 107 | |
2f78071d JR |
108 | %description -l pl.UTF-8 |
109 | CUPS dostarcza standardowy poziom drukowania dla systemów uniksowych. | |
110 | CUPS używa protokołu IPP - Internet Printint Protocol jako podstawy do | |
111 | zarządzania zadaniami i kolejkami druku. W ograniczonym zakresie | |
112 | obsługiwane są także protokoły LPD (Line Printer Daemon), SMB (Server | |
113 | Message Block) i AppSocket (znany także jako JetDirect). CUPS | |
114 | udostępnia przeglądanie drukarek sieciowych i opcje drukowania oparte | |
115 | na PPD (PostScript Printer Description) do obsługi rzeczywistych | |
bc9f5ffe | 116 | drukarek. |
30d7d426 | 117 | |
2f78071d JR |
118 | %description -l pt_BR.UTF-8 |
119 | O sistema Unix de impressão (CUPS) fornece uma camada de impressão | |
120 | portável para os sistemas operacionais baseados no UNIX®. | |
4644dd52 | 121 | |
200bc650 JB |
122 | %package backend-usb |
123 | Summary: USB backend for CUPS | |
124 | Summary(pl.UTF-8): Backend USB dla CUPS-a | |
125 | License: GPL v2 | |
126 | Group: Applications/Printing | |
127 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
fd7e4ff1 | 128 | |
200bc650 JB |
129 | %description backend-usb |
130 | This package allow CUPS printing on USB printers. | |
9625f17f | 131 | |
200bc650 JB |
132 | %description backend-usb -l pl.UTF-8 |
133 | Ten pakiet umożliwia drukowanie z poziomu CUPS-a na drukarkach USB. | |
fd7e4ff1 | 134 | |
200bc650 JB |
135 | %package lpd |
136 | Summary: LPD compatibility support for CUPS print server | |
137 | Summary(pl.UTF-8): Wsparcie dla LPD w serwerze wydruków CUPS | |
138 | License: GPL v2 | |
139 | Group: Applications/Printing | |
140 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
141 | Requires: rc-inetd | |
142 | ||
143 | %description lpd | |
144 | LPD compatibility support for CUPS print server. | |
145 | ||
146 | %description lpd -l pl.UTF-8 | |
147 | Wsparcie dla LPD w serwerze wydruków CUPS. | |
148 | ||
149 | %package ppdc | |
150 | Summary: Common Unix Printing System - PPD manipulation utilities | |
151 | Summary(pl.UTF-8): Narzędzia CUPS do operacji na plikach PPD | |
152 | License: GPL v2 | |
153 | Group: Applications/Printing | |
07168dc1 | 154 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
200bc650 JB |
155 | |
156 | %description ppdc | |
157 | This package provides utilities to generate and manipulate PPD files. | |
158 | ||
159 | %description ppdc -l pl.UTF-8 | |
160 | Ten pakiet zawiera narzędzia do generowania i operowania na plikach | |
161 | PPD. | |
6ebf74dd | 162 | |
2da56f05 SZ |
163 | %package clients |
164 | Summary: Common Unix Printing System Clients | |
fb3b4f59 | 165 | Summary(pl.UTF-8): Aplikacje klienckie dla CUPS |
8196abcc | 166 | License: GPL v2 |
2da56f05 | 167 | Group: Applications/Printing |
07168dc1 | 168 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
09af927c | 169 | Provides: printingclient |
1770fa4c | 170 | Obsoletes: printingclient |
2da56f05 SZ |
171 | |
172 | %description clients | |
173 | Common Unix Printing System Clients. | |
174 | ||
2f78071d | 175 | %description clients -l pl.UTF-8 |
2da56f05 SZ |
176 | Aplikacje klienckie dla CUPS. |
177 | ||
200bc650 JB |
178 | %package lib |
179 | Summary: Common Unix Printing System Libraries | |
180 | Summary(pl.UTF-8): Biblioteki dla CUPS | |
181 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - bibliotecas para uso em clientes cups | |
182 | License: LGPL v2 | |
183 | Group: Libraries | |
184 | Provides: %{name}-libs = %{epoch}:%{version}-%{release} | |
07168dc1 JB |
185 | Obsoletes: cups-libs < 1:1.1.14-2 |
186 | Obsoletes: libcups1 < 1:2 | |
200bc650 JB |
187 | |
188 | %description lib | |
189 | Common Unix Printing System Libraries. | |
190 | ||
191 | %description lib -l pl.UTF-8 | |
192 | Biblioteki dla CUPS. | |
193 | ||
194 | %description lib -l pt_BR.UTF-8 | |
195 | Bibliotecas CUPS requeridas pelos clientes CUPS. | |
196 | ||
6ebf74dd AF |
197 | %package image-lib |
198 | Summary: Common Unix Printing System Libraries - images manipulation | |
fb3b4f59 ER |
199 | Summary(pl.UTF-8): Biblioteki dla CUPS - obsługa formatów graficznych |
200 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - bibliotecas para uso em clientes cups | |
8196abcc | 201 | License: LGPL v2 |
52835768 | 202 | Group: Libraries |
039c735c | 203 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} |
07168dc1 | 204 | Obsoletes: libcups1 < 1:2 |
6ebf74dd AF |
205 | |
206 | %description image-lib | |
257636d7 | 207 | Common Unix Printing System Libraries - images manipalation. |
6ebf74dd | 208 | |
2f78071d JR |
209 | %description image-lib -l pl.UTF-8 |
210 | Biblioteki dla CUPS - obsługa formatów graficznych. | |
6ebf74dd | 211 | |
2f78071d | 212 | %description image-lib -l pt_BR.UTF-8 |
4644dd52 | 213 | Bibliotecas CUPS requeridas pelos clientes CUPS. |
214 | ||
980a97fe | 215 | %package devel |
216 | Summary: Common Unix Printing System development files | |
fb3b4f59 ER |
217 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa - pliki nagłówkowe |
218 | Summary(pt_BR.UTF-8): Sistema Unix de Impressão - ambiente de desenvolvimento | |
8196abcc | 219 | License: LGPL v2 |
980a97fe | 220 | Group: Development/Libraries |
cd99fdf9 JB |
221 | Requires: %{name}-image-lib = %{epoch}:%{version}-%{release} |
222 | Requires: %{name}-lib = %{epoch}:%{version}-%{release} | |
3e2caa76 | 223 | # for libcups |
c0eececa AM |
224 | %{?with_gnutls:Requires: gnutls-devel} |
225 | %{?with_gssapi:Requires: heimdal-devel} | |
717a8d25 | 226 | Requires: zlib-devel |
3e2caa76 JB |
227 | # for libcupsimage |
228 | Requires: libjpeg-devel | |
229 | Requires: libpng-devel | |
230 | Requires: libtiff-devel | |
07168dc1 | 231 | Obsoletes: libcups1-devel < 1:2 |
980a97fe | 232 | |
233 | %description devel | |
9625f17f | 234 | Common Unix Printing System development files. |
980a97fe | 235 | |
2f78071d JR |
236 | %description devel -l pl.UTF-8 |
237 | Ogólny system druku dla Uniksa - pliki nagłówkowe. | |
8bdc526e | 238 | |
2f78071d JR |
239 | %description devel -l pt_BR.UTF-8 |
240 | Este pacote é um adicional que contem um ambiente de desenvolvimento | |
241 | para a criação de suporte a novas impressoras e novos serviços ao | |
4644dd52 | 242 | CUPS. |
243 | ||
980a97fe | 244 | %package static |
245 | Summary: Common Unix Printing System static libraries | |
fb3b4f59 ER |
246 | Summary(pl.UTF-8): Ogólny system druku dla Uniksa - biblioteki statyczne |
247 | Summary(pt_BR.UTF-8): Common Unix Printing System - bibliotecas estáticas | |
8196abcc | 248 | License: LGPL v2 |
980a97fe | 249 | Group: Development/Libraries |
cd99fdf9 | 250 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
980a97fe | 251 | |
252 | %description static | |
8bdc526e | 253 | Common Unix Printing System static libraries. |
980a97fe | 254 | |
2f78071d JR |
255 | %description static -l pl.UTF-8 |
256 | Ogólny system druku dla Uniksa - biblioteki statyczne. | |
8bdc526e | 257 | |
2f78071d JR |
258 | %description static -l pt_BR.UTF-8 |
259 | Bibliotecas estáticas para desenvolvimento de programas que usam as | |
4644dd52 | 260 | bibliotecas do CUPS. |
261 | ||
346112e3 | 262 | %prep |
b3b50933 | 263 | %setup -q |
73a0798d | 264 | %patch0 -p1 |
25dfe94f | 265 | %patch2 -p1 |
73a0798d | 266 | %patch3 -p1 |
f75e41c7 | 267 | %patch4 -p1 |
653cdc22 | 268 | %patch5 -p1 |
d15c7d48 AM |
269 | # why it hasn't been merged for so long (and why no other distro uses it) |
270 | #%patch6 -p1 | |
388c735f | 271 | %patch7 -p1 |
84d9a886 | 272 | %patch9 -p1 |
948a3d9c | 273 | %patch10 -p1 |
d15c7d48 AM |
274 | # why it hasn't been merged for so long (and why no other distro uses it) |
275 | #%patch11 -p1 | |
eea183cb | 276 | %patch12 -p1 |
ba7599c9 AM |
277 | %patch15 -p1 |
278 | %patch16 -p1 | |
6df0c9a8 | 279 | %patch18 -p1 |
8bdc526e | 280 | |
b3b50933 AM |
281 | %patch102 -p1 |
282 | %patch103 -p1 | |
283 | %patch104 -p1 | |
284 | %patch105 -p1 | |
b3b50933 AM |
285 | %patch107 -p1 |
286 | %patch108 -p1 | |
b3b50933 | 287 | %patch110 -p1 |
a3be372f | 288 | |
b3b50933 AM |
289 | %patch113 -p1 |
290 | %patch114 -p1 | |
291 | %patch115 -p1 | |
292 | %patch116 -p1 | |
293 | %patch117 -p1 | |
294 | ||
346112e3 | 295 | %build |
daf27ba0 | 296 | %{__aclocal} -I config-scripts |
0b9d4622 | 297 | %{__autoconf} |
c6f4ebff | 298 | %configure \ |
a329855b JB |
299 | --enable-acl \ |
300 | --enable-avahi%{!?with_avahi:=no} \ | |
5aac26ac | 301 | --disable-cdsassl \ |
a329855b JB |
302 | --enable-dbus \ |
303 | %{?debug:--enable-debug} \ | |
304 | --enable-dnssd%{!?with_dnssd:=no} \ | |
305 | --enable-gnutls%{!?with_gnutls:=no} \ | |
306 | --enable-gssapi%{!?with_gssapi:=no} \ | |
d5391671 AM |
307 | --enable-libpaper \ |
308 | --enable-libusb \ | |
9781b66d | 309 | %{?with_lspp:--enable-lspp} \ |
8d2025a2 | 310 | --enable-shared \ |
5aac26ac | 311 | --enable-ssl \ |
5aac26ac | 312 | %{?with_static_libs:--enable-static} \ |
9781b66d | 313 | %{?with_tcp_wrappers:--enable-tcp-wrappers} \ |
32eff1a9 | 314 | --with-cups-group=lp \ |
a329855b | 315 | --with-cups-user=lp \ |
ceddaf82 | 316 | --with-system-groups=sys \ |
ceddaf82 AM |
317 | --with-config-file-perm=0640 \ |
318 | --with-log-file-perm=0640 \ | |
a329855b JB |
319 | --with-dbusdir=/etc/dbus-1 \ |
320 | --with-docdir=%{_ulibdir}/%{name}/cgi-bin \ | |
fab640ee | 321 | --with-pkgconfpath=%{_pkgconfigdir} \ |
a329855b | 322 | --with-printcap=/etc/printcap \ |
ceddaf82 AM |
323 | %{?with_dnssd:--with-dnssd-libs=x} \ |
324 | %{?with_dnssd:--with-dnssd-includes=x} \ | |
a329855b | 325 | --with-optim=-Wno-format-y2k \ |
10718067 MK |
326 | %{?with_systemd:--with-systemd=%{systemdunitdir}} \ |
327 | %{!?with_systemd:--disable-systemd} | |
373aff1e | 328 | |
03dce67c | 329 | %{__make} %{?debug:OPTIONS="-DDEBUG"} |
7be5c8e8 | 330 | |
346112e3 | 331 | %install |
332 | rm -rf $RPM_BUILD_ROOT | |
19a74fff | 333 | install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,pam.d,logrotate.d,modprobe.d,security,sysconfig/rc-inetd} \ |
428f33ff | 334 | $RPM_BUILD_ROOT/var/run/cups \ |
33a3fa2f | 335 | $RPM_BUILD_ROOT/var/log/{,archive/}cups \ |
cdbbf080 | 336 | $RPM_BUILD_ROOT{%{systemdunitdir},%{systemdtmpfilesdir}} |
fd7e4ff1 | 337 | |
6133c494 | 338 | %{__make} install \ |
e827011a AM |
339 | BUILDROOT=$RPM_BUILD_ROOT \ |
340 | CUPS_USER=$(id -u) \ | |
341 | CUPS_GROUP=$(id -g) | |
fd7e4ff1 | 342 | |
bf51f358 JR |
343 | %if %{with avahi} |
344 | ln -s %{_ulibdir}/cups/backend/dnssd $RPM_BUILD_ROOT%{_ulibdir}/cups/backend/mdns | |
345 | %endif | |
346 | ||
c0eececa | 347 | cp -p %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
0f88cfd9 | 348 | cp -pf %{SOURCE2} $RPM_BUILD_ROOT/etc/pam.d/%{name} |
c0eececa AM |
349 | cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/%{name} |
350 | cp -p %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/cups/mailto.conf | |
84d9a886 | 351 | sed -e 's|__ULIBDIR__|%{_ulibdir}|g' %{SOURCE5} > $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/cups-lpd |
c0eececa AM |
352 | cp -p %{SOURCE6} $RPM_BUILD_ROOT/etc/modprobe.d/cups.conf |
353 | cp -p %{SOURCE7} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf | |
45a67ab9 | 354 | |
4d897458 | 355 | touch $RPM_BUILD_ROOT/var/log/cups/{access_log,error_log,page_log} |
cad7b106 | 356 | touch $RPM_BUILD_ROOT/etc/security/blacklist.cups |
a453f068 JR |
357 | touch $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/{classes,printers}.conf |
358 | ||
359 | cat >$RPM_BUILD_ROOT%{_sysconfdir}/%{name}/client.conf <<'EOF' | |
360 | # Encryption Always | |
be6d8910 | 361 | # ServerName enter.server.IP.or.name |
a453f068 | 362 | EOF |
679be76f | 363 | |
ef5fe709 ER |
364 | # windows drivers can be put there. |
365 | install -d $RPM_BUILD_ROOT%{_datadir}/cups/drivers | |
366 | ||
748a0bf9 ER |
367 | # dirs for gimp-print-cups-4.2.7-1 |
368 | install -d $RPM_BUILD_ROOT%{_datadir}/cups/model/{C,da,en_GB,fr,nb,pl,sv} | |
369 | ||
daf27ba0 | 370 | touch $RPM_BUILD_ROOT/var/cache/cups/help.index |
6139e54a | 371 | touch $RPM_BUILD_ROOT/var/cache/cups/{job,remote}.cache |
68e5a032 | 372 | touch $RPM_BUILD_ROOT/var/cache/cups/ppds.dat |
748a0bf9 | 373 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/cups/ssl |
ef5fe709 | 374 | |
eea94f34 | 375 | # links to enable/disable (compatibility!) |
748a0bf9 ER |
376 | ln -s accept $RPM_BUILD_ROOT%{_sbindir}/enable |
377 | ln -s accept $RPM_BUILD_ROOT%{_sbindir}/disable | |
eea94f34 | 378 | |
9625f17f JB |
379 | %clean |
380 | rm -rf $RPM_BUILD_ROOT | |
381 | ||
168e60c2 | 382 | %post |
96792ec6 JR |
383 | # Deal with config migration due to CVE-2012-5519 (STR #4223) |
384 | _keywords="^\(AccessLog\|CacheDir\|ConfigFilePerm\|\ | |
385 | DataDir\|DocumentRoot\|ErrorLog\|FatalErrors\|\ | |
386 | FileDevice\|FontPath\|Group\|LogFilePerm\|\ | |
387 | LPDConfigFile\|PageLog\|Printcap\|PrintcapFormat\|\ | |
388 | RemoteRoot\|RequestRoot\|ServerBin\|ServerCertificate\|\ | |
389 | ServerKey\|ServerRoot\|SMBConfigFile\|StateDir\|\ | |
9fc3c00d | 390 | SystemGroup\|SystemGroupAuthKey\|TempDir\|User\)\b" |
96792ec6 JR |
391 | if [ -f %{_sysconfdir}/cups/cupsd.conf ] && grep -iq "$_keywords" %{_sysconfdir}/cups/cupsd.conf; then |
392 | echo "# Settings automatically moved from cupsd.conf by RPM package:" >> %{_sysconfdir}/cups/cups-files.conf | |
393 | grep -i "$_keywords" %{_sysconfdir}/cups/cupsd.conf >> %{_sysconfdir}/cups/cups-files.conf || : | |
394 | %{__sed} -i -e "s,$_keywords,#&,ig" %{_sysconfdir}/cups/cupsd.conf || : | |
395 | fi | |
8a24ec7f | 396 | /sbin/chkconfig --add cups |
a73a2669 | 397 | %service cups restart "cups daemon" |
8b6d67b6 | 398 | /sbin/rmmod usblp > /dev/null 2>&1 || : |
fab640ee | 399 | %systemd_post cups.service cups.socket cups.path |
fb328468 | 400 | |
168e60c2 | 401 | %preun |
fd7e4ff1 | 402 | if [ "$1" = "0" ]; then |
a73a2669 | 403 | %service cups stop |
fd7e4ff1 | 404 | /sbin/chkconfig --del cups |
405 | fi | |
fab640ee | 406 | %systemd_preun cups.service cups.socket cups.path |
cdbbf080 JR |
407 | |
408 | %postun | |
409 | %systemd_reload | |
410 | ||
96792ec6 | 411 | %triggerpostun -- cups < 1:1.5.2-1 |
fab640ee | 412 | %systemd_trigger cups.service cups.socket cups.path |
168e60c2 | 413 | |
19e8d1ed | 414 | %post lib -p /sbin/ldconfig |
415 | %postun lib -p /sbin/ldconfig | |
416 | %post image-lib -p /sbin/ldconfig | |
417 | %postun image-lib -p /sbin/ldconfig | |
8bdc526e | 418 | |
84d9a886 JR |
419 | %post lpd |
420 | %service -q rc-inetd reload | |
421 | ||
422 | %postun lpd | |
9fc3c00d | 423 | if [ "$1" = "0" ]; then |
84d9a886 JR |
424 | %service -q rc-inetd reload |
425 | fi | |
426 | ||
fd7e4ff1 | 427 | %files |
346112e3 | 428 | %defattr(644,root,root,755) |
5565574e | 429 | %doc *.md |
9a4bd15e | 430 | %attr(640,root,root) %config %verify(not md5 mtime size) /etc/pam.d/cups |
8bdc526e | 431 | %attr(754,root,root) /etc/rc.d/init.d/cups |
e809c01b | 432 | /etc/dbus-1/system.d/cups.conf |
19a74fff | 433 | /etc/modprobe.d/cups.conf |
10718067 | 434 | %if %{with systemd} |
fab640ee JR |
435 | %{systemdunitdir}/cups.service |
436 | %{systemdunitdir}/cups.socket | |
437 | %{systemdunitdir}/cups.path | |
cdbbf080 | 438 | %{systemdtmpfilesdir}/%{name}.conf |
10718067 | 439 | %endif |
6139e54a | 440 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/classes.conf |
885cd154 | 441 | %attr(640,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/cups-files.conf |
ba9f57fd | 442 | %attr(640,root,lp) %{_sysconfdir}/%{name}/cups-files.conf.default |
39956f63 | 443 | %attr(640,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/cupsd.conf |
3e1538e5 | 444 | %attr(640,root,lp) %{_sysconfdir}/%{name}/cupsd.conf.default |
daf27ba0 | 445 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/printers.conf |
60e0cb5a | 446 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/mailto.conf |
3cb197ff | 447 | %attr(600,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/snmp.conf |
ba9f57fd | 448 | %attr(640,root,lp) %{_sysconfdir}/%{name}/snmp.conf.default |
cd29fb20 | 449 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.cups |
4017839a | 450 | %dir %attr(700,root,lp) %{_sysconfdir}/%{name}/ssl |
6139e54a | 451 | %dir %attr(755,root,lp) %{_sysconfdir}/%{name}/ppd |
39956f63 | 452 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name} |
3ddab923 | 453 | %attr(755,root,root) %{_bindir}/cupstestppd |
5565574e | 454 | %attr(755,root,root) %{_bindir}/ippeveprinter |
ceddaf82 | 455 | %attr(755,root,root) %{_sbindir}/cupsctl |
daf27ba0 | 456 | %attr(755,root,root) %{_sbindir}/cupsd |
ceddaf82 | 457 | %attr(755,root,root) %{_sbindir}/cupsfilter |
daf27ba0 | 458 | |
82f3f074 | 459 | %dir %{_ulibdir}/cups |
9a4bd15e JB |
460 | %dir %{_ulibdir}/cups/backend |
461 | %if %{with avahi} | |
462 | %attr(755,root,root) %{_ulibdir}/cups/backend/dnssd | |
463 | %attr(755,root,root) %{_ulibdir}/cups/backend/mdns | |
464 | %endif | |
465 | %attr(755,root,root) %{_ulibdir}/cups/backend/http | |
8196abcc | 466 | %attr(755,root,root) %{_ulibdir}/cups/backend/https |
9a4bd15e | 467 | %attr(755,root,root) %{_ulibdir}/cups/backend/ipp |
8196abcc | 468 | %attr(755,root,root) %{_ulibdir}/cups/backend/ipps |
9a4bd15e JB |
469 | %attr(755,root,root) %{_ulibdir}/cups/backend/lpd |
470 | %attr(755,root,root) %{_ulibdir}/cups/backend/snmp | |
471 | %attr(755,root,root) %{_ulibdir}/cups/backend/socket | |
472 | ||
473 | %dir %{_ulibdir}/cups/cgi-bin | |
daf27ba0 KK |
474 | %{_ulibdir}/cups/cgi-bin/help |
475 | %{_ulibdir}/cups/cgi-bin/images | |
476 | %attr(755,root,root) %{_ulibdir}/cups/cgi-bin/*.cgi | |
477 | %{_ulibdir}/cups/cgi-bin/*.css | |
478 | %{_ulibdir}/cups/cgi-bin/*.html | |
862c04f1 | 479 | %{_ulibdir}/cups/cgi-bin/*.png |
daf27ba0 | 480 | %{_ulibdir}/cups/cgi-bin/*.txt |
fab640ee | 481 | %lang(da) %{_ulibdir}/cups/cgi-bin/da |
d66b1516 | 482 | %lang(de) %{_ulibdir}/cups/cgi-bin/de |
daf27ba0 | 483 | %lang(es) %{_ulibdir}/cups/cgi-bin/es |
fab640ee | 484 | %lang(fr) %{_ulibdir}/cups/cgi-bin/fr |
a04566f3 | 485 | %lang(ja) %{_ulibdir}/cups/cgi-bin/ja |
c0eececa | 486 | %lang(pt_BR) %{_ulibdir}/cups/cgi-bin/pt_BR |
d66b1516 | 487 | %lang(ru) %{_ulibdir}/cups/cgi-bin/ru |
daf27ba0 | 488 | |
5565574e AM |
489 | %dir %{_ulibdir}/cups/command |
490 | %attr(755,root,root) %{_ulibdir}/cups/command/ippevepcl | |
491 | %attr(755,root,root) %{_ulibdir}/cups/command/ippeveps | |
9a4bd15e | 492 | %dir %{_ulibdir}/cups/daemon |
84d9a886 JR |
493 | %attr(755,root,root) %{_ulibdir}/cups/daemon/cups-deviced |
494 | %attr(755,root,root) %{_ulibdir}/cups/daemon/cups-driverd | |
d15c7d48 | 495 | %attr(755,root,root) %{_ulibdir}/cups/daemon/cups-exec |
7bb201d9 | 496 | %dir %{_ulibdir}/cups/driver |
9a4bd15e JB |
497 | %dir %{_ulibdir}/cups/filter |
498 | %attr(755,root,root) %{_ulibdir}/cups/filter/commandtops | |
499 | %attr(755,root,root) %{_ulibdir}/cups/filter/gziptoany | |
500 | %attr(755,root,root) %{_ulibdir}/cups/filter/pstops | |
9a4bd15e JB |
501 | %attr(755,root,root) %{_ulibdir}/cups/filter/rastertoepson |
502 | %attr(755,root,root) %{_ulibdir}/cups/filter/rastertohp | |
503 | %attr(755,root,root) %{_ulibdir}/cups/filter/rastertolabel | |
504 | %attr(755,root,root) %{_ulibdir}/cups/filter/rastertopwg | |
505 | %dir %{_ulibdir}/cups/monitor | |
506 | %attr(755,root,root) %{_ulibdir}/cups/monitor/bcp | |
507 | %attr(755,root,root) %{_ulibdir}/cups/monitor/tbcp | |
508 | %dir %{_ulibdir}/cups/notifier | |
509 | %attr(755,root,root) %{_ulibdir}/cups/notifier/dbus | |
510 | %attr(755,root,root) %{_ulibdir}/cups/notifier/mailto | |
511 | %attr(755,root,root) %{_ulibdir}/cups/notifier/rss | |
daf27ba0 | 512 | |
4a2b7af1 | 513 | %dir %{_datadir}/cups/banners |
7616b8ed | 514 | %dir %{_datadir}/cups/data |
9a4bd15e | 515 | %dir %{_datadir}/cups/drivers |
9a4bd15e JB |
516 | %dir %{_datadir}/cups/mime |
517 | %{_datadir}/cups/mime/mime.convs | |
518 | %{_datadir}/cups/mime/mime.types | |
748a0bf9 | 519 | %dir %{_datadir}/cups/model |
748a0bf9 ER |
520 | # dirs for gimp-print-cups-4.2.7-1 |
521 | %dir %{_datadir}/cups/model/C | |
522 | %lang(da) %dir %{_datadir}/cups/model/da | |
523 | %lang(en_GB) %dir %{_datadir}/cups/model/en_GB | |
524 | %lang(fr) %dir %{_datadir}/cups/model/fr | |
525 | %lang(nb) %dir %{_datadir}/cups/model/nb | |
526 | %lang(pl) %dir %{_datadir}/cups/model/pl | |
527 | %lang(sv) %dir %{_datadir}/cups/model/sv | |
528 | ||
54906e64 ER |
529 | %dir %{_datadir}/cups/templates |
530 | %{_datadir}/cups/templates/*.tmpl | |
fab640ee | 531 | %lang(da) %{_datadir}/cups/templates/da |
d66b1516 | 532 | %lang(de) %{_datadir}/cups/templates/de |
54906e64 | 533 | %lang(es) %{_datadir}/cups/templates/es |
32548b83 | 534 | %lang(fr) %{_datadir}/cups/templates/fr |
a04566f3 | 535 | %lang(ja) %{_datadir}/cups/templates/ja |
c0eececa | 536 | %lang(pt_BR) %{_datadir}/cups/templates/pt_BR |
d66b1516 | 537 | %lang(ru) %{_datadir}/cups/templates/ru |
862c04f1 | 538 | %{_mandir}/man1/cups.1* |
c1555e94 | 539 | %{_mandir}/man1/cupstestppd.1* |
5565574e | 540 | %{_mandir}/man1/ippeveprinter.1* |
9a4bd15e | 541 | %{_mandir}/man5/classes.conf.5* |
9a4bd15e JB |
542 | %{_mandir}/man5/cups-files.conf.5* |
543 | %{_mandir}/man5/cups-snmp.conf.5* | |
544 | %{_mandir}/man5/cupsd.conf.5* | |
d66b1516 | 545 | %{_mandir}/man5/cupsd-logs.5* |
9a4bd15e JB |
546 | %{_mandir}/man5/ipptoolfile.5* |
547 | %{_mandir}/man5/mailto.conf.5* | |
548 | %{_mandir}/man5/mime.convs.5* | |
549 | %{_mandir}/man5/mime.types.5* | |
9a4bd15e JB |
550 | %{_mandir}/man5/printers.conf.5* |
551 | %{_mandir}/man5/subscriptions.conf.5* | |
200bc650 JB |
552 | %{_mandir}/man7/backend.7* |
553 | %{_mandir}/man7/filter.7* | |
5565574e AM |
554 | %{_mandir}/man7/ippevepcl.7* |
555 | %{_mandir}/man7/ippeveps.7* | |
200bc650 | 556 | %{_mandir}/man7/notifier.7* |
84d9a886 JR |
557 | %{_mandir}/man8/cups-deviced.8* |
558 | %{_mandir}/man8/cups-driverd.8* | |
862c04f1 | 559 | %{_mandir}/man8/cups-exec.8* |
885cd154 | 560 | %{_mandir}/man8/cups-snmp.8* |
84d9a886 JR |
561 | %{_mandir}/man8/cupsctl.8* |
562 | %{_mandir}/man8/cupsd.8* | |
862c04f1 | 563 | %{_mandir}/man8/cupsd-helper.8* |
84d9a886 | 564 | %{_mandir}/man8/cupsfilter.8* |
daf27ba0 KK |
565 | |
566 | %dir %attr(775,root,lp) /var/cache/cups | |
428f33ff KK |
567 | %dir %attr(755,root,lp) /var/lib/cups |
568 | %dir %attr(511,lp,sys) /var/lib/cups/certs | |
6139e54a | 569 | %dir %attr(755,root,lp) /var/run/cups |
daf27ba0 KK |
570 | %dir %attr(710,root,lp) /var/spool/cups |
571 | %dir %attr(1770,root,lp) /var/spool/cups/tmp | |
68e5a032 | 572 | %attr(600,lp,lp) %ghost /var/cache/cups/help.index |
6139e54a | 573 | %attr(640,root,lp) %ghost /var/cache/cups/job.cache |
68e5a032 | 574 | %attr(600,lp,lp) %ghost /var/cache/cups/ppds.dat |
6139e54a | 575 | %attr(640,root,lp) %ghost /var/cache/cups/remote.cache |
081a50cb | 576 | %attr(750,root,logs) %dir /var/log/archive/cups |
40183055 JK |
577 | %attr(750,root,logs) %dir /var/log/cups |
578 | %attr(640,root,logs) %ghost /var/log/cups/access_log | |
579 | %attr(640,root,logs) %ghost /var/log/cups/error_log | |
580 | %attr(640,root,logs) %ghost /var/log/cups/page_log | |
980a97fe | 581 | |
200bc650 | 582 | %files backend-usb |
6ebf74dd | 583 | %defattr(644,root,root,755) |
200bc650 JB |
584 | %attr(755,root,root) %{_ulibdir}/cups/backend/usb |
585 | %dir %{_datadir}/cups/usb | |
586 | %{_datadir}/cups/usb/org.cups.usb-quirks | |
587 | ||
588 | %files lpd | |
589 | %defattr(644,root,root,755) | |
590 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/cups-lpd | |
591 | %attr(755,root,root) %{_ulibdir}/cups/daemon/cups-lpd | |
10718067 | 592 | %if %{with systemd} |
fab640ee JR |
593 | %{systemdunitdir}/cups-lpd.socket |
594 | %{systemdunitdir}/cups-lpd@.service | |
10718067 | 595 | %endif |
200bc650 JB |
596 | %{_mandir}/man8/cups-lpd.8* |
597 | ||
598 | %files ppdc | |
599 | %defattr(644,root,root,755) | |
600 | %attr(755,root,root) %{_bindir}/ppd* | |
601 | %dir %{_datadir}/cups/drv | |
602 | %{_datadir}/cups/drv/sample.drv | |
603 | %dir %{_datadir}/cups/examples | |
604 | %{_datadir}/cups/examples/*.drv | |
605 | %dir %{_datadir}/cups/ppdc | |
606 | %{_datadir}/cups/ppdc/epson.h | |
607 | %{_datadir}/cups/ppdc/hp.h | |
608 | %{_datadir}/cups/ppdc/label.h | |
609 | %{_datadir}/cups/ppdc/font.defs | |
610 | %{_datadir}/cups/ppdc/media.defs | |
611 | %{_datadir}/cups/ppdc/raster.defs | |
612 | %{_mandir}/man1/ppd*.1* | |
613 | %{_mandir}/man5/ppdcfile.5* | |
6ebf74dd | 614 | |
2da56f05 SZ |
615 | %files clients |
616 | %defattr(644,root,root,755) | |
8d2025a2 | 617 | %attr(644,root,lp) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/client.conf |
2da56f05 | 618 | %attr(755,root,root) %{_bindir}/cancel |
601d6000 | 619 | %{?with_avahi:%attr(755,root,root) %{_bindir}/ippfind} |
d15c7d48 | 620 | %attr(755,root,root) %{_bindir}/ipptool |
2da56f05 SZ |
621 | %attr(755,root,root) %{_bindir}/lp |
622 | %attr(755,root,root) %{_bindir}/lpoptions | |
623 | %attr(755,root,root) %{_bindir}/lpq | |
624 | %attr(755,root,root) %{_bindir}/lpr | |
625 | %attr(755,root,root) %{_bindir}/lprm | |
626 | %attr(755,root,root) %{_bindir}/lpstat | |
25802dee | 627 | %attr(755,root,root) %{_sbindir}/cupsaccept |
eea94f34 | 628 | %attr(755,root,root) %{_sbindir}/cupsenable |
629 | %attr(755,root,root) %{_sbindir}/cupsdisable | |
25802dee | 630 | %attr(755,root,root) %{_sbindir}/cupsreject |
eea94f34 | 631 | %attr(755,root,root) %{_sbindir}/disable |
632 | %attr(755,root,root) %{_sbindir}/enable | |
501ef07e AM |
633 | %attr(755,root,root) %{_sbindir}/lpadmin |
634 | %attr(755,root,root) %{_sbindir}/lpc | |
635 | %attr(755,root,root) %{_sbindir}/lpinfo | |
636 | %attr(755,root,root) %{_sbindir}/lpmove | |
d15c7d48 | 637 | %{_datadir}/cups/ipptool |
1770fa4c ER |
638 | %{_desktopdir}/cups.desktop |
639 | %{_iconsdir}/hicolor/*/apps/cups.png | |
93040bdf | 640 | %{_mandir}/man1/cancel.1* |
601d6000 | 641 | %{?with_avahi:%{_mandir}/man1/ippfind.1*} |
d15c7d48 | 642 | %{_mandir}/man1/ipptool.1* |
0366ccc3 AF |
643 | %{_mandir}/man1/lp.1* |
644 | %{_mandir}/man1/lpoptions.1* | |
645 | %{_mandir}/man1/lpq.1* | |
646 | %{_mandir}/man1/lpr.1* | |
647 | %{_mandir}/man1/lprm.1* | |
648 | %{_mandir}/man1/lpstat.1* | |
a453f068 | 649 | %{_mandir}/man5/client.conf.5* |
25802dee | 650 | %{_mandir}/man8/cupsaccept.8* |
a453f068 | 651 | %{_mandir}/man8/cupsenable.8* |
25802dee AM |
652 | %{_mandir}/man8/cupsdisable.8* |
653 | %{_mandir}/man8/cupsreject.8* | |
a453f068 JR |
654 | %{_mandir}/man8/lpadmin.8* |
655 | %{_mandir}/man8/lpc.8* | |
656 | %{_mandir}/man8/lpinfo.8* | |
657 | %{_mandir}/man8/lpmove.8* | |
2da56f05 | 658 | |
200bc650 JB |
659 | %files lib |
660 | %defattr(644,root,root,755) | |
661 | %dir %attr(755,root,lp) %{_sysconfdir}/%{name} | |
07168dc1 | 662 | %attr(755,root,root) %{_libdir}/libcups.so.2 |
200bc650 JB |
663 | %dir %{_datadir}/cups |
664 | %lang(ca) %{_localedir}/ca/cups_ca.po | |
665 | %lang(cs) %{_localedir}/cs/cups_cs.po | |
fab640ee | 666 | %lang(da) %{_localedir}/da/cups_da.po |
200bc650 | 667 | %lang(de) %{_localedir}/de/cups_de.po |
5565574e | 668 | %{_localedir}/en/cups_en.po |
200bc650 JB |
669 | %lang(es) %{_localedir}/es/cups_es.po |
670 | %lang(fr) %{_localedir}/fr/cups_fr.po | |
671 | %lang(it) %{_localedir}/it/cups_it.po | |
672 | %lang(ja) %{_localedir}/ja/cups_ja.po | |
673 | %lang(pt_BR) %{_localedir}/pt_BR/cups_pt_BR.po | |
674 | %lang(ru) %{_localedir}/ru/cups_ru.po | |
675 | %lang(zh_CN) %{_localedir}/zh_CN/cups_zh_CN.po | |
676 | ||
6ebf74dd | 677 | %files image-lib |
fd7e4ff1 | 678 | %defattr(644,root,root,755) |
07168dc1 | 679 | %attr(755,root,root) %{_libdir}/libcupsimage.so.2 |
fd7e4ff1 | 680 | |
980a97fe | 681 | %files devel |
682 | %defattr(644,root,root,755) | |
6e2c2519 | 683 | %attr(755,root,root) %{_bindir}/cups-config |
4e75f969 JB |
684 | %attr(755,root,root) %{_libdir}/libcups.so |
685 | %attr(755,root,root) %{_libdir}/libcupsimage.so | |
980a97fe | 686 | %{_includedir}/cups |
fab640ee | 687 | %{_pkgconfigdir}/cups.pc |
4e75f969 | 688 | %{_mandir}/man1/cups-config.1* |
980a97fe | 689 | |
373aff1e | 690 | %if %{with static_libs} |
8d2025a2 AM |
691 | %files static |
692 | %defattr(644,root,root,755) | |
4e75f969 JB |
693 | %{_libdir}/libcups.a |
694 | %{_libdir}/libcupsimage.a | |
373aff1e | 695 | %endif |