]> git.ipfire.org Git - thirdparty/cups.git/blob - scheduler/Makefile
Load cups into easysw/current.
[thirdparty/cups.git] / scheduler / Makefile
1 #
2 # "$Id: Makefile 5868 2006-08-23 19:39:39Z mike $"
3 #
4 # Scheduler Makefile for the Common UNIX Printing System (CUPS).
5 #
6 # Copyright 1997-2006 by Easy Software Products, all rights reserved.
7 #
8 # These coded instructions, statements, and computer programs are the
9 # property of Easy Software Products and are protected by Federal
10 # copyright law. Distribution and use rights are outlined in the file
11 # "LICENSE.txt" which should have been included with this file. If this
12 # file is missing or damaged please contact Easy Software Products
13 # at:
14 #
15 # Attn: CUPS Licensing Information
16 # Easy Software Products
17 # 44141 Airport View Drive, Suite 204
18 # Hollywood, Maryland 20636 USA
19 #
20 # Voice: (301) 373-9600
21 # EMail: cups-info@cups.org
22 # WWW: http://www.cups.org
23 #
24
25 include ../Makedefs
26
27 CUPSDOBJS = \
28 auth.o \
29 banners.o \
30 cert.o \
31 classes.o \
32 client.o \
33 conf.o \
34 dirsvc.o \
35 env.o \
36 main.o \
37 ipp.o \
38 listen.o \
39 job.o \
40 log.o \
41 network.o \
42 policy.o \
43 printers.o \
44 process.o \
45 quotas.o \
46 server.o \
47 statbuf.o \
48 subscriptions.o \
49 sysman.o
50 MIMEOBJS = \
51 filter.o \
52 mime.o \
53 type.o
54 OBJS = \
55 $(CUPSDOBJS) \
56 $(MIMEOBJS) \
57 cups-deviced.o \
58 cups-driverd.o \
59 cups-lpd.o \
60 cups-polld.o \
61 testdirsvc.o \
62 testlpd.o \
63 testmime.o \
64 testspeed.o \
65 util.o
66 TARGETS = \
67 cupsd \
68 cups-deviced \
69 cups-driverd \
70 cups-lpd \
71 cups-polld \
72 libmime.a \
73 testdirsvc \
74 testlpd \
75 testmime \
76 testspeed
77
78
79 #
80 # Make everything...
81 #
82
83 all: $(TARGETS)
84
85
86 #
87 # Clean all object files...
88 #
89
90 clean:
91 $(RM) $(OBJS)
92 $(RM) $(TARGETS)
93
94
95 #
96 # Update dependencies (without system header dependencies...)
97 #
98
99 depend:
100 makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1
101
102
103 #
104 # Install the scheduler...
105 #
106
107 install: all
108 echo Creating $(SBINDIR)...
109 $(INSTALL_DIR) -m 755 $(SBINDIR)
110 echo Installing cupsd in $(SBINDIR)...
111 $(INSTALL_BIN) cupsd $(SBINDIR)
112 echo Creating $(SERVERBIN)...
113 $(INSTALL_DIR) -m 755 $(SERVERBIN)
114 echo Creating $(SERVERBIN)/daemon...
115 $(INSTALL_DIR) -m 755 $(SERVERBIN)/daemon
116 echo Installing cups-deviced, cups-driverd, cups-lpd, and cups-polld in $(SERVERBIN)/daemon...
117 $(INSTALL_BIN) cups-deviced $(SERVERBIN)/daemon
118 $(INSTALL_BIN) cups-driverd $(SERVERBIN)/daemon
119 $(INSTALL_BIN) cups-lpd $(SERVERBIN)/daemon
120 $(INSTALL_BIN) cups-polld $(SERVERBIN)/daemon
121 echo Creating $(SERVERBIN)/driver...
122 $(INSTALL_DIR) -m 755 $(SERVERBIN)/driver
123 echo Creating $(SERVERROOT)...
124 $(INSTALL_DIR) -m 755 $(SERVERROOT)
125 -chgrp $(CUPS_GROUP) $(SERVERROOT)
126 echo Creating $(SERVERROOT)/interfaces...
127 $(INSTALL_DIR) -m 755 $(SERVERROOT)/interfaces
128 -chgrp $(CUPS_GROUP) $(SERVERROOT)/interfaces
129 echo Creating $(SERVERROOT)/ppd...
130 $(INSTALL_DIR) -m 755 $(SERVERROOT)/ppd
131 -chgrp $(CUPS_GROUP) $(SERVERROOT)/ppd
132 echo Creating $(SERVERROOT)/ssl...
133 $(INSTALL_DIR) -m 700 $(SERVERROOT)/ssl
134 -chgrp $(CUPS_GROUP) $(SERVERROOT)/ssl
135 echo Creating $(STATEDIR)...
136 $(INSTALL_DIR) -m 755 $(STATEDIR)
137 echo Creating $(STATEDIR)/certs...
138 $(INSTALL_DIR) -m 511 $(STATEDIR)/certs
139 -chgrp $(CUPS_PRIMARY_SYSTEM_GROUP) $(STATEDIR)/certs
140 echo Creating $(LOGDIR)...
141 $(INSTALL_DIR) -m 755 $(LOGDIR)
142 echo Creating $(REQUESTS)...
143 $(INSTALL_DIR) -m 710 $(REQUESTS)
144 -chgrp $(CUPS_GROUP) $(REQUESTS)
145 echo Creating $(REQUESTS)/tmp...
146 $(INSTALL_DIR) -m 1770 $(REQUESTS)/tmp
147 -chgrp $(CUPS_GROUP) $(REQUESTS)/tmp
148 echo Creating $(CACHEDIR)...
149 $(INSTALL_DIR) -m 775 $(CACHEDIR)
150 -chgrp $(CUPS_GROUP) $(CACHEDIR)
151 # echo Creating $(CACHEDIR)/ppd...
152 # $(INSTALL_DIR) -m 755 $(CACHEDIR)/ppd
153 # -chgrp $(CUPS_GROUP) $(CACHEDIR)/ppd
154
155
156 #
157 # Uninstall the scheduler...
158 #
159
160 uninstall: all
161 $(RM) $(SBINDIR)/cupsd
162 $(RM) $(SERVERBIN)/daemon/cups-deviced
163 $(RM) $(SERVERBIN)/daemon/cups-driverd
164 $(RM) $(SERVERBIN)/daemon/cups-lpd
165 $(RM) $(SERVERBIN)/daemon/cups-polld
166 -$(RMDIR) $(STATEDIR)/certs
167 -$(RMDIR) $(STATEDIR)
168 -$(RMDIR) $(SERVERROOT)/ppd
169 -$(RMDIR) $(SERVERROOT)/interfaces
170 -$(RMDIR) $(SERVERROOT)
171 -$(RMDIR) $(SERVERBIN)/driver
172 -$(RMDIR) $(SERVERBIN)/daemon
173 -$(RMDIR) $(SERVERBIN)
174 -$(RMDIR) $(SBINDIR)
175 -$(RMDIR) $(REQUESTS)/tmp
176 -$(RMDIR) $(REQUESTS)
177 -$(RMDIR) $(LOGDIR)
178 -$(RMDIR) $(CACHEDIR)
179
180
181 #
182 # Make the scheduler executable, "cupsd".
183 #
184
185 cupsd: $(CUPSDOBJS) libmime.a ../cups/$(LIBCUPS)
186 echo Linking $@...
187 $(CC) $(LDFLAGS) -o cupsd $(CUPSDOBJS) libmime.a \
188 $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \
189 $(LIBPAPER) $(LIBMALLOC) $(CUPSDLIBS) $(LIBS)
190
191 cupsd-static: $(CUPSDOBJS) libmime.a ../cups/libcups.a
192 echo Linking $@...
193 $(CC) $(LDFLAGS) -o cupsd-static $(CUPSDOBJS) libmime.a \
194 $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \
195 ../cups/libcups.a $(COMMONLIBS) $(LIBZ) $(LIBPAPER) \
196 $(LIBMALLOC) $(CUPSDLIBS)
197
198
199 #
200 # Make the device daemon, "cups-deviced".
201 #
202
203 cups-deviced: cups-deviced.o util.o ../cups/$(LIBCUPS)
204 echo Linking $@...
205 $(CC) $(LDFLAGS) -o cups-deviced cups-deviced.o util.o $(LIBS)
206
207
208 #
209 # Make the driver daemon, "cups-driverd".
210 #
211
212 cups-driverd: cups-driverd.o util.o ../cups/$(LIBCUPS)
213 echo Linking $@...
214 $(CC) $(LDFLAGS) -o cups-driverd cups-driverd.o util.o $(LIBS)
215
216
217 #
218 # Make the line printer daemon, "cups-lpd".
219 #
220
221 cups-lpd: cups-lpd.o ../cups/$(LIBCUPS)
222 echo Linking $@...
223 $(CC) $(LDFLAGS) -o cups-lpd cups-lpd.o $(LIBS)
224
225
226 #
227 # Make the polling daemon, "cups-polld".
228 #
229
230 cups-polld: cups-polld.o ../cups/$(LIBCUPS)
231 echo Linking $@...
232 $(CC) $(LDFLAGS) -o cups-polld cups-polld.o $(LIBS)
233
234
235 #
236 # libmime.a
237 #
238
239 libmime.a: $(MIMEOBJS)
240 echo Archiving $@...
241 $(RM) $@
242 $(AR) $(ARFLAGS) $@ $(MIMEOBJS)
243 $(RANLIB) $@
244
245
246 #
247 # Make the test program, "testdirsvc".
248 #
249
250 testdirsvc: testdirsvc.o
251 echo Linking $@...
252 $(CC) $(LDFLAGS) -o testdirsvc testdirsvc.o $(COMMONLIBS) $(NETLIBS)
253
254
255 #
256 # Make the test program, "testlpd".
257 #
258
259 testlpd: testlpd.o ../cups/libcups.a cups-lpd
260 echo Linking $@...
261 $(CC) $(LDFLAGS) -o testlpd testlpd.o ../cups/libcups.a \
262 $(COMMONLIBS) $(LIBZ) $(SSLLIBS)
263
264
265 #
266 # testmime
267 #
268
269 testmime: testmime.o libmime.a ../cups/libcups.a
270 echo Linking $@...
271 $(CC) $(LDFLAGS) -o $@ testmime.o libmime.a ../cups/libcups.a \
272 $(COMMONLIBS) $(LIBZ) $(SSLLIBS)
273
274
275 #
276 # Make the test program, "testspeed".
277 #
278
279 testspeed: testspeed.o ../cups/libcups.a
280 echo Linking $@...
281 $(CC) $(LDFLAGS) -o testspeed testspeed.o ../cups/libcups.a \
282 $(COMMONLIBS) $(LIBZ) $(SSLLIBS)
283
284
285 #
286 # Dependencies...
287 #
288
289 include Dependencies
290
291
292 #
293 # End of "$Id: Makefile 5868 2006-08-23 19:39:39Z mike $".
294 #