]> git.ipfire.org Git - thirdparty/cups.git/blob - systemv/Makefile
Load cups into easysw/current.
[thirdparty/cups.git] / systemv / Makefile
1 #
2 # "$Id: Makefile 6574 2007-06-19 23:52:37Z mike $"
3 #
4 # System V commands 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
25 include ../Makedefs
26
27 TARGETS = accept cancel cupsaddsmb cupstestdsc cupstestppd \
28 lp lpadmin lpinfo lpmove lpoptions lppasswd lpstat
29 OBJS = accept.o cancel.o cupsaddsmb.o cupstestdsc.o cupstestppd.o \
30 lp.o lpadmin.o lpinfo.o lpmove.o lpoptions.o lppasswd.o \
31 lpstat.o
32
33
34 #
35 # Make all targets...
36 #
37
38 all: $(TARGETS)
39
40
41 #
42 # Clean all object files...
43 #
44
45 clean:
46 $(RM) $(OBJS) $(TARGETS) cupsdisable cupsenable reject
47
48
49 #
50 # Update dependencies (without system header dependencies...)
51 #
52
53 depend:
54 makedepend -Y -I.. -fDependencies $(OBJS:.o=.c) >/dev/null 2>&1
55
56
57 #
58 # Install all targets...
59 #
60
61 install: all
62 $(INSTALL_DIR) -m 755 $(SBINDIR)
63 $(INSTALL_BIN) accept $(SBINDIR)
64 $(RM) $(SBINDIR)/reject
65 $(LN) accept $(SBINDIR)/reject
66 $(INSTALL_BIN) cupsaddsmb $(SBINDIR)
67 $(INSTALL_BIN) lpadmin $(SBINDIR)
68 $(INSTALL_BIN) lpinfo $(SBINDIR)
69 $(INSTALL_BIN) lpmove $(SBINDIR)
70 $(INSTALL_DIR) -m 755 $(BINDIR)
71 $(INSTALL_BIN) cancel $(BINDIR)
72 $(INSTALL_BIN) cupstestdsc $(BINDIR)
73 $(INSTALL_BIN) cupstestppd $(BINDIR)
74 $(RM) $(SBINDIR)/cupsdisable
75 $(LN) accept $(SBINDIR)/cupsdisable
76 $(RM) $(SBINDIR)/cupsenable
77 $(LN) accept $(SBINDIR)/cupsenable
78 $(INSTALL_BIN) lp $(BINDIR)
79 $(INSTALL_BIN) lpoptions $(BINDIR)
80 $(INSTALL_BIN) lpstat $(BINDIR)
81 $(INSTALL_BIN) -m 4755 -o root lppasswd $(BINDIR) || $(INSTALL_BIN) lppasswd $(BINDIR)
82 if test "x$(SYMROOT)" != "x"; then \
83 $(INSTALL_DIR) $(SYMROOT); \
84 for file in $(TARGETS); do \
85 cp $$file $(SYMROOT); \
86 done \
87 fi
88
89
90 #
91 # Uninstall all targets...
92 #
93
94 uninstall:
95 $(RM) $(BINDIR)/cancel
96 $(RM) $(BINDIR)/cupstestdsc
97 $(RM) $(BINDIR)/cupstestppd
98 $(RM) $(BINDIR)/lp
99 $(RM) $(BINDIR)/lpoptions
100 $(RM) $(BINDIR)/lppasswd
101 $(RM) $(BINDIR)/lpstat
102 -$(RMDIR) $(BINDIR)
103 $(RM) $(SBINDIR)/accept
104 $(RM) $(SBINDIR)/cupsaddsmb
105 $(RM) $(SBINDIR)/cupsdisable
106 $(RM) $(SBINDIR)/cupsenable
107 $(RM) $(SBINDIR)/lpadmin
108 $(RM) $(SBINDIR)/lpinfo
109 $(RM) $(SBINDIR)/lpmove
110 $(RM) $(SBINDIR)/reject
111 -$(RMDIR) $(SBINDIR)
112
113
114 #
115 # accept
116 #
117
118 accept: accept.o ../cups/$(LIBCUPS)
119 echo Linking $@...
120 $(CC) $(LDFLAGS) -o accept accept.o $(LIBS)
121 $(RM) reject cupsenable cupsdisable
122 $(LN) accept reject
123 $(LN) accept cupsenable
124 $(LN) accept cupsdisable
125
126
127 #
128 # cancel
129 #
130
131 cancel: cancel.o ../cups/$(LIBCUPS)
132 echo Linking $@...
133 $(CC) $(LDFLAGS) -o cancel cancel.o $(LIBS)
134
135
136 #
137 # cupsaddsmb
138 #
139
140 cupsaddsmb: cupsaddsmb.o ../cups/$(LIBCUPS)
141 echo Linking $@...
142 $(CC) $(LDFLAGS) -o cupsaddsmb cupsaddsmb.o $(LIBS)
143
144
145 #
146 # cupstestdsc
147 #
148
149 cupstestdsc: cupstestdsc.o ../cups/$(LIBCUPS)
150 echo Linking $@...
151 $(CC) $(LDFLAGS) -o $@ cupstestdsc.o $(LIBS)
152
153
154 #
155 # cupstestppd
156 #
157
158 cupstestppd: cupstestppd.o ../cups/$(LIBCUPS) ../filter/$(LIBCUPSIMAGE)
159 echo Linking $@...
160 $(CC) $(LDFLAGS) -o $@ cupstestppd.o $(LINKCUPSIMAGE) $(IMGLIBS) $(LIBS)
161
162
163 #
164 # lp
165 #
166
167 lp: lp.o ../cups/$(LIBCUPS)
168 echo Linking $@...
169 $(CC) $(LDFLAGS) -o lp lp.o $(LIBS)
170
171
172 #
173 # lpadmin
174 #
175
176 lpadmin: lpadmin.o ../cups/$(LIBCUPS)
177 echo Linking $@...
178 $(CC) $(LDFLAGS) -o lpadmin lpadmin.o $(LIBZ) $(LIBS)
179
180
181 #
182 # lpinfo
183 #
184
185 lpinfo: lpinfo.o ../cups/$(LIBCUPS)
186 echo Linking $@...
187 $(CC) $(LDFLAGS) -o lpinfo lpinfo.o $(LIBS)
188
189
190 #
191 # lpmove
192 #
193
194 lpmove: lpmove.o ../cups/$(LIBCUPS)
195 echo Linking $@...
196 $(CC) $(LDFLAGS) -o lpmove lpmove.o $(LIBS)
197
198
199 #
200 # lpoptions
201 #
202
203 lpoptions: lpoptions.o ../cups/$(LIBCUPS)
204 echo Linking $@...
205 $(CC) $(LDFLAGS) -o lpoptions lpoptions.o $(LIBZ) $(LIBS)
206
207
208 #
209 # lppasswd
210 #
211
212 lppasswd: lppasswd.o ../cups/$(LIBCUPS)
213 echo Linking $@...
214 $(CC) $(LDFLAGS) -o lppasswd lppasswd.o $(LIBZ) $(LIBS)
215
216
217 #
218 # lpstat
219 #
220
221 lpstat: lpstat.o ../cups/$(LIBCUPS)
222 echo Linking $@...
223 $(CC) $(LDFLAGS) -o lpstat lpstat.o $(LIBS)
224
225
226 #
227 # Dependencies...
228 #
229
230 include Dependencies
231
232
233 #
234 # End of "$Id: Makefile 6574 2007-06-19 23:52:37Z mike $".
235 #