]> git.ipfire.org Git - thirdparty/cups.git/blob - backend/Makefile
Load cups into easysw/current.
[thirdparty/cups.git] / backend / Makefile
1 #
2 # "$Id: Makefile 6576 2007-06-20 00:23:32Z mike $"
3 #
4 # Backend makefile for the Common UNIX Printing System (CUPS).
5 #
6 # Copyright 1997-2007 by Easy Software Products, all rights reserved.
7 #
8 # These coded instructions, statements, and computer programs are the
9 # property of Easy Software Products and are protected by Federal
10 # copyright law. Distribution and use rights are outlined in the file
11 # "LICENSE.txt" which should have been included with this file. If this
12 # file is missing or damaged please contact Easy Software Products
13 # at:
14 #
15 # Attn: CUPS Licensing Information
16 # Easy Software Products
17 # 44141 Airport View Drive, Suite 204
18 # Hollywood, Maryland 20636 USA
19 #
20 # Voice: (301) 373-9600
21 # EMail: cups-info@cups.org
22 # WWW: http://www.cups.org
23 #
24 # This file is subject to the Apple OS-Developed Software exception.
25 #
26
27 include ../Makedefs
28
29 RBACKENDS = lpd
30 UBACKENDS = ipp $(PAP) $(LEGACY_BACKENDS) serial snmp socket usb
31 TARGETS = betest test1284 libbackend.a $(RBACKENDS) $(UBACKENDS)
32 LIBOBJS = ieee1284.o runloop.o
33 OBJS = betest.o ipp.o lpd.o pap.o parallel.o scsi.o \
34 serial.o snmp.o socket.o test1284.o usb.o
35
36
37 #
38 # Make all targets...
39 #
40
41 all: $(TARGETS)
42
43
44 #
45 # Clean all object files...
46 #
47
48 clean:
49 $(RM) $(OBJS) $(TARGETS) $(LIBOBJS) http
50
51
52 #
53 # Update dependencies (without system header dependencies...)
54 #
55
56 depend:
57 makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1
58
59
60 #
61 # Install all targets...
62 #
63
64 install: all
65 $(INSTALL_DIR) -m 755 $(SERVERBIN)/backend
66 for file in $(RBACKENDS); do \
67 $(LIBTOOL) $(INSTALL) -m 700 $$file $(SERVERBIN)/backend; \
68 done
69 for file in $(UBACKENDS); do \
70 $(INSTALL_BIN) $$file $(SERVERBIN)/backend; \
71 done
72 $(RM) $(SERVERBIN)/backend/http
73 $(LN) ipp $(SERVERBIN)/backend/http
74 if test "x$(SYMROOT)" != "x"; then \
75 $(INSTALL_DIR) $(SYMROOT); \
76 for file in $(TARGETS); do \
77 cp $$file $(SYMROOT); \
78 done \
79 fi
80
81
82 #
83 # Uninstall all targets...
84 #
85
86 uninstall:
87 for file in $(RBACKENDS) $(UBACKENDS); do \
88 $(RM) $(SERVERBIN)/backend/$$file; \
89 done
90 $(RM) $(SERVERBIN)/backend/http
91 -$(RMDIR) $(SERVERBIN)/backend
92 -$(RMDIR) $(SERVERBIN)
93
94
95 #
96 # betest
97 #
98
99 betest: betest.o ../cups/$(LIBCUPS)
100 echo Linking $@...
101 $(CC) $(LDFLAGS) -o betest betest.o $(LIBS)
102
103
104 #
105 # test1284
106 #
107
108 test1284: test1284.o ../cups/libcups.a
109 echo Linking $@...
110 $(CC) $(LDFLAGS) -o test1284 test1284.o ../cups/libcups.a \
111 $(SSLLIBS) $(COMMONLIBS) $(LIBZ)
112
113
114 #
115 # libbackend.a
116 #
117
118 libbackend.a: $(LIBOBJS)
119 echo Archiving $@...
120 $(RM) $@
121 $(AR) $(ARFLAGS) $@ $(LIBOBJS)
122 $(RANLIB) $@
123
124
125 #
126 # ieee1394
127 #
128
129 ieee1394: ieee1394.o ieee1394-linux.o
130 echo Linking $@...
131 $(CC) $(LDFLAGS) -o ieee1394 ieee1394.o ieee1394-linux.o -lraw1394 $(LIBS)
132
133 ieee1394.o: ieee1394.h
134 ieee1394-linux.o: ieee1394.h
135
136
137 #
138 # ipp
139 #
140
141 ipp: ipp.o ../cups/$(LIBCUPS)
142 echo Linking $@...
143 $(CC) $(LDFLAGS) -o ipp ipp.o $(LIBS)
144 $(RM) http
145 $(LN) ipp http
146
147
148 #
149 # lpd
150 #
151
152 lpd: lpd.o ../cups/$(LIBCUPS)
153 echo Linking $@...
154 $(CC) $(LDFLAGS) -o lpd lpd.o $(LIBS)
155
156
157 #
158 # pap
159 #
160
161 pap: pap.o ../cups/$(LIBCUPS)
162 echo Linking $@...
163 $(CC) $(LDFLAGS) -o pap pap.o $(BACKLIBS) $(LIBS) -framework AppleTalk
164
165
166 #
167 # parallel
168 #
169
170 parallel: parallel.o ../cups/$(LIBCUPS) libbackend.a
171 echo Linking $@...
172 $(CC) $(LDFLAGS) -o parallel parallel.o libbackend.a $(LIBS)
173
174
175 #
176 # scsi
177 #
178
179 scsi: scsi.o ../cups/$(LIBCUPS)
180 echo Linking $@...
181 $(CC) $(LDFLAGS) -o scsi scsi.o $(LIBS)
182
183 scsi.o: scsi.c scsi-irix.c scsi-linux.c
184
185
186 #
187 # serial
188 #
189
190 serial: serial.o ../cups/$(LIBCUPS) libbackend.a
191 echo Linking $@...
192 $(CC) $(LDFLAGS) -o serial serial.o libbackend.a $(BACKLIBS) $(LIBS)
193
194
195 #
196 # snmp
197 #
198
199 snmp: snmp.o ../cups/$(LIBCUPS) libbackend.a
200 echo Linking $@...
201 $(CC) $(LDFLAGS) -o snmp snmp.o libbackend.a $(LIBS)
202
203
204 #
205 # socket
206 #
207
208 socket: socket.o ../cups/$(LIBCUPS) libbackend.a
209 echo Linking $@...
210 $(CC) $(LDFLAGS) -o socket socket.o libbackend.a $(LIBS)
211
212
213 #
214 # usb
215 #
216
217 usb: usb.o ../cups/$(LIBCUPS) libbackend.a
218 echo Linking $@...
219 $(CC) $(LDFLAGS) -o usb usb.o libbackend.a $(BACKLIBS) $(LIBS)
220 usb.o: usb.c usb-darwin.c usb-unix.c
221
222
223 #
224 # Dependencies...
225 #
226
227 include Dependencies
228
229
230 #
231 # End of "$Id: Makefile 6576 2007-06-20 00:23:32Z mike $".
232 #