]> git.ipfire.org Git - thirdparty/cups.git/blob - backend/Makefile
Load cups into easysw/current.
[thirdparty/cups.git] / backend / Makefile
1 #
2 # "$Id: Makefile 6058 2006-10-23 00:20:09Z mike $"
3 #
4 # Backend makefile for the Common UNIX Printing System (CUPS).
5 #
6 # Copyright 1997-2006 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 = ipp lpd
30 UBACKENDS = $(PAP) parallel scsi 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
75
76 #
77 # Uninstall all targets...
78 #
79
80 uninstall:
81 for file in $(RBACKENDS) $(UBACKENDS); do \
82 $(RM) $(SERVERBIN)/backend/$$file; \
83 done
84 $(RM) $(SERVERBIN)/backend/http
85 -$(RMDIR) $(SERVERBIN)/backend
86 -$(RMDIR) $(SERVERBIN)
87
88
89 #
90 # betest
91 #
92
93 betest: betest.o ../cups/$(LIBCUPS)
94 echo Linking $@...
95 $(CC) $(LDFLAGS) -o betest betest.o $(LIBS)
96
97
98 #
99 # test1284
100 #
101
102 test1284: test1284.o ../cups/libcups.a
103 echo Linking $@...
104 $(CC) $(LDFLAGS) -o test1284 test1284.o ../cups/libcups.a \
105 $(SSLLIBS) $(COMMONLIBS) $(LIBZ)
106
107
108 #
109 # libbackend.a
110 #
111
112 libbackend.a: $(LIBOBJS)
113 echo Archiving $@...
114 $(RM) $@
115 $(AR) $(ARFLAGS) $@ $(LIBOBJS)
116 $(RANLIB) $@
117
118
119 #
120 # ieee1394
121 #
122
123 ieee1394: ieee1394.o ieee1394-linux.o
124 echo Linking $@...
125 $(CC) $(LDFLAGS) -o ieee1394 ieee1394.o ieee1394-linux.o -lraw1394 $(LIBS)
126
127 ieee1394.o: ieee1394.h
128 ieee1394-linux.o: ieee1394.h
129
130
131 #
132 # ipp
133 #
134
135 ipp: ipp.o ../cups/$(LIBCUPS)
136 echo Linking $@...
137 $(CC) $(LDFLAGS) -o ipp ipp.o $(LIBS)
138 $(RM) http
139 $(LN) ipp http
140
141
142 #
143 # lpd
144 #
145
146 lpd: lpd.o ../cups/$(LIBCUPS)
147 echo Linking $@...
148 $(CC) $(LDFLAGS) -o lpd lpd.o $(LIBS)
149
150
151 #
152 # pap
153 #
154
155 pap: pap.o ../cups/$(LIBCUPS)
156 echo Linking $@...
157 $(CC) $(LDFLAGS) -o pap pap.o $(BACKLIBS) $(LIBS) -framework AppleTalk
158
159
160 #
161 # parallel
162 #
163
164 parallel: parallel.o ../cups/$(LIBCUPS) libbackend.a
165 echo Linking $@...
166 $(CC) $(LDFLAGS) -o parallel parallel.o libbackend.a $(LIBS)
167
168
169 #
170 # scsi
171 #
172
173 scsi: scsi.o ../cups/$(LIBCUPS)
174 echo Linking $@...
175 $(CC) $(LDFLAGS) -o scsi scsi.o $(LIBS)
176
177 scsi.o: scsi.c scsi-irix.c scsi-linux.c
178
179
180 #
181 # serial
182 #
183
184 serial: serial.o ../cups/$(LIBCUPS) libbackend.a
185 echo Linking $@...
186 $(CC) $(LDFLAGS) -o serial serial.o libbackend.a $(BACKLIBS) $(LIBS)
187
188
189 #
190 # snmp
191 #
192
193 snmp: snmp.o ../cups/$(LIBCUPS) libbackend.a
194 echo Linking $@...
195 $(CC) $(LDFLAGS) -o snmp snmp.o libbackend.a $(LIBS)
196
197
198 #
199 # socket
200 #
201
202 socket: socket.o ../cups/$(LIBCUPS) libbackend.a
203 echo Linking $@...
204 $(CC) $(LDFLAGS) -o socket socket.o libbackend.a $(LIBS)
205
206
207 #
208 # usb
209 #
210
211 usb: usb.o ../cups/$(LIBCUPS) libbackend.a
212 echo Linking $@...
213 $(CC) $(LDFLAGS) -o usb usb.o libbackend.a $(BACKLIBS) $(LIBS)
214 usb.o: usb.c usb-darwin.c usb-unix.c
215
216
217 #
218 # Dependencies...
219 #
220
221 include Dependencies
222
223
224 #
225 # End of "$Id: Makefile 6058 2006-10-23 00:20:09Z mike $".
226 #