]> sjero.net Git - wget/blob - src/Makefile.in
[svn] Initial revision
[wget] / src / Makefile.in
1 # Makefile for `wget' utility
2 # Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
3
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 2 of the License, or
7 # (at your option) any later version.
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17
18 #
19 # Version: @VERSION@
20 #
21
22 SHELL = /bin/sh
23
24 top_srcdir = @top_srcdir@
25 srcdir     = @srcdir@
26 VPATH      = @srcdir@
27 ANSI2KNR = @ANSI2KNR@
28 o = .@U@o
29
30 prefix       = @prefix@
31 exec_prefix  = @exec_prefix@
32 bindir       = @bindir@
33 sysconfdir   = @sysconfdir@
34 localedir    = $(prefix)/share/locale
35
36 CC       = @CC@
37 CPPFLAGS = @CPPFLAGS@
38 # The following line is losing on some versions of make!
39 DEFS     = @DEFS@ -DSYSTEM_WGETRC=\"$(sysconfdir)/wgetrc\" -DLOCALEDIR=\"$(localedir)\"
40 CFLAGS   = @CFLAGS@
41 LDFLAGS  = @LDFLAGS@
42 LIBS     = @LIBS@
43 exeext   = @exeext@
44
45 INCLUDES = -I. -I$(srcdir)
46
47 COMPILE = $(CC) $(INCLUDES) $(CPPFLAGS)  $(DEFS) $(CFLAGS)
48 LINK    = $(CC) $(CFLAGS) $(LDFLAGS) -o $@
49 INSTALL = @INSTALL@
50 INSTALL_PROGRAM = @INSTALL_PROGRAM@
51 RM = rm -f
52 ETAGS = etags
53
54 # Conditional compiles
55 ALLOCA = @ALLOCA@
56 MD5_OBJ = @MD5_OBJ@
57 OPIE_OBJ = @OPIE_OBJ@
58
59 OBJ = $(ALLOCA) cmpt$o connect$o fnmatch$o ftp$o ftp-basic$o  \
60       ftp-ls$o $(OPIE_OBJ) getopt$o headers$o host$o html$o   \
61       http$o init$o log$o main$o $(MD5_OBJ) netrc$o rbuf$o    \
62       recur$o retr$o url$o utils$o version$o
63
64 .SUFFIXES:
65 .SUFFIXES: .c .o ._c ._o
66
67 .c.o:
68         $(COMPILE) -c $<
69
70 .c._c: $(ANSI2KNR)
71         $(ANSI2KNR) $< > $*.tmp && mv $*.tmp $@
72
73 ._c._o:
74         @echo $(COMPILE) -c $<
75         @rm -f _$*.c
76         @ln $< _$*.c && $(COMPILE) -c _$*.c && mv _$*.o $@ && rm _$*.c
77
78 .c._o: $(ANSI2KNR)
79         $(ANSI2KNR) $< > $*.tmp && mv $*.tmp $*._c
80         @echo $(COMPILE) -c $*._c
81         @rm -f _$*.c
82         @ln $*._c _$*.c && $(COMPILE) -c _$*.c && mv _$*.o $@ && rm _$*.c
83
84 # Dependencies for building
85
86 wget$(exeext): $(OBJ)
87         $(LINK) $(OBJ) $(LIBS)
88
89 ansi2knr: ansi2knr.o
90         $(CC) -o ansi2knr ansi2knr.o $(LIBS)
91
92 $(OBJ): $(ANSI2KNR)
93
94 #
95 # Dependencies for installing
96 #
97
98 install: install.bin
99
100 uninstall: uninstall.bin
101
102 install.bin: wget$(exeext)
103         $(top_srcdir)/mkinstalldirs $(bindir)
104         $(INSTALL_PROGRAM) wget$(exeext) $(bindir)/wget$(exeext)
105
106 uninstall.bin:
107         $(RM) $(bindir)/wget$(exeext)
108
109 #
110 # Dependencies for cleanup
111 #
112
113 clean:
114         $(RM) *.o wget$(exeext) *~ *.bak core $(ANSI2KNR) *._o *._c
115
116 distclean: clean
117         $(RM) Makefile config.h
118
119 realclean: distclean
120         $(RM) TAGS
121
122 #
123 # Dependencies for maintenance
124 #
125
126 subdir = src
127
128 Makefile: Makefile.in ../config.status
129         cd .. && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= ./config.status
130
131 TAGS: *.c *.h
132         -$(ETAGS) *.c *.h
133
134 # DO NOT DELETE THIS LINE -- make depend depends on it.
135
136 cmpt$o: config.h wget.h sysdep.h options.h
137 connect$o: config.h wget.h sysdep.h options.h connect.h host.h
138 fnmatch$o: config.h wget.h sysdep.h options.h fnmatch.h
139 ftp-basic$o: config.h wget.h sysdep.h options.h utils.h rbuf.h connect.h host.h
140 ftp-ls$o: config.h wget.h sysdep.h options.h utils.h ftp.h rbuf.h
141 ftp-opie$o: config.h wget.h sysdep.h options.h md5.h
142 ftp$o: config.h wget.h sysdep.h options.h utils.h url.h rbuf.h retr.h ftp.h html.h connect.h host.h fnmatch.h netrc.h
143 getopt$o: wget.h sysdep.h options.h
144 headers$o: config.h wget.h sysdep.h options.h connect.h rbuf.h headers.h
145 host$o: config.h wget.h sysdep.h options.h utils.h host.h url.h
146 html$o: config.h wget.h sysdep.h options.h url.h utils.h ftp.h rbuf.h html.h
147 http$o: config.h wget.h sysdep.h options.h utils.h url.h host.h rbuf.h retr.h headers.h connect.h fnmatch.h netrc.h
148 init$o: config.h wget.h sysdep.h options.h utils.h init.h host.h recur.h netrc.h
149 log$o: config.h wget.h sysdep.h options.h utils.h
150 main$o: config.h wget.h sysdep.h options.h utils.h getopt.h init.h retr.h rbuf.h recur.h host.h
151 md5$o: wget.h sysdep.h options.h md5.h
152 mswindows$o: config.h winsock.h wget.h sysdep.h options.h url.h
153 netrc$o: wget.h sysdep.h options.h utils.h netrc.h init.h
154 rbuf$o: config.h wget.h sysdep.h options.h rbuf.h connect.h
155 recur$o: config.h wget.h sysdep.h options.h url.h recur.h utils.h retr.h rbuf.h ftp.h fnmatch.h host.h
156 retr$o: config.h wget.h sysdep.h options.h utils.h retr.h rbuf.h url.h recur.h ftp.h host.h connect.h
157 url$o: config.h wget.h sysdep.h options.h utils.h url.h host.h html.h
158 utils$o: config.h wget.h sysdep.h options.h utils.h fnmatch.h