]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | # |
75bd9771 | 2 | # "$Id: Makefile 7558 2008-05-12 23:46:44Z 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: | |
4744bd90 | 51 | $(RM) $(OBJS) $(TARGETS) cupsdisable cupsenable reject |
ef416fc2 | 52 | |
53 | ||
54 | # | |
55 | # Update dependencies (without system header dependencies...) | |
56 | # | |
57 | ||
58 | depend: | |
59 | makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1 | |
60 | ||
61 | ||
62 | # | |
63 | # Install all targets... | |
64 | # | |
65 | ||
50fe7201 MS |
66 | install: all install-data install-headers install-libs install-exec |
67 | ||
68 | ||
69 | # | |
70 | # Install data files... | |
71 | # | |
72 | ||
73 | install-data: | |
74 | ||
75 | ||
76 | # | |
77 | # Install programs... | |
78 | # | |
79 | ||
80 | install-exec: | |
bd7854cb | 81 | $(INSTALL_DIR) -m 755 $(SBINDIR) |
ef416fc2 | 82 | $(INSTALL_BIN) accept $(SBINDIR) |
83 | $(RM) $(SBINDIR)/reject | |
84 | $(LN) accept $(SBINDIR)/reject | |
85 | $(INSTALL_BIN) cupsaddsmb $(SBINDIR) | |
bc44d920 | 86 | $(INSTALL_BIN) cupsctl $(SBINDIR) |
ef416fc2 | 87 | $(INSTALL_BIN) lpadmin $(SBINDIR) |
88 | $(INSTALL_BIN) lpinfo $(SBINDIR) | |
89 | $(INSTALL_BIN) lpmove $(SBINDIR) | |
bd7854cb | 90 | $(INSTALL_DIR) -m 755 $(BINDIR) |
ef416fc2 | 91 | $(INSTALL_BIN) cancel $(BINDIR) |
80ca4592 | 92 | $(INSTALL_BIN) cupstestdsc $(BINDIR) |
ef416fc2 | 93 | $(INSTALL_BIN) cupstestppd $(BINDIR) |
923edb68 | 94 | $(RM) $(SBINDIR)/cupsdisable |
95 | $(LN) accept $(SBINDIR)/cupsdisable | |
96 | $(RM) $(SBINDIR)/cupsenable | |
97 | $(LN) accept $(SBINDIR)/cupsenable | |
ef416fc2 | 98 | $(INSTALL_BIN) lp $(BINDIR) |
99 | $(INSTALL_BIN) lpoptions $(BINDIR) | |
100 | $(INSTALL_BIN) lpstat $(BINDIR) | |
568fa3fa | 101 | $(INSTALL_BIN) lppasswd $(BINDIR) |
09a101d6 | 102 | if test "x$(SYMROOT)" != "x"; then \ |
103 | $(INSTALL_DIR) $(SYMROOT); \ | |
104 | for file in $(TARGETS); do \ | |
105 | cp $$file $(SYMROOT); \ | |
106 | done \ | |
107 | fi | |
ef416fc2 | 108 | |
109 | ||
50fe7201 MS |
110 | # |
111 | # Install headers... | |
112 | # | |
113 | ||
114 | install-headers: | |
115 | ||
116 | ||
117 | # | |
118 | # Install libraries... | |
119 | # | |
120 | ||
121 | install-libs: | |
122 | ||
123 | ||
757d2cad | 124 | # |
125 | # Uninstall all targets... | |
126 | # | |
127 | ||
128 | uninstall: | |
129 | $(RM) $(BINDIR)/cancel | |
80ca4592 | 130 | $(RM) $(BINDIR)/cupstestdsc |
757d2cad | 131 | $(RM) $(BINDIR)/cupstestppd |
132 | $(RM) $(BINDIR)/lp | |
133 | $(RM) $(BINDIR)/lpoptions | |
134 | $(RM) $(BINDIR)/lppasswd | |
135 | $(RM) $(BINDIR)/lpstat | |
136 | -$(RMDIR) $(BINDIR) | |
137 | $(RM) $(SBINDIR)/accept | |
138 | $(RM) $(SBINDIR)/cupsaddsmb | |
139 | $(RM) $(SBINDIR)/cupsdisable | |
140 | $(RM) $(SBINDIR)/cupsenable | |
141 | $(RM) $(SBINDIR)/lpadmin | |
142 | $(RM) $(SBINDIR)/lpinfo | |
143 | $(RM) $(SBINDIR)/lpmove | |
144 | $(RM) $(SBINDIR)/reject | |
145 | -$(RMDIR) $(SBINDIR) | |
146 | ||
147 | ||
ef416fc2 | 148 | # |
149 | # accept | |
150 | # | |
151 | ||
152 | accept: accept.o ../cups/$(LIBCUPS) | |
153 | echo Linking $@... | |
154 | $(CC) $(LDFLAGS) -o accept accept.o $(LIBS) | |
4744bd90 | 155 | $(RM) reject cupsenable cupsdisable |
ef416fc2 | 156 | $(LN) accept reject |
4744bd90 | 157 | $(LN) accept cupsenable |
158 | $(LN) accept cupsdisable | |
ef416fc2 | 159 | |
160 | ||
161 | # | |
162 | # cancel | |
163 | # | |
164 | ||
165 | cancel: cancel.o ../cups/$(LIBCUPS) | |
166 | echo Linking $@... | |
167 | $(CC) $(LDFLAGS) -o cancel cancel.o $(LIBS) | |
168 | ||
169 | ||
170 | # | |
171 | # cupsaddsmb | |
172 | # | |
173 | ||
174 | cupsaddsmb: cupsaddsmb.o ../cups/$(LIBCUPS) | |
175 | echo Linking $@... | |
176 | $(CC) $(LDFLAGS) -o cupsaddsmb cupsaddsmb.o $(LIBS) | |
177 | ||
178 | ||
bc44d920 | 179 | # |
180 | # cupsctl | |
181 | # | |
182 | ||
183 | cupsctl: cupsctl.o ../cups/$(LIBCUPS) | |
184 | echo Linking $@... | |
185 | $(CC) $(LDFLAGS) -o cupsctl cupsctl.o $(LIBS) | |
186 | ||
187 | ||
80ca4592 | 188 | # |
189 | # cupstestdsc | |
190 | # | |
191 | ||
192 | cupstestdsc: cupstestdsc.o ../cups/$(LIBCUPS) | |
193 | echo Linking $@... | |
194 | $(CC) $(LDFLAGS) -o $@ cupstestdsc.o $(LIBS) | |
195 | ||
196 | ||
ef416fc2 | 197 | # |
198 | # cupstestppd | |
199 | # | |
200 | ||
09a101d6 | 201 | cupstestppd: cupstestppd.o ../cups/$(LIBCUPS) ../filter/$(LIBCUPSIMAGE) |
ef416fc2 | 202 | echo Linking $@... |
09a101d6 | 203 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o $(LINKCUPSIMAGE) $(IMGLIBS) $(LIBS) |
ef416fc2 | 204 | |
66ab9486 MS |
205 | cupstestppd-static: cupstestppd.o ../cups/libcups.a ../filter/libcupsimage.a |
206 | echo Linking $@... | |
207 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o ../filter/libcupsimage.a \ | |
208 | ../cups/libcups.a $(IMGLIBS) $(LIBGSSAPI) $(LIBS) $(LIBZ) | |
209 | ||
ef416fc2 | 210 | |
211 | # | |
212 | # lp | |
213 | # | |
214 | ||
215 | lp: lp.o ../cups/$(LIBCUPS) | |
216 | echo Linking $@... | |
217 | $(CC) $(LDFLAGS) -o lp lp.o $(LIBS) | |
218 | ||
219 | ||
220 | # | |
221 | # lpadmin | |
222 | # | |
223 | ||
224 | lpadmin: lpadmin.o ../cups/$(LIBCUPS) | |
225 | echo Linking $@... | |
226 | $(CC) $(LDFLAGS) -o lpadmin lpadmin.o $(LIBZ) $(LIBS) | |
227 | ||
228 | ||
229 | # | |
230 | # lpinfo | |
231 | # | |
232 | ||
233 | lpinfo: lpinfo.o ../cups/$(LIBCUPS) | |
234 | echo Linking $@... | |
235 | $(CC) $(LDFLAGS) -o lpinfo lpinfo.o $(LIBS) | |
236 | ||
237 | ||
238 | # | |
239 | # lpmove | |
240 | # | |
241 | ||
242 | lpmove: lpmove.o ../cups/$(LIBCUPS) | |
243 | echo Linking $@... | |
244 | $(CC) $(LDFLAGS) -o lpmove lpmove.o $(LIBS) | |
245 | ||
246 | ||
247 | # | |
248 | # lpoptions | |
249 | # | |
250 | ||
251 | lpoptions: lpoptions.o ../cups/$(LIBCUPS) | |
252 | echo Linking $@... | |
253 | $(CC) $(LDFLAGS) -o lpoptions lpoptions.o $(LIBZ) $(LIBS) | |
254 | ||
255 | ||
256 | # | |
257 | # lppasswd | |
258 | # | |
259 | ||
260 | lppasswd: lppasswd.o ../cups/$(LIBCUPS) | |
261 | echo Linking $@... | |
262 | $(CC) $(LDFLAGS) -o lppasswd lppasswd.o $(LIBZ) $(LIBS) | |
263 | ||
264 | ||
265 | # | |
266 | # lpstat | |
267 | # | |
268 | ||
269 | lpstat: lpstat.o ../cups/$(LIBCUPS) | |
270 | echo Linking $@... | |
271 | $(CC) $(LDFLAGS) -o lpstat lpstat.o $(LIBS) | |
272 | ||
273 | ||
274 | # | |
275 | # Dependencies... | |
276 | # | |
277 | ||
278 | include Dependencies | |
279 | ||
280 | ||
281 | # | |
75bd9771 | 282 | # End of "$Id: Makefile 7558 2008-05-12 23:46:44Z mike $". |
ef416fc2 | 283 | # |