]> git.ipfire.org Git - thirdparty/cups.git/blob - packaging/cups.spec.in
Load cups into easysw/current.
[thirdparty/cups.git] / packaging / cups.spec.in
1 #
2 # "$Id: cups.spec.in 5146 2006-02-22 14:03:50Z mike $"
3 #
4 # RPM "spec" file for the Common UNIX Printing System (CUPS).
5 #
6 # Original version by Jason McMullan <jmcc@ontv.com>.
7 #
8 # Copyright 1999-2006 by Easy Software Products, all rights reserved.
9 #
10 # These coded instructions, statements, and computer programs are the
11 # property of Easy Software Products and are protected by Federal
12 # copyright law. Distribution and use rights are outlined in the file
13 # "LICENSE.txt" which should have been included with this file. If this
14 # file is missing or damaged please contact Easy Software Products
15 # at:
16 #
17 # Attn: CUPS Licensing Information
18 # Easy Software Products
19 # 44141 Airport View Drive, Suite 204
20 # Hollywood, Maryland 20636 USA
21 #
22 # Voice: (301) 373-9600
23 # EMail: cups-info@cups.org
24 # WWW: http://www.cups.org
25 #
26
27 # Conditional build options (--with name/--without name):
28 #
29 # dbus - Enable/disable DBUS support (default = enable)
30
31 %{!?_with_dbus: %{!?_without_dbus: %define _with_dbus --with-dbus}}
32 %{?_with_dbus: %define _dbus --enable-dbus}
33 %{!?_with_dbus: %define _dbus --disable-dbus}
34
35 Summary: Common UNIX Printing System
36 Name: cups
37 Version: @CUPS_VERSION@
38 Release: 0
39 Epoch: 1
40 License: GPL
41 Group: System Environment/Daemons
42 Source: ftp://ftp.easysw.com/pub/cups/%{version}/cups-%{version}-source.tar.gz
43 Url: http://www.cups.org
44 Packager: Anonymous <anonymous@foo.com>
45 Vendor: Easy Software Products
46
47 # Use buildroot so as not to disturb the version already installed
48 BuildRoot: /tmp/%{name}-root
49
50 # Dependencies...
51 Requires: %{name}-libs = %{epoch}:%{version}
52 Obsoletes: lpd, lpr, LPRng
53 Provides: lpd, lpr, LPRng
54
55 %package devel
56 Summary: Common UNIX Printing System - development environment
57 Group: Development/Libraries
58 Requires: %{name}-libs = %{epoch}:%{version}
59
60 %package libs
61 Summary: Common UNIX Printing System - shared libraries
62 Group: System Environment/Libraries
63 Provides: libcups1
64
65 %package lpd
66 Summary: Common UNIX Printing System - LPD support
67 Group: System Environment/Daemons
68 Requires: %{name} = %{epoch}:%{version} xinetd
69
70 %package ja
71 Summary: Common UNIX Printing System - Japanese support
72 Group: System Environment/Daemons
73 Requires: %{name} = %{epoch}:%{version}
74
75 %description
76 The Common UNIX Printing System provides a portable printing layer for
77 UNIX® operating systems. It has been developed by Easy Software Products
78 to promote a standard printing solution for all UNIX vendors and users.
79 CUPS provides the System V and Berkeley command-line interfaces.
80
81 %description devel
82 The Common UNIX Printing System provides a portable printing layer for
83 UNIX® operating systems. This is the development package for creating
84 additional printer drivers and other CUPS services.
85
86 %description libs
87 The Common UNIX Printing System provides a portable printing layer for
88 UNIX® operating systems. This package contains the CUPS shared libraries.
89
90 %description lpd
91 The Common UNIX Printing System provides a portable printing layer for
92 UNIX® operating systems. This package provides LPD client support.
93
94 %description ja
95 The Common UNIX Printing System provides a portable printing layer for
96 UNIX® operating systems. This package provides Japanese support.
97
98 %prep
99 %setup
100
101 %build
102 CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" LDFLAGS="$RPM_OPT_FLAGS" ./configure %{_dbus}
103
104 # If we got this far, all prerequisite libraries must be here.
105 make
106
107 %install
108 # Make sure the RPM_BUILD_ROOT directory exists.
109 rm -rf $RPM_BUILD_ROOT
110
111 make BUILDROOT=$RPM_BUILD_ROOT install
112
113 %post
114 /sbin/chkconfig --add cups
115 /sbin/chkconfig cups on
116
117 # Restart cupsd if we are upgrading...
118 if test $1 -gt 1; then
119 /sbin/service cups stop
120 /sbin/service cups start
121 fi
122
123 %post libs
124 /sbin/ldconfig
125
126 %preun
127 if test $1 = 0; then
128 /sbin/service cups stop
129 /sbin/chkconfig --del cups
130 fi
131
132 %postun
133 if test $1 -ge 1; then
134 /sbin/service cups stop
135 /sbin/service cups start
136 fi
137
138 %postun libs
139 /sbin/ldconfig
140
141 %clean
142 rm -rf $RPM_BUILD_ROOT
143
144 %files
145 %docdir /usr/share/doc/cups
146 %defattr(-,root,root)
147 %dir /etc/cups
148 %config(noreplace) /etc/cups/*.conf
149 /etc/cups/cupsd.conf.default
150 %dir /etc/cups/interfaces
151 /etc/cups/mime.types
152 /etc/cups/mime.convs
153 %dir /etc/cups/ppd
154
155 %if %{?_with_dbus:1}%{!?_with_dbus:0}
156 # DBUS
157 /etc/dbus-1/system.d/*
158 %endif
159
160 # PAM
161 %dir /etc/pam.d
162 /etc/pam.d/*
163
164 # RC dirs are a pain under Linux... Uncomment the appropriate ones if you
165 # don't use Red Hat or Mandrake...
166
167 /etc/init.d/*
168 /etc/rc0.d/*
169 /etc/rc2.d/*
170 /etc/rc3.d/*
171 /etc/rc5.d/*
172
173 # OLD RedHat/Mandrake
174 #/etc/rc.d/init.d/*
175 #/etc/rc.d/rc0.d/*
176 #/etc/rc.d/rc2.d/*
177 #/etc/rc.d/rc3.d/*
178 #/etc/rc.d/rc5.d/*
179
180 #/sbin/rc.d/*
181 #/sbin/rc.d/rc0.d/*
182 #/sbin/rc.d/rc2.d/*
183 #/sbin/rc.d/rc3.d/*
184 #/sbin/rc.d/rc5.d/*
185
186 /usr/bin/cancel
187 /usr/bin/cupstestppd
188 /usr/bin/lp*
189 %dir /usr/lib/cups
190 %dir /usr/lib/cups/backend
191 /usr/lib/cups/backend/http
192 /usr/lib/cups/backend/ipp
193 %attr(0700,root,root) /usr/lib/cups/backend/lpd
194 /usr/lib/cups/backend/parallel
195 /usr/lib/cups/backend/scsi
196 /usr/lib/cups/backend/serial
197 /usr/lib/cups/backend/socket
198 /usr/lib/cups/backend/usb
199 %dir /usr/lib/cups/cgi-bin
200 /usr/lib/cups/cgi-bin/*
201 %dir /usr/lib/cups/daemon
202 /usr/lib/cups/daemon/cups-deviced
203 /usr/lib/cups/daemon/cups-driverd
204 /usr/lib/cups/daemon/cups-polld
205 %dir /usr/lib/cups/driver
206 %dir /usr/lib/cups/filter
207 /usr/lib/cups/filter/*
208 %dir /usr/lib/cups/monitor
209 /usr/lib/cups/monitor/*
210 %dir /usr/lib/cups/notifier
211 /usr/lib/cups/notifier/*
212
213 /usr/sbin/*
214 %dir /usr/share/cups
215 /usr/share/cups/*
216 %dir /usr/share/doc/cups
217 /usr/share/doc/cups/*.*
218 %dir /usr/share/doc/cups/help
219 /usr/share/doc/cups/help/*-reference.html
220 /usr/share/doc/cups/help/man-*.html
221 /usr/share/doc/cups/help/network.html
222 /usr/share/doc/cups/help/overview.html
223 /usr/share/doc/cups/help/standard.html
224 /usr/share/doc/cups/help/whatsnew.html
225 %dir /usr/share/doc/cups/images
226 /usr/share/doc/cups/images/*
227 /usr/share/locale/fr/cups_fr.po
228
229 %dir /usr/share/man/man1
230 /usr/share/man/man1/cancel.1.gz
231 /usr/share/man/man1/cupstestppd.1.gz
232 /usr/share/man/man1/lp.1.gz
233 /usr/share/man/man1/lpoptions.1.gz
234 /usr/share/man/man1/lppasswd.1.gz
235 /usr/share/man/man1/lpq.1.gz
236 /usr/share/man/man1/lpr.1.gz
237 /usr/share/man/man1/lprm.1.gz
238 /usr/share/man/man1/lpstat.1.gz
239 %dir /usr/share/man/man5
240 /usr/share/man/man5/*
241 %dir /usr/share/man/man8
242 /usr/share/man/man8/accept.8.gz
243 /usr/share/man/man8/cupsaddsmb.8.gz
244 /usr/share/man/man8/cupsd.8.gz
245 /usr/share/man/man8/cupsdisable.8.gz
246 /usr/share/man/man8/cupsenable.8.gz
247 /usr/share/man/man8/cups-deviced.8.gz
248 /usr/share/man/man8/cups-driverd.8.gz
249 /usr/share/man/man8/cups-polld.8.gz
250 /usr/share/man/man8/lpadmin.8.gz
251 /usr/share/man/man8/lpc.8.gz
252 /usr/share/man/man8/lpinfo.8.gz
253 /usr/share/man/man8/lpmove.8.gz
254 /usr/share/man/man8/reject.8.gz
255
256 %dir /var/cache/cups
257 %dir /var/log/cups
258 %dir /var/run/cups
259 %attr(0711,lp,sys) %dir /var/run/cups/certs
260 %attr(0710,lp,sys) %dir /var/spool/cups
261 %attr(1770,lp,sys) %dir /var/spool/cups/tmp
262
263 %files devel
264 %defattr(-,root,root)
265 %dir /usr/share/man/man1
266 /usr/share/man/man1/cups-config.1.gz
267 %dir /usr/share/man/man7
268 /usr/share/man/man7/*
269
270 /usr/bin/cups-config
271 %dir /usr/include/cups
272 /usr/include/cups/*
273 #/usr/lib/*.a
274 /usr/lib/*.so
275
276 %dir /usr/share/doc/cups/help
277 /usr/share/doc/cups/help/api*.html
278 /usr/share/doc/cups/help/spec*.html
279
280 %files libs
281 %defattr(-,root,root)
282 /usr/lib/*.so.*
283
284 %files lpd
285 %defattr(-,root,root)
286 #/etc/xinetd.d/cups-lpd
287 %dir /usr/lib/cups
288 %dir /usr/lib/cups/daemon
289 /usr/lib/cups/daemon/cups-lpd
290 %dir /usr/share/man/man8
291 /usr/share/man/man8/cups-lpd.8.gz
292
293 %files ja
294 %defattr(-,root,root)
295 %dir /usr/share/doc/cups/ja
296 /usr/share/doc/cups/ja/index.html
297 %dir /usr/share/doc/cups/ja/images
298 /usr/share/doc/cups/ja/images/*
299 %dir /usr/share/cups/templates/ja
300 /usr/share/cups/templates/ja/*
301 /usr/share/locale/ja/cups_ja.po
302
303 #
304 # End of "$Id: cups.spec.in 5146 2006-02-22 14:03:50Z mike $".
305 #