]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | # |
8ca02f3c | 2 | # "$Id: Makefile 5736 2006-07-13 19:59:36Z mike $" |
ef416fc2 | 3 | # |
4 | # Scheduler Makefile for the Common UNIX Printing System (CUPS). | |
5 | # | |
bd7854cb | 6 | # Copyright 1997-2006 by Easy Software Products, all rights reserved. |
ef416fc2 | 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 \ | |
09ec0018 | 48 | subscriptions.o \ |
49 | sysman.o | |
ef416fc2 | 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 | testmime.o \ | |
63 | testspeed.o \ | |
64 | util.o | |
65 | TARGETS = \ | |
66 | cupsd \ | |
67 | cups-deviced \ | |
68 | cups-driverd \ | |
69 | cups-lpd \ | |
70 | cups-polld \ | |
71 | libmime.a \ | |
72 | testdirsvc \ | |
73 | testmime \ | |
74 | testspeed | |
75 | ||
76 | ||
77 | # | |
78 | # Make everything... | |
79 | # | |
80 | ||
81 | all: $(TARGETS) | |
82 | ||
83 | ||
84 | # | |
85 | # Clean all object files... | |
86 | # | |
87 | ||
88 | clean: | |
89 | $(RM) $(OBJS) | |
90 | $(RM) $(TARGETS) | |
91 | ||
92 | ||
93 | # | |
94 | # Update dependencies (without system header dependencies...) | |
95 | # | |
96 | ||
97 | depend: | |
98 | makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1 | |
99 | ||
100 | ||
101 | # | |
102 | # Install the scheduler... | |
103 | # | |
104 | ||
105 | install: all | |
106 | echo Creating $(SBINDIR)... | |
923edb68 | 107 | $(INSTALL_DIR) -m 755 $(SBINDIR) |
ef416fc2 | 108 | echo Installing cupsd in $(SBINDIR)... |
109 | $(INSTALL_BIN) cupsd $(SBINDIR) | |
110 | echo Creating $(SERVERBIN)... | |
923edb68 | 111 | $(INSTALL_DIR) -m 755 $(SERVERBIN) |
ef416fc2 | 112 | echo Creating $(SERVERBIN)/daemon... |
923edb68 | 113 | $(INSTALL_DIR) -m 755 $(SERVERBIN)/daemon |
ef416fc2 | 114 | echo Installing cups-deviced, cups-driverd, cups-lpd, and cups-polld in $(SERVERBIN)/daemon... |
115 | $(INSTALL_BIN) cups-deviced $(SERVERBIN)/daemon | |
116 | $(INSTALL_BIN) cups-driverd $(SERVERBIN)/daemon | |
117 | $(INSTALL_BIN) cups-lpd $(SERVERBIN)/daemon | |
118 | $(INSTALL_BIN) cups-polld $(SERVERBIN)/daemon | |
119 | echo Creating $(SERVERBIN)/driver... | |
923edb68 | 120 | $(INSTALL_DIR) -m 755 $(SERVERBIN)/driver |
ef416fc2 | 121 | echo Creating $(SERVERROOT)... |
923edb68 | 122 | $(INSTALL_DIR) -m 755 $(SERVERROOT) |
bd7854cb | 123 | -chgrp $(CUPS_GROUP) $(SERVERROOT) |
ef416fc2 | 124 | echo Creating $(SERVERROOT)/interfaces... |
bd7854cb | 125 | $(INSTALL_DIR) -m 755 $(SERVERROOT)/interfaces |
126 | -chgrp $(CUPS_GROUP) $(SERVERROOT)/interfaces | |
ef416fc2 | 127 | echo Creating $(SERVERROOT)/ppd... |
bd7854cb | 128 | $(INSTALL_DIR) -m 755 $(SERVERROOT)/ppd |
129 | -chgrp $(CUPS_GROUP) $(SERVERROOT)/ppd | |
8ca02f3c | 130 | echo Creating $(SERVERROOT)/ssl... |
131 | $(INSTALL_DIR) -m 700 $(SERVERROOT)/ssl | |
132 | -chgrp $(CUPS_GROUP) $(SERVERROOT)/ssl | |
ef416fc2 | 133 | echo Creating $(STATEDIR)... |
923edb68 | 134 | $(INSTALL_DIR) -m 755 $(STATEDIR) |
ef416fc2 | 135 | echo Creating $(STATEDIR)/certs... |
bd7854cb | 136 | $(INSTALL_DIR) -m 511 $(STATEDIR)/certs |
137 | -chgrp $(CUPS_PRIMARY_SYSTEM_GROUP) $(STATEDIR)/certs | |
ef416fc2 | 138 | echo Creating $(LOGDIR)... |
923edb68 | 139 | $(INSTALL_DIR) -m 755 $(LOGDIR) |
ef416fc2 | 140 | echo Creating $(REQUESTS)... |
bd7854cb | 141 | $(INSTALL_DIR) -m 710 $(REQUESTS) |
142 | -chgrp $(CUPS_GROUP) $(REQUESTS) | |
923edb68 | 143 | echo Creating $(REQUESTS)/tmp... |
bd7854cb | 144 | $(INSTALL_DIR) -m 1770 $(REQUESTS)/tmp |
145 | -chgrp $(CUPS_GROUP) $(REQUESTS)/tmp | |
ef416fc2 | 146 | echo Creating $(CACHEDIR)... |
bd7854cb | 147 | $(INSTALL_DIR) -m 775 $(CACHEDIR) |
148 | -chgrp $(CUPS_GROUP) $(CACHEDIR) | |
923edb68 | 149 | # echo Creating $(CACHEDIR)/ppd... |
150 | # $(INSTALL_DIR) -m 755 $(CACHEDIR)/ppd | |
bd7854cb | 151 | # -chgrp $(CUPS_GROUP) $(CACHEDIR)/ppd |
ef416fc2 | 152 | |
153 | ||
757d2cad | 154 | # |
155 | # Uninstall the scheduler... | |
156 | # | |
157 | ||
158 | uninstall: all | |
159 | $(RM) $(SBINDIR)/cupsd | |
160 | $(RM) $(SERVERBIN)/daemon/cups-deviced | |
161 | $(RM) $(SERVERBIN)/daemon/cups-driverd | |
162 | $(RM) $(SERVERBIN)/daemon/cups-lpd | |
163 | $(RM) $(SERVERBIN)/daemon/cups-polld | |
164 | -$(RMDIR) $(STATEDIR)/certs | |
165 | -$(RMDIR) $(STATEDIR) | |
166 | -$(RMDIR) $(SERVERROOT)/ppd | |
167 | -$(RMDIR) $(SERVERROOT)/interfaces | |
168 | -$(RMDIR) $(SERVERROOT) | |
169 | -$(RMDIR) $(SERVERBIN)/driver | |
170 | -$(RMDIR) $(SERVERBIN)/daemon | |
171 | -$(RMDIR) $(SERVERBIN) | |
172 | -$(RMDIR) $(SBINDIR) | |
173 | -$(RMDIR) $(REQUESTS)/tmp | |
174 | -$(RMDIR) $(REQUESTS) | |
175 | -$(RMDIR) $(LOGDIR) | |
176 | -$(RMDIR) $(CACHEDIR) | |
177 | ||
178 | ||
ef416fc2 | 179 | # |
180 | # Make the scheduler executable, "cupsd". | |
181 | # | |
182 | ||
183 | cupsd: $(CUPSDOBJS) libmime.a ../cups/$(LIBCUPS) | |
184 | echo Linking $@... | |
185 | $(CC) $(LDFLAGS) -o cupsd $(CUPSDOBJS) libmime.a \ | |
b423cd4c | 186 | $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \ |
09ec0018 | 187 | $(LIBPAPER) $(LIBMALLOC) $(CUPSDLIBS) $(LIBS) |
ef416fc2 | 188 | |
189 | cupsd-static: $(CUPSDOBJS) libmime.a ../cups/libcups.a | |
190 | echo Linking $@... | |
191 | $(CC) $(LDFLAGS) -o cupsd-static $(CUPSDOBJS) libmime.a \ | |
b423cd4c | 192 | $(LIBZ) $(SSLLIBS) $(LIBSLP) $(LIBLDAP) $(PAMLIBS) \ |
193 | ../cups/libcups.a $(COMMONLIBS) $(LIBZ) $(LIBPAPER) \ | |
194 | $(LIBMALLOC) $(CUPSDLIBS) | |
ef416fc2 | 195 | |
196 | ||
197 | # | |
198 | # Make the device daemon, "cups-deviced". | |
199 | # | |
200 | ||
201 | cups-deviced: cups-deviced.o util.o ../cups/$(LIBCUPS) | |
202 | echo Linking $@... | |
203 | $(CC) $(LDFLAGS) -o cups-deviced cups-deviced.o util.o $(LIBS) | |
204 | ||
205 | ||
206 | # | |
207 | # Make the driver daemon, "cups-driverd". | |
208 | # | |
209 | ||
210 | cups-driverd: cups-driverd.o util.o ../cups/$(LIBCUPS) | |
211 | echo Linking $@... | |
212 | $(CC) $(LDFLAGS) -o cups-driverd cups-driverd.o util.o $(LIBS) | |
213 | ||
214 | ||
215 | # | |
216 | # Make the line printer daemon, "cups-lpd". | |
217 | # | |
218 | ||
219 | cups-lpd: cups-lpd.o ../cups/$(LIBCUPS) | |
220 | echo Linking $@... | |
221 | $(CC) $(LDFLAGS) -o cups-lpd cups-lpd.o $(LIBS) | |
222 | ||
223 | ||
224 | # | |
225 | # Make the polling daemon, "cups-polld". | |
226 | # | |
227 | ||
228 | cups-polld: cups-polld.o ../cups/$(LIBCUPS) | |
229 | echo Linking $@... | |
230 | $(CC) $(LDFLAGS) -o cups-polld cups-polld.o $(LIBS) | |
231 | ||
232 | ||
233 | # | |
234 | # libmime.a | |
235 | # | |
236 | ||
237 | libmime.a: $(MIMEOBJS) | |
238 | echo Archiving $@... | |
239 | $(RM) $@ | |
240 | $(AR) $(ARFLAGS) $@ $(MIMEOBJS) | |
241 | $(RANLIB) $@ | |
242 | ||
243 | ||
244 | # | |
245 | # Make the test program, "testdirsvc". | |
246 | # | |
247 | ||
248 | testdirsvc: testdirsvc.o | |
249 | echo Linking $@... | |
250 | $(CC) $(LDFLAGS) -o testdirsvc testdirsvc.o $(COMMONLIBS) $(NETLIBS) | |
251 | ||
252 | ||
253 | # | |
254 | # testmime | |
255 | # | |
256 | ||
fa73b229 | 257 | testmime: testmime.o libmime.a ../cups/libcups.a |
ef416fc2 | 258 | echo Linking $@... |
259 | $(CC) $(LDFLAGS) -o $@ testmime.o libmime.a ../cups/libcups.a \ | |
fa73b229 | 260 | $(COMMONLIBS) $(LIBZ) $(SSLLIBS) |
ef416fc2 | 261 | |
262 | ||
263 | # | |
264 | # Make the test program, "testspeed". | |
265 | # | |
266 | ||
267 | testspeed: testspeed.o ../cups/$(LIBCUPS) | |
268 | echo Linking $@... | |
269 | $(CC) $(LDFLAGS) -o testspeed testspeed.o $(LIBS) | |
270 | ||
271 | ||
272 | # | |
273 | # Dependencies... | |
274 | # | |
275 | ||
276 | include Dependencies | |
277 | ||
278 | ||
279 | # | |
8ca02f3c | 280 | # End of "$Id: Makefile 5736 2006-07-13 19:59:36Z mike $". |
ef416fc2 | 281 | # |