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