all libs now relative to a base dir, use compiler warning level 2
[obnox/wireshark/wip.git] / config.nmake
1 # $Id: config.nmake,v 1.74 2003/12/28 18:31:14 ulfl Exp $
2
3 VERSION=0.10.0
4 #
5 # The RC_VERSION should be comma-separated, not dot-separated, 
6 # as per Graham Bloice's message in
7 #
8 #       http://www.ethereal.com/lists/ethereal-dev/200303/msg00283.html
9 #
10 # "The RC_VERSION variable in config.nmake should be comma separated. 
11 # This allows the resources to be built correctly and the version
12 # number to be correctly displayed in the explorer properties dialog
13 # for the executables, and XP's tooltip, rather than 0.0.0.0."
14 #
15 RC_VERSION=0,10,0
16 WTAP_VERSION=0.0
17
18 #
19 # If you're building with WinPcap 2.3, set WINPCAP_VERSION to 2.3; if
20 # you're building with WinPcap 3.0, set it to 3.0; if you're building
21 # with WinPcap 3.1 alpha, set it to 3.1.
22 #
23 # If you're not building with WinPcap at all, don't set it (comment
24 # out or remove the line that sets it).
25 #
26 WINPCAP_VERSION=2.3
27
28
29 # Base directory, where your libraries reside, which needs to be 
30 # compiling the sources. This is only inside this file.
31 #
32 ETHEREAL_LIBS=C:\ethereal-win32-libs
33
34 #
35 # Current versions of GTK+ 1.3 require GLib 2.0.  Earlier versions of
36 # GTK+ 1.3 are buggy; we don't recommend using them, and we don't
37 # support them.  Upgrade to the current version.
38 #
39 GLIB_VERSION=2.0
40 GLIB_DIR=$(ETHEREAL_LIBS)\glib
41
42 #
43 # This presumes that GTK+ 1.3 packages put header files and libraries
44 # directly in a "gtk+" directory, while GTK+ 2.x developer's packages
45 # put header files in an "include\gtk-{version}" directory and libraries
46 # in a "lib\gtk-{version}" directory.
47 #
48 # If you're building with GTK+ 1.3, set GTK_VERSION to 1.3 and set
49 # GTK_DIR to the pathname of the "gtk+" directory; if you're building
50 # with GTK+ 2.x, set GTK_VERSION to 2.0 and set GTK_DIR to the pathname
51 # of the directory in which the "include" and "lib" directories reside.
52 #
53 GTK_VERSION=1.3
54 #GTK_VERSION=2.0
55 !IF "$(GTK_VERSION)" == "1.3"
56 GTK_DIR=$(ETHEREAL_LIBS)\gtk+
57 !ELSE
58 GTK_DIR=$(ETHEREAL_LIBS)\gtk2
59 !ENDIF
60
61 #
62 # If you have Zlib, set this to the pathname of the directory in
63 # which the Zlib headers and .lib file are stored.
64 #
65 # If you don't have Zlib, comment this line out, so that Zlib isn't
66 # defined.
67 #
68 ZLIB_DIR=$(ETHEREAL_LIBS)\zlib121-dll
69
70 #
71 # Set PCAP_DIR to the pathname of the directory in which the WinPcap
72 # developer's pack resides
73 #
74 PCAP_DIR=$(ETHEREAL_LIBS)\WPdpack
75
76 #
77 # Set NET_SNMP_DIR to the pathname of the directory in which the
78 # Net-SNMP include files and library resides.
79 #
80 NET_SNMP_DIR=$(ETHEREAL_LIBS)\net-snmp-5.1
81
82 #
83 # If you have GNU ADNS, set this to the pathname of the directory in
84 # which the GNU ADNS .lib file is stored.
85 #
86 # If you don't have GNU ADNS, comment this line out, so that ADNS_DIR
87 # isn't defined.
88 #
89 ADNS_DIR=$(ETHEREAL_LIBS)\adns-1.0-win32-01
90
91 #
92 # If you have the PCRE (Perl Compatible Regular Expressions) library,
93 # set this to the pathname of the directory in which the GNUWIN32
94 # pcre-lib package has been extracted.
95 #
96 # If you don't have PCRE, comment this line out, so that PCRE_DIR
97 # isn't defined.
98 #
99 PCRE_DIR=$(ETHEREAL_LIBS)\pcre-4.4
100
101 #
102 # Set ICONV_DIR to the pathname of the directory in which the
103 # ICONV include files and library resides.
104 #
105 ICONV_DIR=$(ETHEREAL_LIBS)\libiconv-1.9.1.bin.woe32
106
107 #
108 # Set GETTEXT_DIR to the pathname of the directory in which the
109 # GETTEXT include files and library resides.
110 #
111 GETTEXT_DIR=$(ETHEREAL_LIBS)\gettext-runtime-0.12.1.bin.woe32
112
113 # Compiler flags
114 # /W2  warning level 2 (0 less - 4 most, 1 default)
115 # /Zi  create .pdb file for debugging
116 LOCAL_CFLAGS=/Zi /W2
117
118 # Linker flags
119 # /DEBUG generate debug info
120 LOCAL_LDFLAGS=/DEBUG
121
122 # Set PDB_FILE according to your VC++ version 
123 PDB_FILE=vc*.pdb
124
125 # Set path if you need to find some binary
126 PATH=c:\cygwin\bin;c:\python22;$(PATH)
127
128 # Set path to some required DLLs
129 PATH=.\wiretap;$(ZLIB_DIR);$(ICONV_DIR)\bin;$(PCRE_DIR)\bin;$(PATH)
130
131 SH=bash
132 PERL=perl
133 POD2MAN=$(SH) pod2man
134 POD2HTML=$(SH) pod2html
135 PYTHON="C:/python22/python.exe"
136 LEX=flex
137 YACC=bison
138
139 # Set YACC_OPTS if cygnus bison can't find template file.
140 #YACC_OPTS=-S t:\w32-ix86\cygnus\cygwin-b20\share\bison.simple 
141
142 # To build the installer
143 MAKENSIS="C:/program files/nsis/makensis.exe"
144
145 # Choose modern style user interface for the installer.
146 # When using this, make sure you have a supported NSIS
147 # version installed. See "packaging\nsis\ethereal.nsi" for details.
148 #
149 # If you don't want the modern UI (or don't have a recent NSIS version),
150 # comment this line out, so that MAKENSIS_MODERN_UI isn't defined.
151 #
152 #MAKENSIS_MODERN_UI=USE
153
154 #
155 # You should not have to change anything below this comment.
156 # If you do, it's a deficiency in the Makefile.nmake files;
157 # either tell ethereal-dev@ethereal.com about it, including
158 # details of why you had to change it, or fix config.nmake
159 # and any Makefile.nmake files that need to be changed, and
160 # send us the patches, along with details of why the change
161 # was necessary.
162 #
163 GLIB_CFLAGS=/I$(GLIB_DIR)\include\glib-$(GLIB_VERSION) \
164         /I$(GLIB_DIR)\lib\glib-$(GLIB_VERSION)\include
165 GCC_GLIB_CFLAGS=-I$(GLIB_DIR)\include\glib-$(GLIB_VERSION) \
166         -I$(GLIB_DIR)\lib\glib-$(GLIB_VERSION)\include
167 GLIB_LIBS=$(GLIB_DIR)\lib\glib-$(GLIB_VERSION).lib \
168         $(GLIB_DIR)\lib\gmodule-$(GLIB_VERSION).lib \
169         $(GLIB_DIR)\lib\gobject-$(GLIB_VERSION).lib
170
171 !IF "$(GTK_VERSION)" == "1.3"
172 # GTK+ 1.3
173 GTK_CFLAGS=$(GLIB_CFLAGS) /I$(GTK_DIR)\include /I$(GTK_DIR)\include\gdk \
174         /I$(GTK_DIR)\lib\gtk+\include
175 GTK_LIBS=$(GTK_DIR)\lib\gtk.lib \
176         $(GTK_DIR)\lib\gdk.lib \
177         $(GLIB_LIBS)
178 !ELSE
179 # GTK+ 2.x
180 GTK_CFLAGS=$(GLIB_CFLAGS) /I$(GTK_DIR)\include\gtk-$(GTK_VERSION) \
181         /I$(GTK_DIR)\lib\gtk-$(GTK_VERSION)\include \
182         /I$(GTK_DIR)\include\atk-1.0 \
183         /I$(GTK_DIR)\include\pango-1.0
184 GTK_LIBS=$(GTK_DIR)\lib\gtk-win32-$(GTK_VERSION).lib \
185         $(GTK_DIR)\lib\gdk-win32-$(GTK_VERSION).lib \
186         $(GTK_DIR)\lib\gdk_pixbuf-$(GTK_VERSION).lib \
187         $(GTK_DIR)\lib\pango-1.0.lib \
188         $(GLIB_LIBS)
189 !ENDIF
190
191 !IFDEF WINPCAP_VERSION
192 # Nmake uses carets to escape special characters
193 WINPCAP_CONFIG=^#define HAVE_LIBPCAP 1
194 !IF "$(WINPCAP_VERSION)" == "3.0" || "$(WINPCAP_VERSION)" == "3.1"
195 PCAP_FINDALLDEVS_CONFIG=^#define HAVE_PCAP_FINDALLDEVS 1
196 WPCAP_CONSTIFIED_CONFIG=^#define WPCAP_CONSTIFIED 1
197 !ELSE
198 PCAP_FINDALLDEVS_CONFIG=
199 WPCAP_CONSTIFIED=
200 !ENDIF
201 !ELSE
202 WINPCAP_CONFIG=
203 PCAP_FINDALLDEVS_CONFIG=
204 WPCAP_CONSTIFIED=
205 !ENDIF
206
207 !IFDEF ZLIB_DIR
208 ZLIB_CFLAGS=/I$(ZLIB_DIR)\include
209 ZLIB_LIBS=$(ZLIB_DIR)\lib\zdll.lib
210 # Nmake uses carets to escape special characters
211 ZLIB_CONFIG=^#define HAVE_LIBZ 1
212 !else
213 ZLIB_CFLAGS=
214 ZLIB_LIBS=
215 ZLIB_CONFIG=
216 !ENDIF
217
218 !IFDEF ADNS_DIR
219 ADNS_CFLAGS=/I$(ADNS_DIR)\src /I$(ADNS_DIR)\adns_win32
220 ADNS_LIBS=$(ADNS_DIR)\adns_win32\lib\adns_dll.lib
221 # Nmake uses carets to escape special characters
222 ADNS_CONFIG=^#define HAVE_GNU_ADNS 1
223 !else
224 ADNS_CFLAGS=
225 ADNS_LIBS=
226 ADNS_CONFIG=
227 !ENDIF
228
229 !IFDEF PCRE_DIR
230 PCRE_CFLAGS=/I$(PCRE_DIR)\include
231 PCRE_LIBS=$(PCRE_DIR)\lib\pcre.lib
232 # Nmake uses carets to escape special characters
233 PCRE_CONFIG=^#define HAVE_LIBPCRE 1
234 !else
235 PCRE_CFLAGS=
236 PCRE_LIBS=
237 PCRE_CONFIG=
238 !ENDIF
239