]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | # |
f2d18633 | 2 | # "$Id$" |
ef416fc2 | 3 | # |
f8b3a85b | 4 | # API library Makefile for CUPS. |
ef416fc2 | 5 | # |
cb7f98ee | 6 | # Copyright 2007-2013 by Apple Inc. |
ef416fc2 | 7 | # Copyright 1997-2006 by Easy Software Products, all rights reserved. |
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 | # This file is subject to the Apple OS-Developed Software exception. | |
16 | # | |
17 | ||
18 | include ../Makedefs | |
19 | ||
cb7f98ee MS |
20 | |
21 | # | |
22 | # Options to build libcups without the use of deprecated APIs... | |
23 | # | |
24 | ||
25 | OPTIONS = -D_CUPS_NO_DEPRECATED=1 -D_PPD_DEPRECATED="" | |
26 | ||
27 | ||
ef416fc2 | 28 | # |
29 | # Object files... | |
30 | # | |
31 | ||
32 | LIBOBJS = \ | |
757d2cad | 33 | adminutil.o \ |
ef416fc2 | 34 | array.o \ |
35 | attr.o \ | |
36 | auth.o \ | |
37 | backchannel.o \ | |
a4d04587 | 38 | backend.o \ |
66ab9486 | 39 | conflicts.o \ |
fa73b229 | 40 | custom.o \ |
ae71f5de | 41 | debug.o \ |
ef416fc2 | 42 | dest.o \ |
dcb445bc MS |
43 | dest-job.o \ |
44 | dest-localization.o \ | |
45 | dest-options.o \ | |
ef416fc2 | 46 | dir.o \ |
47 | emit.o \ | |
48 | encode.o \ | |
49 | file.o \ | |
ae71f5de | 50 | getdevices.o \ |
89d46774 | 51 | getifaddrs.o \ |
ef416fc2 | 52 | getputfile.o \ |
53 | globals.o \ | |
54 | http.o \ | |
55 | http-addr.o \ | |
56 | http-addrlist.o \ | |
57 | http-support.o \ | |
58 | ipp.o \ | |
59 | ipp-support.o \ | |
60 | langprintf.o \ | |
61 | language.o \ | |
fa73b229 | 62 | localize.o \ |
ef416fc2 | 63 | mark.o \ |
64 | md5.o \ | |
65 | md5passwd.o \ | |
fa73b229 | 66 | notify.o \ |
ef416fc2 | 67 | options.o \ |
68 | page.o \ | |
69 | ppd.o \ | |
f14324a7 | 70 | ppd-cache.o \ |
54afec33 | 71 | pwg-media.o \ |
ecdc0628 | 72 | request.o \ |
f7deaa1a | 73 | sidechannel.o \ |
91c84a35 | 74 | snmp.o \ |
ef416fc2 | 75 | snprintf.o \ |
76 | string.o \ | |
77 | tempfile.o \ | |
6d2f911b | 78 | thread.o \ |
ef416fc2 | 79 | transcode.o \ |
80 | usersys.o \ | |
81 | util.o | |
dcb445bc | 82 | TESTOBJS = \ |
757d2cad | 83 | testadmin.o \ |
ef416fc2 | 84 | testarray.o \ |
06d4e77b | 85 | testconflicts.o \ |
09a101d6 | 86 | testcups.o \ |
ef416fc2 | 87 | testfile.o \ |
88 | testhttp.o \ | |
89 | testi18n.o \ | |
90 | testipp.o \ | |
20fbc903 | 91 | testoptions.o \ |
ef416fc2 | 92 | testlang.o \ |
fa73b229 | 93 | testppd.o \ |
54afec33 | 94 | testpwg.o \ |
cc754834 | 95 | testsnmp.o |
dcb445bc MS |
96 | OBJS = \ |
97 | $(LIBOBJS) \ | |
dcb445bc MS |
98 | $(TESTOBJS) |
99 | ||
ef416fc2 | 100 | |
101 | # | |
102 | # Header files to install... | |
103 | # | |
104 | ||
105 | HEADERS = \ | |
757d2cad | 106 | adminutil.h \ |
ef416fc2 | 107 | array.h \ |
d09495fa | 108 | backend.h \ |
ef416fc2 | 109 | cups.h \ |
110 | dir.h \ | |
111 | file.h \ | |
112 | http.h \ | |
ef416fc2 | 113 | ipp.h \ |
114 | language.h \ | |
ef416fc2 | 115 | ppd.h \ |
6961465f | 116 | pwg.h \ |
ac884b6a | 117 | raster.h \ |
f7deaa1a | 118 | sidechannel.h \ |
a41f09e2 MS |
119 | transcode.h \ |
120 | versioning.h | |
ef416fc2 | 121 | |
71e16022 | 122 | HEADERSPRIV = \ |
eac3a0a0 | 123 | array-private.h \ |
71e16022 MS |
124 | cups-private.h \ |
125 | debug-private.h \ | |
126 | file-private.h \ | |
127 | http-private.h \ | |
128 | ipp-private.h \ | |
129 | language-private.h \ | |
130 | md5-private.h \ | |
131 | ppd-private.h \ | |
132 | pwg-private.h \ | |
a4845881 | 133 | raster-private.h \ |
71e16022 | 134 | snmp-private.h \ |
6d2f911b MS |
135 | string-private.h \ |
136 | thread-private.h | |
137 | ||
ef416fc2 | 138 | |
139 | # | |
140 | # Targets in this directory... | |
141 | # | |
142 | ||
c9fc04c6 | 143 | LIBTARGETS = \ |
f8b3a85b | 144 | $(LIBCUPSSTATIC) \ |
12f89d24 | 145 | $(LIBCUPS) |
5f64df29 MS |
146 | |
147 | UNITTARGETS = \ | |
148 | testadmin \ | |
ef416fc2 | 149 | testarray \ |
5f64df29 MS |
150 | testconflicts \ |
151 | testcups \ | |
ef416fc2 | 152 | testfile \ |
153 | testhttp \ | |
154 | testi18n \ | |
155 | testipp \ | |
fa73b229 | 156 | testlang \ |
20fbc903 | 157 | testoptions \ |
5f64df29 | 158 | testppd \ |
54afec33 | 159 | testpwg \ |
5f64df29 | 160 | testsnmp |
c9fc04c6 MS |
161 | |
162 | TARGETS = \ | |
5f64df29 | 163 | $(LIBTARGETS) |
ef416fc2 | 164 | |
165 | ||
166 | # | |
167 | # Make all targets... | |
168 | # | |
169 | ||
f8b3a85b | 170 | all: $(TARGETS) |
ef416fc2 | 171 | |
172 | ||
c9fc04c6 MS |
173 | # |
174 | # Make library targets... | |
175 | # | |
176 | ||
177 | libs: $(LIBTARGETS) | |
178 | ||
179 | ||
5f64df29 MS |
180 | # |
181 | # Make unit tests... | |
182 | # | |
183 | ||
184 | unittests: $(UNITTARGETS) | |
185 | ||
186 | ||
ef416fc2 | 187 | # |
188 | # Remove object and target files... | |
189 | # | |
190 | ||
191 | clean: | |
5f64df29 | 192 | $(RM) $(OBJS) $(TARGETS) $(UNITTARGETS) |
f301802f | 193 | $(RM) libcups.so libcups.sl libcups.dylib |
ef416fc2 | 194 | |
195 | ||
196 | # | |
197 | # Update dependencies (without system header dependencies...) | |
198 | # | |
199 | ||
200 | depend: | |
12f89d24 | 201 | $(CC) -MM $(ALL_CFLAGS) $(OBJS:.o=.c) >Dependencies |
ef416fc2 | 202 | |
203 | ||
6961465f MS |
204 | # |
205 | # Run oclint to check code coverage... | |
206 | # | |
207 | ||
208 | oclint: | |
209 | oclint -o=oclint.html -html $(LIBOBJS:.o=.c) -- $(ALL_CFLAGS) | |
210 | ||
211 | ||
ef416fc2 | 212 | # |
50fe7201 | 213 | # Install all targets... |
ef416fc2 | 214 | # |
215 | ||
50fe7201 MS |
216 | install: all install-data install-headers install-libs install-exec |
217 | ||
218 | ||
219 | # | |
220 | # Install data files... | |
221 | # | |
222 | ||
223 | install-data: | |
224 | ||
225 | ||
226 | # | |
227 | # Install programs... | |
228 | # | |
229 | ||
230 | install-exec: | |
231 | ||
232 | ||
233 | # | |
234 | # Install headers... | |
235 | # | |
236 | ||
237 | install-headers: | |
238 | echo Installing header files into $(INCLUDEDIR)/cups... | |
239 | $(INSTALL_DIR) -m 755 $(INCLUDEDIR)/cups | |
240 | for file in $(HEADERS); do \ | |
241 | $(INSTALL_DATA) $$file $(INCLUDEDIR)/cups; \ | |
242 | done | |
71e16022 MS |
243 | if test "x$(privateinclude)" != x; then \ |
244 | echo Installing private header files into $(PRIVATEINCLUDE)...; \ | |
5180a04c | 245 | $(INSTALL_DIR) -m 755 $(PRIVATEINCLUDE); \ |
71e16022 | 246 | for file in $(HEADERSPRIV); do \ |
5180a04c | 247 | $(INSTALL_DATA) $$file $(PRIVATEINCLUDE)/$$file; \ |
71e16022 MS |
248 | done; \ |
249 | fi | |
50fe7201 MS |
250 | |
251 | ||
252 | # | |
253 | # Install libraries... | |
254 | # | |
255 | ||
12f89d24 | 256 | install-libs: $(INSTALLSTATIC) |
50fe7201 | 257 | echo Installing libraries in $(LIBDIR)... |
bd7854cb | 258 | $(INSTALL_DIR) -m 755 $(LIBDIR) |
ef416fc2 | 259 | $(INSTALL_LIB) $(LIBCUPS) $(LIBDIR) |
260 | if test $(LIBCUPS) = "libcups.so.2" -o $(LIBCUPS) = "libcups.sl.2"; then \ | |
261 | $(RM) $(LIBDIR)/`basename $(LIBCUPS) .2`; \ | |
262 | $(LN) $(LIBCUPS) $(LIBDIR)/`basename $(LIBCUPS) .2`; \ | |
263 | fi | |
264 | if test $(LIBCUPS) = "libcups.2.dylib"; then \ | |
ef416fc2 | 265 | $(RM) $(LIBDIR)/libcups.dylib; \ |
266 | $(LN) $(LIBCUPS) $(LIBDIR)/libcups.dylib; \ | |
267 | fi | |
09a101d6 | 268 | if test "x$(SYMROOT)" != "x"; then \ |
269 | $(INSTALL_DIR) $(SYMROOT); \ | |
50fe7201 | 270 | cp $(LIBCUPS) $(SYMROOT); \ |
c1420c87 | 271 | dsymutil $(SYMROOT)/$(LIBCUPS); \ |
09a101d6 | 272 | fi |
923edb68 | 273 | |
274 | installstatic: | |
275 | $(INSTALL_DIR) -m 755 $(LIBDIR) | |
f8b3a85b MS |
276 | $(INSTALL_LIB) -m 755 $(LIBCUPSSTATIC) $(LIBDIR) |
277 | $(RANLIB) $(LIBDIR)/$(LIBCUPSSTATIC) | |
278 | $(CHMOD) 555 $(LIBDIR)/$(LIBCUPSSTATIC) | |
ef416fc2 | 279 | |
ef416fc2 | 280 | |
757d2cad | 281 | # |
282 | # Uninstall object and target files... | |
283 | # | |
284 | ||
12f89d24 | 285 | uninstall: |
757d2cad | 286 | $(RM) $(LIBDIR)/libcups.2.dylib |
6d2f911b | 287 | $(RM) $(LIBDIR)/$(LIBCUPSSTATIC) |
757d2cad | 288 | $(RM) $(LIBDIR)/libcups.dylib |
289 | $(RM) $(LIBDIR)/libcups_s.a | |
290 | $(RM) $(LIBDIR)/libcups.sl | |
291 | $(RM) $(LIBDIR)/libcups.sl.2 | |
292 | $(RM) $(LIBDIR)/libcups.so | |
293 | $(RM) $(LIBDIR)/libcups.so.2 | |
294 | -$(RMDIR) $(LIBDIR) | |
295 | for file in $(HEADERS); do \ | |
296 | $(RM) $(INCLUDEDIR)/cups/$$file; \ | |
297 | done | |
298 | -$(RMDIR) $(INCLUDEDIR)/cups | |
299 | ||
300 | ||
ef416fc2 | 301 | # |
302 | # libcups.so.2, libcups.sl.2 | |
303 | # | |
304 | ||
305 | libcups.so.2 libcups.sl.2: $(LIBOBJS) | |
306 | echo Linking $@... | |
c168a833 MS |
307 | $(DSO) $(ARCHFLAGS) $(DSOFLAGS) -o $@ $(LIBOBJS) $(LIBGSSAPI) \ |
308 | $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) | |
ef416fc2 | 309 | $(RM) `basename $@ .2` |
310 | $(LN) $@ `basename $@ .2` | |
311 | ||
312 | ||
313 | # | |
314 | # libcups.2.dylib | |
315 | # | |
316 | ||
f8b3a85b MS |
317 | libcups.2.dylib: $(LIBOBJS) $(LIBCUPSORDER) |
318 | echo Creating export list for $@... | |
319 | nm $(LIBOBJS) 2>/dev/null | grep "T _" | awk '{print $$3}' | \ | |
cc754834 | 320 | grep -v -e '^(_cupsConnect|_cupsCharset|_cupsEncodingName|_cupsSetDefaults|_cupsSetHTTPError|_cupsUserDefault|_httpWait)$$' | \ |
f8b3a85b | 321 | sort >t.exp |
ef416fc2 | 322 | echo Linking $@... |
e1d6a774 | 323 | $(DSO) $(ARCHFLAGS) $(DSOFLAGS) -o $@ \ |
fa73b229 | 324 | -install_name $(libdir)/$@ \ |
37e7e6e0 | 325 | -current_version 2.10.0 \ |
ef416fc2 | 326 | -compatibility_version 2.0.0 \ |
f8b3a85b | 327 | -exported_symbols_list t.exp \ |
c168a833 MS |
328 | $(LIBOBJS) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \ |
329 | $(COMMONLIBS) $(LIBZ) | |
f8b3a85b | 330 | $(RM) libcups.dylib t.exp |
ef416fc2 | 331 | $(LN) $@ libcups.dylib |
332 | ||
333 | ||
334 | # | |
335 | # libcups_s.a | |
336 | # | |
337 | ||
a74454a7 | 338 | libcups_s.a: $(LIBOBJS) libcups_s.exp |
ef416fc2 | 339 | echo Creating $@... |
c168a833 MS |
340 | $(DSO) $(DSOFLAGS) -Wl,-bexport:libcups_s.exp -o libcups_s.o \ |
341 | $(LIBOBJS) $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) \ | |
83e08001 | 342 | $(COMMONLIBS) $(LIBZ) |
ef416fc2 | 343 | $(RM) $@ |
344 | $(AR) $(ARFLAGS) $@ libcups_s.o | |
345 | ||
346 | ||
347 | # | |
348 | # libcups.la | |
349 | # | |
350 | ||
351 | libcups.la: $(LIBOBJS) | |
352 | echo Linking $@... | |
c168a833 | 353 | $(CC) $(ARCHFLAGS) $(DSOFLAGS) -o $@ $(LIBOBJS:.o=.lo) \ |
37e7e6e0 | 354 | -rpath $(LIBDIR) -version-info 2:10 $(LIBGSSAPI) $(SSLLIBS) \ |
c168a833 | 355 | $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
ef416fc2 | 356 | |
357 | ||
358 | # | |
359 | # libcups.a | |
360 | # | |
361 | ||
362 | libcups.a: $(LIBOBJS) | |
363 | echo Archiving $@... | |
364 | $(RM) $@ | |
365 | $(AR) $(ARFLAGS) $@ $(LIBOBJS) | |
366 | $(RANLIB) $@ | |
367 | ||
368 | ||
757d2cad | 369 | # |
370 | # testadmin (dependency on static CUPS library is intentional) | |
371 | # | |
372 | ||
f8b3a85b | 373 | testadmin: testadmin.o $(LIBCUPSSTATIC) |
757d2cad | 374 | echo Linking $@... |
f8b3a85b | 375 | $(CC) $(LDFLAGS) -o $@ testadmin.o $(LIBCUPSSTATIC) \ |
c168a833 | 376 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
757d2cad | 377 | |
378 | ||
ef416fc2 | 379 | # |
380 | # testarray (dependency on static CUPS library is intentional) | |
381 | # | |
382 | ||
f8b3a85b | 383 | testarray: testarray.o $(LIBCUPSSTATIC) |
ef416fc2 | 384 | echo Linking $@... |
f8b3a85b | 385 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testarray.o $(LIBCUPSSTATIC) \ |
c168a833 | 386 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
387 | echo Running array API tests... |
388 | ./testarray | |
ef416fc2 | 389 | |
390 | ||
06d4e77b MS |
391 | # |
392 | # testconflicts (dependency on static CUPS library is intentional) | |
393 | # | |
394 | ||
f8b3a85b | 395 | testconflicts: testconflicts.o $(LIBCUPSSTATIC) |
06d4e77b | 396 | echo Linking $@... |
f8b3a85b | 397 | $(CC) $(LDFLAGS) -o $@ testconflicts.o $(LIBCUPSSTATIC) \ |
c168a833 | 398 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
06d4e77b MS |
399 | |
400 | ||
09a101d6 | 401 | # |
402 | # testcups (dependency on static CUPS library is intentional) | |
403 | # | |
404 | ||
f8b3a85b | 405 | testcups: testcups.o $(LIBCUPSSTATIC) |
09a101d6 | 406 | echo Linking $@... |
f8b3a85b | 407 | $(CC) $(LDFLAGS) -o $@ testcups.o $(LIBCUPSSTATIC) \ |
c168a833 | 408 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
09a101d6 | 409 | |
410 | ||
ef416fc2 | 411 | # |
412 | # testfile (dependency on static CUPS library is intentional) | |
413 | # | |
414 | ||
f8b3a85b | 415 | testfile: testfile.o $(LIBCUPSSTATIC) |
ef416fc2 | 416 | echo Linking $@... |
f8b3a85b | 417 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testfile.o $(LIBCUPSSTATIC) \ |
c168a833 | 418 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
419 | echo Running file API tests... |
420 | ./testfile | |
ef416fc2 | 421 | |
422 | ||
423 | # | |
424 | # testhttp (dependency on static CUPS library is intentional) | |
425 | # | |
426 | ||
f8b3a85b | 427 | testhttp: testhttp.o $(LIBCUPSSTATIC) |
ef416fc2 | 428 | echo Linking $@... |
f8b3a85b | 429 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testhttp.o $(LIBCUPSSTATIC) \ |
c168a833 | 430 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
431 | echo Running HTTP API tests... |
432 | ./testhttp | |
ef416fc2 | 433 | |
434 | ||
435 | # | |
436 | # testipp (dependency on static CUPS library is intentional) | |
437 | # | |
438 | ||
f8b3a85b | 439 | testipp: testipp.o $(LIBCUPSSTATIC) |
ef416fc2 | 440 | echo Linking $@... |
f8b3a85b | 441 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testipp.o $(LIBCUPSSTATIC) \ |
c168a833 | 442 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
443 | echo Running IPP API tests... |
444 | ./testipp | |
ef416fc2 | 445 | |
446 | ||
447 | # | |
448 | # testi18n (dependency on static CUPS library is intentional) | |
449 | # | |
450 | ||
f8b3a85b | 451 | testi18n: testi18n.o $(LIBCUPSSTATIC) |
ef416fc2 | 452 | echo Linking $@... |
f8b3a85b | 453 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testi18n.o $(LIBCUPSSTATIC) \ |
c168a833 | 454 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
455 | echo Running internationalization API tests... |
456 | ./testi18n | |
ef416fc2 | 457 | |
458 | ||
459 | # | |
460 | # testlang (dependency on static CUPS library is intentional) | |
461 | # | |
462 | ||
f8b3a85b | 463 | testlang: testlang.o $(LIBCUPSSTATIC) |
ef416fc2 | 464 | echo Linking $@... |
f8b3a85b | 465 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testlang.o $(LIBCUPSSTATIC) \ |
c168a833 | 466 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
467 | echo Running language API tests... |
468 | ./testlang | |
ef416fc2 | 469 | |
470 | ||
20fbc903 MS |
471 | # |
472 | # testoptions (dependency on static CUPS library is intentional) | |
473 | # | |
474 | ||
f8b3a85b | 475 | testoptions: testoptions.o $(LIBCUPSSTATIC) |
20fbc903 | 476 | echo Linking $@... |
f8b3a85b | 477 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testoptions.o $(LIBCUPSSTATIC) \ |
c168a833 | 478 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
20fbc903 MS |
479 | echo Running option API tests... |
480 | ./testoptions | |
481 | ||
482 | ||
fa73b229 | 483 | # |
484 | # testppd (dependency on static CUPS library is intentional) | |
485 | # | |
486 | ||
f8b3a85b | 487 | testppd: testppd.o $(LIBCUPSSTATIC) test.ppd test2.ppd |
fa73b229 | 488 | echo Linking $@... |
f8b3a85b | 489 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testppd.o $(LIBCUPSSTATIC) \ |
c168a833 | 490 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
c9fc04c6 MS |
491 | echo Running PPD API tests... |
492 | ./testppd | |
fa73b229 | 493 | |
494 | ||
54afec33 MS |
495 | # |
496 | # testpwg (dependency on static CUPS library is intentional) | |
497 | # | |
498 | ||
499 | testpwg: testpwg.o $(LIBCUPSSTATIC) test.ppd | |
500 | echo Linking $@... | |
501 | $(CC) $(ARCHFLAGS) $(LDFLAGS) -o $@ testpwg.o $(LIBCUPSSTATIC) \ | |
502 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) | |
503 | echo Running PWG API tests... | |
504 | ./testpwg test.ppd | |
505 | ||
506 | ||
91c84a35 MS |
507 | # |
508 | # testsnmp (dependency on static CUPS library is intentional) | |
509 | # | |
510 | ||
f8b3a85b | 511 | testsnmp: testsnmp.o $(LIBCUPSSTATIC) |
91c84a35 | 512 | echo Linking $@... |
f8b3a85b | 513 | $(CC) $(LDFLAGS) -o $@ testsnmp.o $(LIBCUPSSTATIC) \ |
c168a833 | 514 | $(LIBGSSAPI) $(SSLLIBS) $(DNSSDLIBS) $(COMMONLIBS) $(LIBZ) |
91c84a35 MS |
515 | |
516 | ||
ef416fc2 | 517 | # |
518 | # Automatic API help files... | |
519 | # | |
520 | ||
521 | apihelp: | |
522 | echo Generating CUPS API help files... | |
5a738aea MS |
523 | mxmldoc --section "Programming" \ |
524 | --title "Introduction to CUPS Programming" \ | |
525 | --css ../doc/cups-printable.css \ | |
526 | --header api-overview.header --intro api-overview.shtml \ | |
527 | >../doc/help/api-overview.html | |
ef416fc2 | 528 | mxmldoc --section "Programming" --title "Array API" \ |
5a738aea MS |
529 | --css ../doc/cups-printable.css \ |
530 | --header api-array.header --intro api-array.shtml \ | |
f11a948a | 531 | api-array.xml \ |
ef416fc2 | 532 | array.h array.c >../doc/help/api-array.html |
f11a948a MS |
533 | mxmldoc --tokens help/api-array.html api-array.xml >../doc/help/api-array.tokens |
534 | $(RM) api-array.xml | |
ef416fc2 | 535 | mxmldoc --section "Programming" --title "CUPS API" \ |
5a738aea MS |
536 | --css ../doc/cups-printable.css \ |
537 | --header api-cups.header --intro api-cups.shtml \ | |
f11a948a | 538 | api-cups.xml \ |
6961465f MS |
539 | cups.h pwg.h adminutil.c dest*.c language.c notify.c \ |
540 | options.c pwg-media.c tempfile.c usersys.c \ | |
ef416fc2 | 541 | util.c >../doc/help/api-cups.html |
f11a948a MS |
542 | mxmldoc --tokens help/api-cups.html api-cups.xml >../doc/help/api-cups.tokens |
543 | $(RM) api-cups.xml | |
ef416fc2 | 544 | mxmldoc --section "Programming" --title "File and Directory APIs" \ |
5a738aea MS |
545 | --css ../doc/cups-printable.css \ |
546 | --header api-filedir.header --intro api-filedir.shtml \ | |
f11a948a | 547 | api-filedir.xml \ |
ef416fc2 | 548 | file.h file.c dir.h dir.c >../doc/help/api-filedir.html |
f11a948a MS |
549 | mxmldoc --tokens api-filedir.xml >../doc/help/api-filedir.tokens |
550 | $(RM) api-filedir.xml | |
a2326b5b | 551 | mxmldoc --section "Programming" --title "PPD API (DEPRECATED)" \ |
5a738aea MS |
552 | --css ../doc/cups-printable.css \ |
553 | --header api-ppd.header --intro api-ppd.shtml \ | |
f11a948a | 554 | api-ppd.xml \ |
66ab9486 | 555 | ppd.h attr.c conflicts.c custom.c emit.c localize.c mark.c page.c \ |
ef416fc2 | 556 | ppd.c >../doc/help/api-ppd.html |
f11a948a MS |
557 | mxmldoc --tokens help/api-ppd.html api-ppd.xml >../doc/help/api-ppd.tokens |
558 | $(RM) api-ppd.xml | |
ef416fc2 | 559 | mxmldoc --section "Programming" --title "HTTP and IPP APIs" \ |
5a738aea MS |
560 | --css ../doc/cups-printable.css \ |
561 | --header api-httpipp.header --intro api-httpipp.shtml \ | |
f11a948a | 562 | api-httpipp.xml \ |
ae71f5de MS |
563 | http.h ipp.h auth.c getdevices.c getputfile.c encode.c \ |
564 | http.c http-addr.c http-support.c ipp.c ipp-support.c \ | |
565 | md5passwd.c request.c >../doc/help/api-httpipp.html | |
f11a948a MS |
566 | mxmldoc --tokens help/api-httpipp.html api-httpipp.xml >../doc/help/api-httpipp.tokens |
567 | $(RM) api-httpipp.xml | |
5a738aea MS |
568 | mxmldoc --section "Programming" \ |
569 | --title "Filter and Backend Programming" \ | |
570 | --css ../doc/cups-printable.css \ | |
571 | --header api-filter.header --intro api-filter.shtml \ | |
f11a948a | 572 | api-filter.xml \ |
ac884b6a | 573 | backchannel.c backend.h backend.c sidechannel.c sidechannel.h \ |
7a14d768 | 574 | >../doc/help/api-filter.html |
f11a948a MS |
575 | mxmldoc --tokens help/api-filter.html api-filter.xml >../doc/help/api-filter.tokens |
576 | $(RM) api-filter.xml | |
5a738aea MS |
577 | |
578 | framedhelp: | |
579 | echo Generating CUPS API help files... | |
580 | mxmldoc --framed api-overview \ | |
581 | --section "Programming" \ | |
582 | --title "Introduction to CUPS Programming" \ | |
583 | --css ../doc/cups-printable.css \ | |
584 | --header api-overview.header --intro api-overview.shtml | |
585 | mxmldoc --framed api-array \ | |
586 | --section "Programming" --title "Array API" \ | |
587 | --css ../doc/cups-printable.css \ | |
588 | --header api-array.header --intro api-array.shtml \ | |
589 | array.h array.c | |
590 | mxmldoc --framed api-cups \ | |
591 | --section "Programming" --title "CUPS API" \ | |
592 | --css ../doc/cups-printable.css \ | |
593 | --header api-cups.header --intro api-cups.shtml \ | |
5a9febac | 594 | cups.h adminutil.c dest*.c language.c notify.c \ |
5a738aea | 595 | options.c tempfile.c usersys.c \ |
ac884b6a | 596 | util.c |
5a738aea MS |
597 | mxmldoc --framed api-filedir \ |
598 | --section "Programming" --title "File and Directory APIs" \ | |
599 | --css ../doc/cups-printable.css \ | |
600 | --header api-filedir.header --intro api-filedir.shtml \ | |
ac884b6a | 601 | file.h file.c dir.h dir.c |
5a738aea | 602 | mxmldoc --framed api-ppd \ |
a2326b5b | 603 | --section "Programming" --title "PPD API (DEPRECATED)" \ |
5a738aea MS |
604 | --css ../doc/cups-printable.css \ |
605 | --header api-ppd.header --intro api-ppd.shtml \ | |
66ab9486 MS |
606 | ppd.h attr.c conflicts.c custom.c emit.c localize.c mark.c \ |
607 | page.c ppd.c | |
5a738aea MS |
608 | mxmldoc --framed api-httpipp \ |
609 | --section "Programming" --title "HTTP and IPP APIs" \ | |
610 | --css ../doc/cups-printable.css \ | |
611 | --header api-httpipp.header --intro api-httpipp.shtml \ | |
ae71f5de MS |
612 | http.h ipp.h auth.c getdevices.c getputfile.c encode.c \ |
613 | http.c http-addr.c http-support.c ipp.c ipp-support.c \ | |
614 | md5passwd.c request.c | |
5a738aea MS |
615 | mxmldoc --framed api-filter \ |
616 | --section "Programming" \ | |
617 | --title "Filter and Backend Programming" \ | |
618 | --css ../doc/cups-printable.css \ | |
619 | --header api-filter.header --intro api-filter.shtml \ | |
7a14d768 | 620 | backchannel.c backend.h backend.c sidechannel.c sidechannel.h |
ef416fc2 | 621 | |
622 | ||
84315f46 MS |
623 | # |
624 | # Lines of code computation... | |
625 | # | |
626 | ||
627 | sloc: | |
628 | echo "libcupslite: \c" | |
629 | sloccount $(LITEOBJS:.o=.c) 2>/dev/null | grep "Total Physical" | awk '{print $$9}' | |
630 | echo "libcups: \c" | |
631 | sloccount $(LIBOBJS:.o=.c) 2>/dev/null | grep "Total Physical" | awk '{print $$9}' | |
632 | ||
633 | ||
ef416fc2 | 634 | # |
635 | # Dependencies... | |
636 | # | |
637 | ||
638 | include Dependencies | |
639 | ||
640 | ||
641 | # | |
f2d18633 | 642 | # End of "$Id$". |
ef416fc2 | 643 | # |