]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | # |
1a18c85c | 2 | # "$Id: Makefile 11776 2014-03-28 19:16:05Z msweet $" |
ef416fc2 | 3 | # |
1a18c85c | 4 | # System V commands makefile for CUPS. |
ef416fc2 | 5 | # |
1a18c85c MS |
6 | # Copyright 2007-2014 by Apple Inc. |
7 | # Copyright 1997-2006 by Easy Software Products, all rights reserved. | |
ef416fc2 | 8 | # |
1a18c85c MS |
9 | # These coded instructions, statements, and computer programs are the |
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 | ||
1f6f3dbc | 18 | TARGETS = cancel cupsaccept cupsaddsmb cupsctl cupstestdsc cupstestppd \ |
1a18c85c | 19 | lp lpadmin lpinfo lpmove lpoptions lpstat |
1f6f3dbc | 20 | OBJS = cancel.o cupsaccept.o cupsaddsmb.o cupsctl.o cupstestdsc.o \ |
bc44d920 | 21 | cupstestppd.o lp.o lpadmin.o lpinfo.o lpmove.o lpoptions.o \ |
1a18c85c | 22 | 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 | 51 | $(RM) $(OBJS) $(TARGETS) |
f11a948a | 52 | $(RM) accept cupsdisable cupsenable cupsreject reject |
ef416fc2 | 53 | |
54 | ||
55 | # | |
56 | # Update dependencies (without system header dependencies...) | |
57 | # | |
58 | ||
59 | depend: | |
12f89d24 | 60 | $(CC) -MM $(ALL_CFLAGS) $(OBJS:.o=.c) >Dependencies |
ef416fc2 | 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: | |
e07d4801 | 82 | echo Installing System V admin printing commands in $(SBINDIR) |
bd7854cb | 83 | $(INSTALL_DIR) -m 755 $(SBINDIR) |
e07d4801 | 84 | $(INSTALL_BIN) cupsaccept $(SBINDIR) |
ef416fc2 | 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) | |
e07d4801 MS |
90 | $(RM) $(SBINDIR)/accept |
91 | $(LN) cupsaccept $(SBINDIR)/accept | |
92 | $(RM) $(SBINDIR)/cupsdisable | |
93 | $(LN) cupsaccept $(SBINDIR)/cupsdisable | |
94 | $(RM) $(SBINDIR)/cupsenable | |
95 | $(LN) cupsaccept $(SBINDIR)/cupsenable | |
96 | $(RM) $(SBINDIR)/cupsreject | |
97 | $(LN) cupsaccept $(SBINDIR)/cupsreject | |
98 | $(RM) $(SBINDIR)/reject | |
99 | $(LN) cupsaccept $(SBINDIR)/reject | |
100 | echo Installing System V user printing commands in $(BINDIR) | |
bd7854cb | 101 | $(INSTALL_DIR) -m 755 $(BINDIR) |
ef416fc2 | 102 | $(INSTALL_BIN) cancel $(BINDIR) |
80ca4592 | 103 | $(INSTALL_BIN) cupstestdsc $(BINDIR) |
ef416fc2 | 104 | $(INSTALL_BIN) cupstestppd $(BINDIR) |
ef416fc2 | 105 | $(INSTALL_BIN) lp $(BINDIR) |
106 | $(INSTALL_BIN) lpoptions $(BINDIR) | |
107 | $(INSTALL_BIN) lpstat $(BINDIR) | |
09a101d6 | 108 | if test "x$(SYMROOT)" != "x"; then \ |
109 | $(INSTALL_DIR) $(SYMROOT); \ | |
110 | for file in $(TARGETS); do \ | |
111 | cp $$file $(SYMROOT); \ | |
c1420c87 | 112 | dsymutil $(SYMROOT)/$$file; \ |
09a101d6 | 113 | done \ |
114 | fi | |
ef416fc2 | 115 | |
116 | ||
50fe7201 MS |
117 | # |
118 | # Install headers... | |
119 | # | |
120 | ||
121 | install-headers: | |
122 | ||
123 | ||
124 | # | |
125 | # Install libraries... | |
126 | # | |
127 | ||
128 | install-libs: | |
129 | ||
130 | ||
757d2cad | 131 | # |
132 | # Uninstall all targets... | |
133 | # | |
134 | ||
135 | uninstall: | |
136 | $(RM) $(BINDIR)/cancel | |
80ca4592 | 137 | $(RM) $(BINDIR)/cupstestdsc |
757d2cad | 138 | $(RM) $(BINDIR)/cupstestppd |
139 | $(RM) $(BINDIR)/lp | |
140 | $(RM) $(BINDIR)/lpoptions | |
757d2cad | 141 | $(RM) $(BINDIR)/lpstat |
142 | -$(RMDIR) $(BINDIR) | |
143 | $(RM) $(SBINDIR)/accept | |
e07d4801 | 144 | $(RM) $(SBINDIR)/cupsaccept |
757d2cad | 145 | $(RM) $(SBINDIR)/cupsaddsmb |
49d87452 | 146 | $(RM) $(SBINDIR)/cupsaccept |
757d2cad | 147 | $(RM) $(SBINDIR)/cupsdisable |
148 | $(RM) $(SBINDIR)/cupsenable | |
49d87452 | 149 | $(RM) $(SBINDIR)/cupsreject |
757d2cad | 150 | $(RM) $(SBINDIR)/lpadmin |
151 | $(RM) $(SBINDIR)/lpinfo | |
152 | $(RM) $(SBINDIR)/lpmove | |
153 | $(RM) $(SBINDIR)/reject | |
154 | -$(RMDIR) $(SBINDIR) | |
155 | ||
156 | ||
ef416fc2 | 157 | # |
1f6f3dbc | 158 | # cancel |
ef416fc2 | 159 | # |
160 | ||
1f6f3dbc | 161 | cancel: cancel.o ../cups/$(LIBCUPS) |
ef416fc2 | 162 | echo Linking $@... |
1f6f3dbc | 163 | $(CC) $(LDFLAGS) -o cancel cancel.o $(LIBS) |
ef416fc2 | 164 | |
165 | ||
166 | # | |
1f6f3dbc | 167 | # cupsaccept |
ef416fc2 | 168 | # |
169 | ||
1f6f3dbc | 170 | cupsaccept: cupsaccept.o ../cups/$(LIBCUPS) |
ef416fc2 | 171 | echo Linking $@... |
1f6f3dbc | 172 | $(CC) $(LDFLAGS) -o cupsaccept cupsaccept.o $(LIBS) |
f11a948a | 173 | for file in accept cupsenable cupsdisable cupsreject reject; do \ |
1f6f3dbc MS |
174 | $(RM) $$file; \ |
175 | $(LN) cupsaccept $$file; \ | |
176 | done | |
ef416fc2 | 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 $@... |
83e08001 | 212 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o $(LINKCUPSIMAGE) $(IMGLIBS) $(LIBS) |
ef416fc2 | 213 | |
f8b3a85b | 214 | cupstestppd-static: cupstestppd.o ../cups/$(LIBCUPSSTATIC) ../filter/libcupsimage.a |
66ab9486 MS |
215 | echo Linking $@... |
216 | $(CC) $(LDFLAGS) -o $@ cupstestppd.o ../filter/libcupsimage.a \ | |
f8b3a85b | 217 | ../cups/$(LIBCUPSSTATIC) $(IMGLIBS) $(LIBGSSAPI) $(LIBS) $(LIBZ) |
66ab9486 | 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 | ||
ef416fc2 | 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 | # | |
1a18c85c | 282 | # End of "$Id: Makefile 11776 2014-03-28 19:16:05Z msweet $". |
ef416fc2 | 283 | # |