]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | # |
b19ccc9e | 2 | # "$Id: Makefile 7929 2008-09-10 22:23:59Z mike $" |
ef416fc2 | 3 | # |
4 | # System V commands makefile for the Common UNIX Printing System (CUPS). | |
5 | # | |
568fa3fa | 6 | # Copyright 2007-2008 by Apple Inc. |
bd7854cb | 7 | # Copyright 1997-2006 by Easy Software Products, all rights reserved. |
ef416fc2 | 8 | # |
9 | # These coded instructions, statements, and computer programs are the | |
bc44d920 | 10 | # property of Apple Inc. and are protected by Federal copyright |
11 | # law. Distribution and use rights are outlined in the file "LICENSE.txt" | |
12 | # which should have been included with this file. If this file is | |
13 | # file is missing or damaged, see the license at "http://www.cups.org/". | |
ef416fc2 | 14 | # |
15 | ||
16 | include ../Makedefs | |
17 | ||
bc44d920 | 18 | TARGETS = accept cancel cupsaddsmb cupsctl cupstestdsc cupstestppd \ |
80ca4592 | 19 | lp lpadmin lpinfo lpmove lpoptions lppasswd lpstat |
bc44d920 | 20 | OBJS = accept.o cancel.o cupsaddsmb.o cupsctl.o cupstestdsc.o \ |
21 | cupstestppd.o lp.o lpadmin.o lpinfo.o lpmove.o lpoptions.o \ | |
22 | lppasswd.o lpstat.o | |
ef416fc2 | 23 | |
24 | ||
25 | # | |
26 | # Make all targets... | |
27 | # | |
28 | ||
29 | all: $(TARGETS) | |
30 | ||
31 | ||
c9fc04c6 MS |
32 | # |
33 | # Make library targets... | |
34 | # | |
35 | ||
36 | libs: | |
37 | ||
38 | ||
5f64df29 MS |
39 | # |
40 | # Make unit tests... | |
41 | # | |
42 | ||
43 | unittests: | |
44 | ||
45 | ||
ef416fc2 | 46 | # |
47 | # Clean all object files... | |
48 | # | |
49 | ||
50 | clean: | |
49d87452 MS |
51 | $(RM) $(OBJS) $(TARGETS) |
52 | $(RM) cupsaccept cupsdisable cupsenable cupsreject reject | |
ef416fc2 | 53 | |
54 | ||
55 | # | |
56 | # Update dependencies (without system header dependencies...) | |
57 | # | |
58 | ||
59 | depend: | |
60 | makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1 | |
61 | ||
62 | ||
63 | # | |
64 | # Install all targets... | |
65 | # | |
66 | ||
50fe7201 MS |
67 | install: all install-data install-headers install-libs install-exec |
68 | ||
69 | ||
70 | # | |
71 | # Install data files... | |
72 | # | |
73 | ||
74 | install-data: | |
75 | ||
76 | ||
77 | # | |
78 | # Install programs... | |
79 | # | |
80 | ||
81 | install-exec: | |
bd7854cb | 82 | $(INSTALL_DIR) -m 755 $(SBINDIR) |
ef416fc2 | 83 | $(INSTALL_BIN) accept $(SBINDIR) |
84 | $(RM) $(SBINDIR)/reject | |
85 | $(LN) accept $(SBINDIR)/reject | |
86 | $(INSTALL_BIN) cupsaddsmb $(SBINDIR) | |
bc44d920 | 87 | $(INSTALL_BIN) cupsctl $(SBINDIR) |
ef416fc2 | 88 | $(INSTALL_BIN) lpadmin $(SBINDIR) |
89 | $(INSTALL_BIN) lpinfo $(SBINDIR) | |
90 | $(INSTALL_BIN) lpmove $(SBINDIR) | |
bd7854cb | 91 | $(INSTALL_DIR) -m 755 $(BINDIR) |
ef416fc2 | 92 | $(INSTALL_BIN) cancel $(BINDIR) |
80ca4592 | 93 | $(INSTALL_BIN) cupstestdsc $(BINDIR) |
ef416fc2 | 94 | $(INSTALL_BIN) cupstestppd $(BINDIR) |
49d87452 MS |
95 | $(RM) $(SBINDIR)/cupsaccept |
96 | $(LN) accept $(SBINDIR)/cupsaccept | |
923edb68 | 97 | $(RM) $(SBINDIR)/cupsdisable |
98 | $(LN) accept $(SBINDIR)/cupsdisable | |
99 | $(RM) $(SBINDIR)/cupsenable | |
100 | $(LN) accept $(SBINDIR)/cupsenable | |
49d87452 MS |
101 | $(RM) $(SBINDIR)/cupsreject |
102 | $(LN) accept $(SBINDIR)/cupsreject | |
ef416fc2 | 103 | $(INSTALL_BIN) lp $(BINDIR) |
104 | $(INSTALL_BIN) lpoptions $(BINDIR) | |
105 | $(INSTALL_BIN) lpstat $(BINDIR) | |
568fa3fa | 106 | $(INSTALL_BIN) lppasswd $(BINDIR) |
09a101d6 | 107 | if test "x$(SYMROOT)" != "x"; then \ |
108 | $(INSTALL_DIR) $(SYMROOT); \ | |
109 | for file in $(TARGETS); do \ | |
110 | cp $$file $(SYMROOT); \ | |
111 | done \ | |
112 | fi | |
ef416fc2 | 113 | |
114 | ||
50fe7201 MS |
115 | # |
116 | # Install headers... | |
117 | # | |
118 | ||
119 | install-headers: | |
120 | ||
121 | ||
122 | # | |
123 | # Install libraries... | |
124 | # | |
125 | ||
126 | install-libs: | |
127 | ||
128 | ||
757d2cad | 129 | # |
130 | # Uninstall all targets... | |
131 | # | |
132 | ||
133 | uninstall: | |
134 | $(RM) $(BINDIR)/cancel | |
80ca4592 | 135 | $(RM) $(BINDIR)/cupstestdsc |
757d2cad | 136 | $(RM) $(BINDIR)/cupstestppd |
137 | $(RM) $(BINDIR)/lp | |
138 | $(RM) $(BINDIR)/lpoptions | |
139 | $(RM) $(BINDIR)/lppasswd | |
140 | $(RM) $(BINDIR)/lpstat | |
141 | -$(RMDIR) $(BINDIR) | |
142 | $(RM) $(SBINDIR)/accept | |
143 | $(RM) $(SBINDIR)/cupsaddsmb | |
49d87452 | 144 | $(RM) $(SBINDIR)/cupsaccept |
757d2cad | 145 | $(RM) $(SBINDIR)/cupsdisable |
146 | $(RM) $(SBINDIR)/cupsenable | |
49d87452 | 147 | $(RM) $(SBINDIR)/cupsreject |
757d2cad | 148 | $(RM) $(SBINDIR)/lpadmin |
149 | $(RM) $(SBINDIR)/lpinfo | |
150 | $(RM) $(SBINDIR)/lpmove | |
151 | $(RM) $(SBINDIR)/reject | |
152 | -$(RMDIR) $(SBINDIR) | |
153 | ||
154 | ||
ef416fc2 | 155 | # |
156 | # accept | |
157 | # | |
158 | ||
159 | accept: accept.o ../cups/$(LIBCUPS) | |
160 | echo Linking $@... | |
161 | $(CC) $(LDFLAGS) -o accept accept.o $(LIBS) | |
49d87452 | 162 | $(RM) cupsaccept cupsenable cupsdisable cupsreject reject |
ef416fc2 | 163 | $(LN) accept reject |
49d87452 | 164 | $(LN) accept cupsaccept |
4744bd90 | 165 | $(LN) accept cupsenable |
166 | $(LN) accept cupsdisable | |
49d87452 | 167 | $(LN) accept cupsreject |
ef416fc2 | 168 | |
169 | ||
170 | # | |
171 | # cancel | |
172 | # | |
173 | ||
174 | cancel: cancel.o ../cups/$(LIBCUPS) | |
175 | echo Linking $@... | |
176 | $(CC) $(LDFLAGS) -o cancel cancel.o $(LIBS) | |
177 | ||
178 | ||
179 | # | |
180 | # cupsaddsmb | |
181 | # | |
182 | ||
183 | cupsaddsmb: cupsaddsmb.o ../cups/$(LIBCUPS) | |
184 | echo Linking $@... | |
185 | $(CC) $(LDFLAGS) -o cupsaddsmb cupsaddsmb.o $(LIBS) | |
186 | ||
187 | ||
bc44d920 | 188 | # |
189 | # cupsctl | |
190 | # | |
191 | ||
192 | cupsctl: cupsctl.o ../cups/$(LIBCUPS) | |
193 | echo Linking $@... | |
194 | $(CC) $(LDFLAGS) -o cupsctl cupsctl.o $(LIBS) | |
195 | ||
196 | ||
80ca4592 | 197 | # |
198 | # cupstestdsc | |
199 | # | |
200 | ||
201 | cupstestdsc: cupstestdsc.o ../cups/$(LIBCUPS) | |
202 | echo Linking $@... | |
203 | $(CC) $(LDFLAGS) -o $@ cupstestdsc.o $(LIBS) | |
204 | ||
205 | ||
ef416fc2 | 206 | # |
207 | # cupstestppd | |
208 | # | |
209 | ||
09a101d6 | 210 | cupstestppd: cupstestppd.o ../cups/$(LIBCUPS) ../filter/$(LIBCUPSIMAGE) |
ef416fc2 | 211 | echo Linking $@... |
09a101d6 | 212 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o $(LINKCUPSIMAGE) $(IMGLIBS) $(LIBS) |
ef416fc2 | 213 | |
66ab9486 MS |
214 | cupstestppd-static: cupstestppd.o ../cups/libcups.a ../filter/libcupsimage.a |
215 | echo Linking $@... | |
216 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o ../filter/libcupsimage.a \ | |
217 | ../cups/libcups.a $(IMGLIBS) $(LIBGSSAPI) $(LIBS) $(LIBZ) | |
218 | ||
ef416fc2 | 219 | |
220 | # | |
221 | # lp | |
222 | # | |
223 | ||
224 | lp: lp.o ../cups/$(LIBCUPS) | |
225 | echo Linking $@... | |
226 | $(CC) $(LDFLAGS) -o lp lp.o $(LIBS) | |
227 | ||
228 | ||
229 | # | |
230 | # lpadmin | |
231 | # | |
232 | ||
233 | lpadmin: lpadmin.o ../cups/$(LIBCUPS) | |
234 | echo Linking $@... | |
235 | $(CC) $(LDFLAGS) -o lpadmin lpadmin.o $(LIBZ) $(LIBS) | |
236 | ||
237 | ||
238 | # | |
239 | # lpinfo | |
240 | # | |
241 | ||
242 | lpinfo: lpinfo.o ../cups/$(LIBCUPS) | |
243 | echo Linking $@... | |
244 | $(CC) $(LDFLAGS) -o lpinfo lpinfo.o $(LIBS) | |
245 | ||
246 | ||
247 | # | |
248 | # lpmove | |
249 | # | |
250 | ||
251 | lpmove: lpmove.o ../cups/$(LIBCUPS) | |
252 | echo Linking $@... | |
253 | $(CC) $(LDFLAGS) -o lpmove lpmove.o $(LIBS) | |
254 | ||
255 | ||
256 | # | |
257 | # lpoptions | |
258 | # | |
259 | ||
260 | lpoptions: lpoptions.o ../cups/$(LIBCUPS) | |
261 | echo Linking $@... | |
262 | $(CC) $(LDFLAGS) -o lpoptions lpoptions.o $(LIBZ) $(LIBS) | |
263 | ||
264 | ||
265 | # | |
266 | # lppasswd | |
267 | # | |
268 | ||
269 | lppasswd: lppasswd.o ../cups/$(LIBCUPS) | |
270 | echo Linking $@... | |
271 | $(CC) $(LDFLAGS) -o lppasswd lppasswd.o $(LIBZ) $(LIBS) | |
272 | ||
273 | ||
274 | # | |
275 | # lpstat | |
276 | # | |
277 | ||
278 | lpstat: lpstat.o ../cups/$(LIBCUPS) | |
279 | echo Linking $@... | |
280 | $(CC) $(LDFLAGS) -o lpstat lpstat.o $(LIBS) | |
281 | ||
282 | ||
283 | # | |
284 | # Dependencies... | |
285 | # | |
286 | ||
287 | include Dependencies | |
288 | ||
289 | ||
290 | # | |
b19ccc9e | 291 | # End of "$Id: Makefile 7929 2008-09-10 22:23:59Z mike $". |
ef416fc2 | 292 | # |