X.25 over TCP support, from Paul Ionescu.
[obnox/wireshark/wip.git] / Makefile.nmake
1 ## Makefile for building ethereal.exe with Microsoft C and nmake
2 ## Use: nmake -f makefile.nmake
3 #
4 # $Id: Makefile.nmake,v 1.68 2000/12/17 07:38:14 guy Exp $
5
6 include config.nmake
7
8 ############### no need to modify below this line #########
9
10 CC = cl
11 LINK= link
12
13 LDFLAGS = /NOLOGO /INCREMENTAL:no /MACHINE:I386 $(LOCAL_LDFLAGS)
14
15 CFLAGS=/MT -DHAVE_CONFIG_H $(LOCAL_CFLAGS) /I$(GLIB_DIR) /I$(GLIB_DIR)\gmodule \
16         /I$(GTK_DIR) /Iepan /Iwiretap /I$(GTK_DIR)\gdk /I$(GTK_DIR)\gdk\win32 \
17         /I$(PCAP_DIR)/include
18
19 {$S}.c{$O}.obj::
20    $(CC) $(CFLAGS) -Fd$O\ -c $<
21
22 DISSECTOR_SOURCES = \
23         packet-aarp.c  \
24         packet-afs.c   \
25         packet-aim.c   \
26         packet-arp.c   \
27         packet-ascend.c\
28         packet-atalk.c \
29         packet-atm.c   \
30         packet-auto_rp.c   \
31         packet-bgp.c   \
32         packet-bootp.c \
33         packet-bootparams.c \
34         packet-bpdu.c  \
35         packet-bxxp.c \
36         packet-cdp.c   \
37         packet-cgmp.c  \
38         packet-clip.c  \
39         packet-clnp.c  \
40         packet-cops.c  \
41         packet-data.c  \
42         packet-ddtp.c  \
43         packet-diameter.c \
44         packet-dns.c   \
45         packet-eigrp.c \
46         packet-esis.c  \
47         packet-eth.c   \
48         packet-ethertype.c   \
49         packet-fddi.c  \
50         packet-frame.c  \
51         packet-ftp.c   \
52         packet-giop.c  \
53         packet-gre.c   \
54         packet-gvrp.c  \
55         packet-h1.c    \
56         packet-h261.c  \
57         packet-hsrp.c  \
58         packet-http.c  \
59         packet-icmpv6.c\
60         packet-icp.c   \
61         packet-icq.c   \
62         packet-igrp.c  \
63         packet-imap.c   \
64         packet-ip.c    \
65         packet-ipp.c   \
66         packet-ipsec.c \
67         packet-ipv6.c  \
68         packet-ipx.c   \
69         packet-irc.c   \
70         packet-ieee80211.c \
71         packet-isakmp.c\
72         packet-isis.c  \
73         packet-isis-clv.c \
74         packet-isis-hello.c \
75         packet-isis-lsp.c \
76         packet-isis-snp.c \
77         packet-isl.c   \
78         packet-kerberos.c \
79         packet-l2tp.c  \
80         packet-lapb.c  \
81         packet-lapd.c  \
82         packet-ldap.c  \
83         packet-ldp.c  \
84         packet-llc.c   \
85         packet-lpd.c   \
86         packet-mapi.c  \
87         packet-mip.c  \
88         packet-mount.c \
89         packet-mpls.c \
90         packet-msproxy.c \
91         packet-nbipx.c \
92         packet-nbns.c  \
93         packet-ncp.c   \
94         packet-ncp2222.c   \
95         packet-netbios.c \
96         packet-nfs.c   \
97         packet-nlm.c   \
98         packet-nntp.c  \
99         packet-ntp.c  \
100         packet-null.c  \
101         packet-osi.c   \
102         packet-osi-options.c \
103         packet-ospf.c  \
104         packet-pim.c   \
105         packet-pop.c   \
106         packet-portmap.c   \
107         packet-ppp.c   \
108         packet-pppoe.c \
109         packet-pptp.c  \
110         packet-q2931.c \
111         packet-q931.c  \
112         packet-quake.c \
113         packet-radius.c\
114         packet-raw.c   \
115         packet-rip.c   \
116         packet-ripng.c \
117         packet-rlogin.c \
118         packet-rpc.c   \
119         packet-rsh.c   \
120         packet-rsvp.c  \
121         packet-rtcp.c  \
122         packet-rtp.c   \
123         packet-rtsp.c  \
124         packet-rx.c  \
125         packet-sap.c   \
126         packet-sctp.c   \
127         packet-sdp.c   \
128         packet-sip.c   \
129         packet-smb.c   \
130         packet-smb-browse.c \
131         packet-smb-common.c \
132         packet-smb-logon.c \
133         packet-smb-mailslot.c \
134         packet-smb-pipe.c \
135         packet-smtp.c \
136         packet-sna.c   \
137         packet-snmp.c   \
138         packet-socks.c \
139         packet-srvloc.c \
140         packet-sscop.c \
141         packet-stat.c   \
142         packet-syslog.c \
143         packet-tacacs.c \
144         packet-tcp.c   \
145         packet-telnet.c\
146         packet-tftp.c  \
147         packet-time.c  \
148         packet-tns.c \
149         packet-tpkt.c  \
150         packet-tr.c    \
151         packet-trmac.c \
152         packet-udp.c   \
153         packet-v120.c \
154         packet-vines.c \
155         packet-vlan.c \
156         packet-vrrp.c \
157         packet-vtp.c  \
158         packet-wccp.c \
159         packet-who.c  \
160         packet-wsp.c \
161         packet-wtp.c \
162         packet-x11.c    \
163         packet-x25.c   \
164         packet-xot.c   \
165         packet-yhoo.c  \
166         packet-ypbind.c \
167         packet-ypserv.c \
168         packet-ypxfr.c \
169         packet-zebra.c
170
171 DISSECTOR_OBJECTS = $(DISSECTOR_SOURCES:.c=.obj)
172
173 ETHEREAL_COMMON_OBJECTS = \
174         asn1.obj         \
175         column.obj       \
176         follow.obj       \
177         getopt.obj       \
178         in_cksum.obj     \
179         ipproto.obj      \
180         prefs.obj        \
181         print.obj        \
182         ps.obj           \
183         ptvcursor.obj    \
184         register.obj     \
185         util.obj         \
186         xdlc.obj         \
187
188 ethereal_OBJECTS = \
189         $(DISSECTOR_OBJECTS) \
190         $(ETHEREAL_COMMON_OBJECTS) \
191         capture.obj      \
192         file.obj         \
193         summary.obj      \
194
195 tethereal_OBJECTS = \
196         $(DISSECTOR_OBJECTS) \
197         $(ETHEREAL_COMMON_OBJECTS) \
198         tethereal.obj
199
200 EXTRA_OBJECTS = \
201         snprintf.obj    \
202         strerror.obj    \
203         mkstemp.obj
204
205 ethereal_LIBS= wiretap\libwtap.lib gtk\libui.lib epan\ethereal.lib \
206         wsock32.lib user32.lib \
207         $(GTK_DIR)\gtk\gtk-$(GTK_VERSION).lib \
208         $(GTK_DIR)\gdk\gdk-$(GTK_VERSION).lib \
209         $(GLIB_DIR)\glib-$(GLIB_VERSION).lib \
210         $(GLIB_DIR)\gmodule\gmodule-$(GLIB_VERSION).lib \
211         $(PCAP_DIR)\lib\libpcap.lib
212
213 tethereal_LIBS= wiretap\libwtap.lib epan\ethereal.lib \
214         wsock32.lib user32.lib \
215         $(GLIB_DIR)\glib-$(GLIB_VERSION).lib \
216         $(GLIB_DIR)\gmodule\gmodule-$(GLIB_VERSION).lib \
217         $(PCAP_DIR)\lib\libpcap.lib
218
219 editcap_LIBS= wiretap\libwtap.lib wsock32.lib user32.lib \
220         $(GLIB_DIR)\glib-$(GLIB_VERSION).lib \
221         $(GLIB_DIR)\gmodule\gmodule-$(GLIB_VERSION).lib
222
223 EXECUTABLES=ethereal.exe tethereal.exe editcap.exe
224
225 RESOURCES=image\ethereal.res image\tethereal.res image\editcap.res
226
227 all: wiretap gtk epan $(EXECUTABLES) $(RESOURCES)
228
229 ethereal.exe    : config.h $(ethereal_OBJECTS) $(EXTRA_OBJECTS) image\ethereal.res wiretap\libwtap.lib gtk\libui.lib plugins
230         @echo Linking $@
231         $(LINK) @<<
232                 /OUT:ethereal.exe $(LDFLAGS) /SUBSYSTEM:windows $(ethereal_LIBS) $(ethereal_OBJECTS) $(EXTRA_OBJECTS) image\ethereal.res
233 <<
234
235 tethereal.exe   : config.h $(tethereal_OBJECTS) $(EXTRA_OBJECTS) image\tethereal.res wiretap\libwtap.lib plugins
236         @echo Linking $@
237         $(LINK) @<<
238                 /OUT:tethereal.exe $(LDFLAGS) /SUBSYSTEM:console $(tethereal_LIBS) $(tethereal_OBJECTS) $(EXTRA_OBJECTS) image\tethereal.res
239 <<
240
241 editcap.exe     : config.h editcap.obj getopt.obj wiretap\libwtap.lib image\editcap.res
242         @echo Linking $@
243         $(LINK) @<<
244                 /OUT:editcap.exe $(LDFLAGS) /SUBSYSTEM:console editcap.obj getopt.obj $(editcap_LIBS) image\editcap.res
245 <<
246
247 config.h        : config.h.win32
248         copy config.h.win32 $@
249
250 ps.c    : rdps.exe print.ps
251         rdps print.ps ps.c
252
253 packet-ncp2222.c : ncp2222.py
254         $(PYTHON) ncp2222.py > packet-ncp2222.c
255
256 register.c: $(DISSECTOR_SOURCES)
257         @echo Making register.c
258         @sh make-reg-dotc . $(DISSECTOR_SOURCES)
259
260 clean:
261         rm -f $(ethereal_OBJECTS) $(EXTRA_OBJECTS) $(EXECUTABLES) \
262                 tethereal.obj editcap.obj register.c dfilter-scanner.c \
263                 dfilter-grammar.c dfilter-grammar.h rdps.obj
264         cd wiretap
265         nmake -f Makefile.nmake clean
266         cd ../gtk
267         nmake -f Makefile.nmake clean
268         cd ../epan
269         nmake -f Makefile.nmake clean
270         cd ../plugins
271         nmake -f Makefile.nmake clean
272         cd ..
273
274 wiretap::
275         cd wiretap
276         nmake -f Makefile.nmake
277         cd ..
278
279 gtk::
280         cd gtk
281         nmake -f Makefile.nmake
282         cd ..
283
284 epan::
285         cd epan
286         nmake -f Makefile.nmake
287         cd ..
288
289 plugins::
290         cd plugins
291         nmake -f Makefile.nmake
292         cd ..
293