]>
Commit | Line | Data |
---|---|---|
bd7854cb | 1 | # |
503b54c9 | 2 | # Port monitor makefile for CUPS. |
bd7854cb | 3 | # |
a621d151 | 4 | # Copyright 2007-2017 by Apple Inc. |
503b54c9 | 5 | # Copyright 2006 by Easy Software Products. |
bd7854cb | 6 | # |
e3101897 | 7 | # Licensed under Apache License v2.0. See the file "LICENSE" for more information. |
bd7854cb | 8 | # |
9 | ||
10 | include ../Makedefs | |
11 | ||
12 | TARGETS = bcp tbcp | |
13 | ||
14 | OBJS = bcp.o tbcp.o | |
15 | ||
16 | ||
17 | # | |
18 | # Make all targets... | |
19 | # | |
20 | ||
21 | all: $(TARGETS) | |
22 | ||
23 | ||
c9fc04c6 MS |
24 | # |
25 | # Make library targets... | |
26 | # | |
27 | ||
28 | libs: | |
29 | ||
30 | ||
5f64df29 MS |
31 | # |
32 | # Make unit tests... | |
33 | # | |
34 | ||
35 | unittests: | |
36 | ||
37 | ||
bd7854cb | 38 | # |
39 | # Clean all object files... | |
40 | # | |
41 | ||
42 | clean: | |
43 | $(RM) $(OBJS) $(TARGETS) | |
44 | ||
45 | ||
46 | # | |
47 | # Update dependencies (without system header dependencies...) | |
48 | # | |
49 | ||
50 | depend: | |
12f89d24 | 51 | $(CC) -MM $(ALL_CFLAGS) $(OBJS:.o=.c) >Dependencies |
bd7854cb | 52 | |
53 | ||
54 | # | |
55 | # Install all targets... | |
56 | # | |
57 | ||
50fe7201 MS |
58 | install: all install-data install-headers install-libs install-exec |
59 | ||
60 | ||
61 | # | |
62 | # Install data files... | |
63 | # | |
64 | ||
65 | install-data: | |
66 | ||
67 | ||
68 | # | |
69 | # Install programs... | |
70 | # | |
71 | ||
72 | install-exec: | |
bd7854cb | 73 | $(INSTALL_DIR) -m 755 $(SERVERBIN)/monitor |
74 | for file in $(TARGETS); do \ | |
75 | $(INSTALL_BIN) $$file $(SERVERBIN)/monitor; \ | |
76 | done | |
09a101d6 | 77 | if test "x$(SYMROOT)" != "x"; then \ |
78 | $(INSTALL_DIR) $(SYMROOT); \ | |
79 | for file in $(TARGETS); do \ | |
80 | cp $$file $(SYMROOT); \ | |
cb7f98ee | 81 | dsymutil $(SYMROOT)/$$file; \ |
09a101d6 | 82 | done \ |
83 | fi | |
bd7854cb | 84 | |
85 | ||
50fe7201 MS |
86 | # |
87 | # Install headers... | |
88 | # | |
89 | ||
90 | install-headers: | |
91 | ||
92 | ||
93 | # | |
94 | # Install libraries... | |
95 | # | |
96 | ||
97 | install-libs: | |
98 | ||
99 | ||
757d2cad | 100 | # |
101 | # Uninstall all targets... | |
102 | # | |
103 | ||
104 | uninstall: | |
105 | for file in $(TARGETS); do \ | |
106 | $(RM) $(SERVERBIN)/monitor/$$file; \ | |
107 | done | |
108 | -$(RMDIR) $(SERVERBIN)/monitor | |
109 | -$(RMDIR) $(SERVERBIN) | |
110 | ||
111 | ||
bd7854cb | 112 | # |
113 | # bcp | |
114 | # | |
115 | ||
116 | bcp: bcp.o ../cups/$(LIBCUPS) | |
117 | echo Linking $@... | |
a621d151 | 118 | $(LD_CC) $(LDFLAGS) -o $@ bcp.o $(LIBS) |
bd7854cb | 119 | |
120 | ||
121 | # | |
122 | # tbcp | |
123 | # | |
124 | ||
125 | tbcp: tbcp.o ../cups/$(LIBCUPS) | |
126 | echo Linking $@... | |
a621d151 | 127 | $(LD_CC) $(LDFLAGS) -o $@ tbcp.o $(LIBS) |
bd7854cb | 128 | |
129 | ||
130 | # | |
131 | # Dependencies... | |
132 | # | |
321d8d57 | 133 | |
bd7854cb | 134 | include Dependencies |