From Ivan Sy (with minor modifications):
[obnox/wireshark/wip.git] / config.nmake
1 # $Id$
2
3 # Some more informations about the settings in this file, can be found
4 # in the file README.win32 and the Developer's Guide (available online).
5
6 ##### Target platform #####
7 # Only "win32" and "win64" are valid (for now).
8 # This can be defined in the system environment.
9 !IFNDEF WIRESHARK_TARGET_PLATFORM
10 WIRESHARK_TARGET_PLATFORM=win32
11 !ENDIF
12
13 ##### Versions #####
14
15 # The current Wireshark version
16 # It's highly recommended to leave MAJOR/MINOR/MICRO unchanged
17 VERSION_MAJOR=1
18 VERSION_MINOR=3
19 VERSION_MICRO=0
20 VERSION_BUILD=0
21 # It's recommended to change VERSION_EXTRA for your own custom builds
22 # e.g. "-SVN-12345"
23 VERSION_EXTRA=
24
25 # The version of the wiretap library (recommended: leave unchanged)
26 WTAP_VERSION_MAJOR=0
27 WTAP_VERSION_MINOR=3
28 WTAP_VERSION_MICRO=1
29
30
31
32 ##### Directories #####
33
34 #
35 # Base directory, where your libraries reside, which are needed to
36 # compile the sources. This setting is used only inside this file.
37 #
38 WIRESHARK_LIBS=C:\wireshark-$(WIRESHARK_TARGET_PLATFORM)-libs
39
40 #
41 # Base directory, where your programs reside.
42 # This setting is used only inside this file.
43 #
44 PROGRAM_FILES=$(PROGRAMFILES)
45
46 #
47 # Location of the "tools" directory. This affects HTML2TXT below and should
48 # be overridden by makefiles in any subdirectories that use HTML2TXT.
49 !IFNDEF TOOLS_DIR
50 TOOLS_DIR=tools
51 !ENDIF
52
53 #
54 # Machine type for the compiler and linker
55 # TARGET_MACHINE (Used for link /MACHINE) should be one of "X86" or "X64"
56 # (sorry ARM, Alpha, MIPS, and Itanium fans).
57 # CPU (Used by win32.mak) should be one of "i386" or "AMD64".
58 !if "$(WIRESHARK_TARGET_PLATFORM)" == "win32"
59 TARGET_MACHINE=x86
60 CPU=i386
61 VCREDIST_DLL=x86
62 !else if "$(WIRESHARK_TARGET_PLATFORM)" == "win64"
63 TARGET_MACHINE=x64
64 CPU=AMD64
65 VCREDIST_DLL=amd64
66 !else
67 !error Your mysterious moon-man architecture "$(WIRESHARK_TARGET_PLATFORM)" frightens and confuses us.
68 !endif
69
70
71 ##### Microsoft Visual C / Studio Variant #####
72 # for the different Studios, see: http://en.wikipedia.org/wiki/Microsoft_Visual_Studio
73 # only one of the following MSVC_VARIANT settings should be used
74 # BTW: The "Microsoft Visual C++ Toolkit 2003" DOESN'T WORK for WS!
75
76 # "Microsoft Visual Studio 6.0"
77 # Visual C++ 6.0, _MSC_VER 1200, msvcrt.dll (version 6)
78 #MSVC_VARIANT=MSVC6
79
80 # "Microsoft Visual Studio .NET (2002)"
81 # Visual C++ 7.0, _MSC_VER 1300, msvcr70.dll
82 #MSVC_VARIANT=MSVC2002
83
84 # "Microsoft .Net Framework SDK Version 1.0"
85 # needs additional Platform SDK installation
86 # Visual C++ 7.0, _MSC_VER 1300, msvcr70.dll
87 #MSVC_VARIANT=DOTNET10
88
89 # "Microsoft Visual Studio .NET 2003"
90 # Visual C++ 7.1, _MSC_VER 1310, msvcr71.dll
91 #MSVC_VARIANT=MSVC2003
92
93 # "Microsoft .Net Framework SDK Version 1.1"
94 # needs additional Platform SDK installation
95 # Visual C++ 7.1, _MSC_VER 1310, msvcr71.dll
96 #MSVC_VARIANT=DOTNET11
97
98 # "Microsoft Visual Studio 2005"
99 # Visual C++ 8.0, _MSC_VER 1400, msvcr80.dll
100 #MSVC_VARIANT=MSVC2005
101
102 # "Microsoft Visual C++ 2005 Express Edition"
103 # needs additional Platform SDK installation
104 # Visual C++ 8.0, _MSC_VER 1400, msvcr80.dll
105 #MSVC_VARIANT=MSVC2005EE
106
107 # "Microsoft .Net Framework 2.0 SDK"
108 # needs additional Platform SDK installation
109 # Visual C++ 8.0, _MSC_VER 1400, msvcr80.dll
110 #MSVC_VARIANT=DOTNET20
111
112 # "Microsoft Visual Studio 2008"
113 # Visual C++ 9.0, _MSC_VER 1500, msvcr90.dll
114 MSVC_VARIANT=MSVC2008
115
116 # "Microsoft Visual C++ 2008 Express Edition"
117 # Visual C++ 9.0, _MSC_VER 1500, msvcr90.dll
118 #MSVC_VARIANT=MSVC2008EE
119
120 #
121 # Optional: To compile some time critical code from assembler instead of C
122 #
123 # If you have the NASM compiler, set this to the NASM executable.
124 # http://nasm.sourceforge.net/
125 #
126 # If you don't have NASM, comment this line out, so that NASM
127 # isn't defined.
128 #
129 NASM=$(WIRESHARK_LIBS)\nasm-2.02\nasm.exe
130
131
132 !if "$(WIRESHARK_TARGET_PLATFORM)" == "win32"
133 ##### Win32 Libraries #####
134 #
135 # Mandatory: GLib settings
136 #
137 # Please note: Since Wireshark release 1.0.0, we no longer support GLib1.x
138 #
139 GLIB_VERSION=2.0
140 GLIB_PKG=2.20.3-1
141 GLIB_DIR=$(WIRESHARK_LIBS)\glib
142
143 ##### To Use new packet list uncomment this line ####
144 ### Warning Experimental - work in progress
145 #NEW_PACKET_LIST_CONFIG=^#define NEW_PACKET_LIST 1
146
147 #
148 # Mandatory: GTK (& related libs) settings
149 #
150 # Please note: Since Wireshark release 1.0.0, we no longer support GTK1.x
151 #
152 # If you want building with GTK+, set GTK_DIR to the pathname of the
153 # directory in which the "include" and "lib" directories reside.
154 #
155 GTK_DIR=$(WIRESHARK_LIBS)\gtk2
156 GTK_PKG=2.16.2-1
157 CAIRO_PKG=1.8.6-1
158 ATK_PKG=1.26.0-1
159 LIBPNG_PKG=1.2.37-1
160 TIFF_PKG=libtiff-3.8.2
161 TIFF_DLL=libtiff3.dll
162 JPEG_PKG=jpeg-6b-4-bin
163 JPEG_DLL=jpeg62.dll
164 PANGO_PKG=1.24.2-1
165
166 #
167 # Mandatory: Version numbers of GTK and pango.
168 #
169 # (MAJOR + MINOR Version number but without MICRO version number)
170 # These macros are used by the nsis installer script and by the setup target.
171 #
172 # GTK 2.12 is the mainline since Wireshark 0.99.7
173 GTK_INST_VERSION=2.16
174 PANGO_INST_VERSION=1.24
175
176 #
177 # Optional: WinPcap developer's pack to capture network traffic.
178 #
179 # If you have the WinPcap developer's pack (at least version 3.0),
180 # set this to the directory in which the WinPcap developer's pack resides.
181 #
182 # If you don't have the WPdpack, comment this line out, so that
183 # PCAP_DIR isn't defined.
184 #
185 PCAP_VERSION=4_1_beta5
186 PCAP_DIR=$(WIRESHARK_LIBS)\WPdpack
187
188 #
189 # Optional: WinPcap remote capture support and new API
190 # (pcap_open(), pcap_findalldevs_ex(), etc.)
191 #
192 PCAP_REMOTE=1
193
194 #
195 # Optional: The ZLib enables unzipping of gzip compressed capture files
196 # "on the fly".
197 #
198 # If you have Zlib, set this to directory in which the Zlib headers
199 # and .lib file are stored.
200 #
201 # If you don't have Zlib, comment this line out, so that ZLIB_DIR isn't
202 # defined.
203 #
204 ZLIB_DIR=$(WIRESHARK_LIBS)\zlib123
205
206 #
207 # Optional: the ADNS library enables asynchronous (nonblocking) DNS
208 # name resolvings.
209 #
210 # If you have GNU ADNS, set this to the directory in which the GNU ADNS
211 # .lib file is stored.
212 #
213 # If you don't have GNU ADNS, comment this line out, so that ADNS_DIR
214 # isn't defined.
215 #
216 # If C_ARES_DIR is defined below, it will override this setting.
217 #
218 #ADNS_DIR=$(WIRESHARK_LIBS)\adns-1.0-win32-05ws
219
220 #
221 # Optional: the c-ares library enables asynchronous (nonblocking) DNS
222 # name resolvings.
223 #
224 # If you have c-ares, set this to the directory in which the c-ares
225 # .lib file is stored. Setting this will override ADNS_DIR above. You
226 # can't have both.
227 #
228 # If you're using Visual C++ 6.0, you'll have to use a platform SDK that
229 # defines socklen_t, such as Windows Server 2003 PSDK.
230 #
231 # If you don't have c-ares, comment this line out, so that C_ARES_DIR
232 # isn't defined.
233 #
234 C_ARES_DIR=$(WIRESHARK_LIBS)\c-ares-1.6.0ws
235
236 #
237 # Optional: the PCRE (Perl Compatible Regular Expressions) library
238 # enables regular expressions for display filters.
239 #
240 # If you have the PCRE library, set this to the directory in which
241 # the GNUWIN32 pcre-lib package is stored.
242 #
243 # If you don't have PCRE, comment this line out, so that PCRE_DIR
244 # isn't defined.
245 #
246 PCRE_DIR=$(WIRESHARK_LIBS)\pcre-7.0
247
248 #
249 # Optional: the GNUTLS library enables ssl decryption.
250 #
251 # If you have the GNUTLS library, set this to the directory where
252 # the lib and include files are stored.
253 #
254 # If you don't have GNUTLS, comment this line out, so that GNUTLS_DIR
255 # isn't defined.
256 #
257 # Platform SDK conflicts with openssl.h header
258 GNUTLS_DIR=$(WIRESHARK_LIBS)\gnutls-2.8.1-1
259
260 #
261 # Optional: the KFW library enables kerberos/sasl/dcerpc decryption.
262 #
263 # If you have the kerberos for windows (mit) library, set this to the
264 # directory where the kfw package is stored.
265 #
266 # If you don't have KFW, comment this line out, so that KFW_DIR
267 # isn't defined.
268 #
269 KFW_DIR=$(WIRESHARK_LIBS)\kfw-3.2.2-ws1
270
271 #
272 # Optional: the Nettle library enables ??? decryption.
273 #
274 # If you have the Nettle encryption library, set this to the
275 # directory in which the nettle package is stored.
276 #
277 # If you don't have Nettle, comment this line out, so that NETTLE_DIR
278 # isn't defined.
279 #
280 # NETTLE_DIR=$(WIRESHARK_LIBS)\nettle-1.10
281
282 #
283 # Optional: the LUA library enables scripting support.
284 #
285 # If you have the LUA library, set this to the directory in which
286 # the LUA package is stored.
287 #
288 # If you don't have LUA, comment this line out, so that LUA_DIR
289 # isn't defined.
290 #
291 LUA_DIST=5_1_4_Win32_dll6
292 LUA_DIR=$(WIRESHARK_LIBS)\lua5.1.4
293
294 #
295 # Optional: the PORTAUDIO library enables audio output for RTP streams.
296 #
297 # If you have the PORTAUDIO library (used for rtp_player), set this to
298 # the directory in which the PORTAUDIO library is stored.
299 #
300 # If you don't have PORTAUDIO, comment this line out, so that
301 # PORTAUDIO_DIR isn't defined.
302 #
303 #PORTAUDIO_DIR=$(WIRESHARK_LIBS)\portaudio_v18_1
304 PORTAUDIO_DIR=$(WIRESHARK_LIBS)\portaudio_v19_2
305
306 #
307 # Version number of PortAudio
308 #
309 #PORTAUDIO_VERSION=18
310 PORTAUDIO_VERSION=19
311
312 #
313 # Iconv: Mandatory for Glib >= 2 and <= 2.14.4
314 # [win-iconv statically linked as part of Glib >= 2.14.5]
315 # Set ICONV_DIR to the directory in which the
316 # ICONV include files and library resides.
317 #
318 ##ICONV_DIR=$(WIRESHARK_LIBS)\libiconv-1.9.1.bin.woe32
319
320 #
321 # Mandatory for GTK >= 2: Gettext
322 #
323 # Set GETTEXT_DIR to the directory in which the
324 # GETTEXT include files and library resides.
325 #
326 #GETTEXT_DIR=$(WIRESHARK_LIBS)\gettext-0.14.5
327 GETTEXT_PKG=-runtime-0.17-1
328 GETTEXT_DIR=$(WIRESHARK_LIBS)\gettext-runtime-0.17-1
329 GETTEXT_DLL=intl.dll
330 #
331 # Optional: AirPcap developer's pack to capture wireless network traffic
332 # incl. 802.11 management frames.
333 #
334 # If you have the AirPcap developer's pack, set this to the directory
335 # in which the AirPcap developer's pack resides.
336 #
337 # If you don't have the AirPcap developer's pack, comment this line out,
338 # so that AIRPCAP_DIR isn't defined.
339 #
340 AIRPCAP_DIR=$(WIRESHARK_LIBS)\AirPcap_Devpack_1_0_0_594\AirPcap_Devpack
341
342 #
343 # Optional: LIBSMI, System Management Interface
344 #
345 # Used for oid-name resolution for SNMP and other protocols
346 #
347 SMI_DIR=$(WIRESHARK_LIBS)\libsmi-0.4.8
348
349 #
350 # Optional: GeoIP, IP address database lookups
351 #
352 # Used to map IP addresses to MaxMind GeoIP database entries
353 #
354 # GeoIP requires IPv6 definitions that don't ship with Visual C++ 6.0.
355 # However, the Microsoft Platform SDK for Windows Server 2003 R2 provides
356 # these definitions. The SDK's SetEnv.bat script defines INETSDK.
357 !IF "$(MSVC_VARIANT)" != "MSVC6" || DEFINED(INETSDK)
358 GEOIP_DIR=$(WIRESHARK_LIBS)\GeoIP-1.4.5ws
359 !ENDIF
360
361 !else
362 ##### Win64 Libraries #####
363 #
364 # Mandatory: GLib settings
365 #
366 # Please note: Since Wireshark release 1.0.0, we no longer support GLib1.x
367 #
368 GLIB_VERSION=2.0
369 GLIB_PKG=2.20.3-1
370 GLIB_DIR=$(WIRESHARK_LIBS)\glib
371
372 ##### To Use new packet list uncomment this line ####
373 ### Warning Experimental - work in progress
374 #NEW_PACKET_LIST_CONFIG=^#define NEW_PACKET_LIST 1
375
376 #
377 # Mandatory: GTK (& related libs) settings
378 #
379 # Please note: Since Wireshark release 1.0.0, we no longer support GTK1.x
380 #
381 # If you want building with GTK+, set GTK_DIR to the pathname of the
382 # directory in which the "include" and "lib" directories reside.
383 #
384 GTK_DIR=$(WIRESHARK_LIBS)\gtk2
385 GTK_PKG=2.16.2-1
386 CAIRO_PKG=1.8.6-2
387 ATK_PKG=1.26.0-1
388 LIBPNG_PKG=1.2.37-1
389 TIFF_PKG=libtiff_3.8.2-1_win64
390 TIFF_DLL=libtiff.dll
391 JPEG_PKG=jpeg_6b-2_win64
392 JPEG_DLL=libjpeg-62.dll
393 PANGO_PKG=1.24.2-1
394
395 #
396 # Mandatory: Version numbers of GTK and pango.
397 #
398 # (MAJOR + MINOR Version number but without MICRO version number)
399 # These macros are used by the nsis installer script and by the setup target.
400 #
401 GTK_INST_VERSION=2.16
402 PANGO_INST_VERSION=1.24
403
404 #
405 # Optional: WinPcap developer's pack to capture network traffic.
406 #
407 # If you have the WinPcap developer's pack (at least version 3.0),
408 # set this to the directory in which the WinPcap developer's pack resides.
409 #
410 # If you don't have the WPdpack, comment this line out, so that
411 # PCAP_DIR isn't defined.
412 #
413 PCAP_VERSION=4_1_beta5
414 PCAP_DIR=$(WIRESHARK_LIBS)\WPdpack
415
416 #
417 # Optional: WinPcap remote capture support and new API
418 # (pcap_open(), pcap_findalldevs_ex(), etc.)
419 #
420 PCAP_REMOTE=1
421
422 #
423 # Optional: The ZLib enables unzipping of gzip compressed capture files
424 # "on the fly".
425 #
426 # If you have Zlib, set this to directory in which the Zlib headers
427 # and .lib file are stored.
428 #
429 # If you don't have Zlib, comment this line out, so that ZLIB_DIR isn't
430 # defined.
431 #
432 ZLIB_DIR=$(WIRESHARK_LIBS)\zlib123
433
434 #
435 # Optional: the ADNS library enables asynchronous (nonblocking) DNS
436 # name resolvings.
437 #
438 # If you have GNU ADNS, set this to the directory in which the GNU ADNS
439 # .lib file is stored.
440 #
441 # If you don't have GNU ADNS, comment this line out, so that ADNS_DIR
442 # isn't defined.
443 #
444 # If C_ARES_DIR is defined below, it will override this setting.
445 #
446 #ADNS_DIR=$(WIRESHARK_LIBS)\adns-1.0-win32-05ws
447
448 #
449 # Optional: the c-ares library enables asynchronous (nonblocking) DNS
450 # name resolvings.
451 #
452 # If you have c-ares, set this to the directory in which the c-ares
453 # .lib file is stored. Setting this will override ADNS_DIR above. You
454 # can't have both.
455 #
456 # If you're using Visual C++ 6.0, you'll have to use a platform SDK that
457 # defines socklen_t, such as Windows Server 2003 PSDK.
458 #
459 # If you don't have c-ares, comment this line out, so that C_ARES_DIR
460 # isn't defined.
461 #
462 #C_ARES_DIR=$(WIRESHARK_LIBS)\c-ares-1.5.2ws
463
464 #
465 # Optional: the PCRE (Perl Compatible Regular Expressions) library
466 # enables regular expressions for display filters.
467 #
468 # If you have the PCRE library, set this to the directory in which
469 # the GNUWIN32 pcre-lib package is stored.
470 #
471 # If you don't have PCRE, comment this line out, so that PCRE_DIR
472 # isn't defined.
473 #
474 #PCRE_DIR=$(WIRESHARK_LIBS)\pcre-7.0
475
476 #
477 # Optional: the GNUTLS library enables ssl decryption.
478 #
479 # If you have the GNUTLS library, set this to the directory where
480 # the lib and include files are stored.
481 #
482 # If you don't have GNUTLS, comment this line out, so that GNUTLS_DIR
483 # isn't defined.
484 #
485 # Platform SDK conflicts with openssl.h header
486 #GNUTLS_DIR=$(WIRESHARK_LIBS)\gnutls-2.8.1-1
487
488 #
489 # Optional: the KFW library enables kerberos/sasl/dcerpc decryption.
490 #
491 # If you have the kerberos for windows (mit) library, set this to the
492 # directory where the kfw package is stored.
493 #
494 # If you don't have KFW, comment this line out, so that KFW_DIR
495 # isn't defined.
496 #
497 #KFW_DIR=$(WIRESHARK_LIBS)\kfw-3.2.2-ws1
498
499 #
500 # Optional: the Nettle library enables ??? decryption.
501 #
502 # If you have the Nettle encryption library, set this to the
503 # directory in which the nettle package is stored.
504 #
505 # If you don't have Nettle, comment this line out, so that NETTLE_DIR
506 # isn't defined.
507 #
508 # NETTLE_DIR=$(WIRESHARK_LIBS)\nettle-1.10
509
510 #
511 # Optional: the LUA library enables scripting support.
512 #
513 # If you have the LUA library, set this to the directory in which
514 # the LUA package is stored.
515 #
516 # If you don't have LUA, comment this line out, so that LUA_DIR
517 # isn't defined.
518 #
519 LUA_DIST=5_1_4_Win64_dll9
520 LUA_DIR=$(WIRESHARK_LIBS)\lua5.1.4
521
522 #
523 # Optional: the PORTAUDIO library enables audio output for RTP streams.
524 #
525 # If you have the PORTAUDIO library (used for rtp_player), set this to
526 # the directory in which the PORTAUDIO library is stored.
527 #
528 # If you don't have PORTAUDIO, comment this line out, so that
529 # PORTAUDIO_DIR isn't defined.
530 #
531 #PORTAUDIO_DIR=$(WIRESHARK_LIBS)\portaudio_v18_1
532 PORTAUDIO_DIR=$(WIRESHARK_LIBS)\portaudio_v19_2
533
534 #
535 # Version number of PortAudio
536 #
537 #PORTAUDIO_VERSION=18
538 PORTAUDIO_VERSION=19
539
540 #
541 # Iconv: Mandatory for Glib >= 2 and <= 2.14.4
542 # [win-iconv statically linked as part of Glib >= 2.14.5]
543 # Set ICONV_DIR to the directory in which the
544 # ICONV include files and library resides.
545 #
546 ##ICONV_DIR=$(WIRESHARK_LIBS)\libiconv-1.9.1.bin.woe32
547
548 #
549 # Mandatory for GTK >= 2: Gettext
550 #
551 # Set GETTEXT_DIR to the directory in which the
552 # GETTEXT include files and library resides.
553 #
554 #GETTEXT_DIR=$(WIRESHARK_LIBS)\gettext-0.14.5
555 GETTEXT_PKG=_0.17-1_win64
556 GETTEXT_DIR=$(WIRESHARK_LIBS)\gettext-0.17-1
557 GETTEXT_DLL=libintl-8.dll
558 #
559 # Optional: AirPcap developer's pack to capture wireless network traffic
560 # incl. 802.11 management frames.
561 #
562 # If you have the AirPcap developer's pack, set this to the directory
563 # in which the AirPcap developer's pack resides.
564 #
565 # If you don't have the AirPcap developer's pack, comment this line out,
566 # so that AIRPCAP_DIR isn't defined.
567 #
568 #AIRPCAP_DIR=$(WIRESHARK_LIBS)\AirPcap_Devpack_1_0_0_594\AirPcap_Devpack
569
570 #
571 # Optional: LIBSMI, System Management Interface
572 #
573 # Used for oid-name resolution for SNMP and other protocols
574 #
575 #SMI_DIR=$(WIRESHARK_LIBS)\libsmi-0.4.8
576
577 #
578 # Optional: GeoIP, IP address database lookups
579 #
580 # Used to map IP addresses to MaxMind GeoIP database entries
581 #
582 # GeoIP requires IPv6 definitions that don't ship with Visual C++ 6.0.
583 # However, the Microsoft Platform SDK for Windows Server 2003 R2 provides
584 # these definitions. The SDK's SetEnv.bat script defines INETSDK.
585 !IF "$(MSVC_VARIANT)" != "MSVC6" || DEFINED(INETSDK)
586 #GEOIP_DIR=$(WIRESHARK_LIBS)\GeoIP-1.4.5ws
587 !ENDIF
588
589 !endif
590
591 ##### Tools #####
592
593 # Set the following mandatory commands to find the tools.
594 # The easiest way is to use the corresponding packages from cygwin.
595
596 # Set up the path to the cygwin binaries
597 CYGWIN_PATH=c:\cygwin\bin
598
599 # command for a shell (cygwin's bash package recommended)
600 SH_PROG=bash
601
602 # bash versions after 3.1.6 need the 'igncr' shell option to be able to
603 #  process scripts in windows 'native format' (dos crlf format).
604 # The following !IF results in the option being used only if it is available
605 #  since using it on bash version 3.1.6 (or earlier) is not required and
606 #  will cause an error message.
607 !if "$(SH_PROG)"=="bash" && [$(CYGWIN_PATH)\bash -c "set -o igncr" 2>nul: ] == 0
608 SH_FLAGS=-o igncr
609 !endif
610
611 SH=$(SH_PROG) $(SH_FLAGS)
612
613
614 # command for perl (cygwin's perl package recommended)
615 PERL=perl
616
617 # command for pod2man and pod2html
618 # (part of the perl package, usually leave these unchanged)
619 POD2MAN=$(SH) pod2man
620 POD2HTML=$(SH) pod2html
621
622 # Command for native Windows Python (recommended)
623 # V2.4 to V2.6 should work
624
625 # If you want to specify your Python settings, uncomment the lines below.
626 #PYTHON="C:\Python26\python.exe"
627 #PATH=c:\Python26;$(PATH)
628
629 # Command for Cygwin's Python (not recommended)
630 #PYTHON=env python
631
632 # Otherwise, find Python automatically.
633 !IF !DEFINED(PYTHON)
634 !IF EXIST(c:\Python26\python.exe)
635 PYTHON="C:\Python26\python.exe"
636 PATH=c:\Python26;$(PATH)
637 !ELSE IF EXIST(c:\Python25\python.exe)
638 PYTHON="C:\Python25\python.exe"
639 PATH=c:\Python25;$(PATH)
640 !ELSE IF EXIST(c:\Python24\python.exe)
641 PYTHON="C:\Python24\python.exe"
642 PATH=c:\Python24;$(PATH)
643 !ENDIF
644 !ENDIF
645
646 # command for lex/flexx (cygwin's flex recommended)
647 LEX=flex
648
649 # command for yacc/bison (cygwin's bison recommended)
650 YACC=bison
651
652 #
653 # Optional: To build the NSIS installer.
654 #
655 # If you have the NSIS package, set this to the NSIS executable.
656 #
657 # If you don't have NSIS, comment this line out, so that MAKENSIS
658 # isn't defined.
659 #
660 MAKENSIS="$(PROGRAM_FILES)\nsis\makensis.exe"
661
662 #
663 # Optional: To build the developers API documentation with doxygen and dot.
664 # Currently experimental, outdated and incomplete.
665 #
666 # You will have to download and install:
667 # Doxygen from: http://www.doxygen.org
668 # Graphviz from: http://www.research.att.com/sw/tools/graphviz/
669 #
670 # If you have doxygen, set this to the doxygen executable.
671 #
672 # If you don't want the developers documentation (or don't have the tools),
673 # comment this line out, so that DOXYGEN isn't defined.
674 #
675 #DOXYGEN="$(PROGRAM_FILES)/doxygen/bin/doxygen.exe"
676
677 #
678 # Recommended: Use the compressed html help format .chm as the Wireshark integrated help.
679 #
680 # The required htmlhelp.h and htmlhelp.lib should be included in MSVC_VARIANT > MSVC6.
681 #
682 # For MSVC_VARIANT == MSVC6 you will have to download and install the html help workshop from:
683 #
684 # http://msdn.microsoft.com/library/default.asp?url=/library/en-us/htmlhelp/html
685 # /hwMicrosoftHTMLHelpDownloads.asp
686 #
687 # Then point HHC_DIR to the html help dir (where hhc.exe resides).
688 #
689 # If you don't want the online help (or don't have the tools),
690 # comment this line out, so that HHC_DIR isn't defined.
691 #
692 HHC_DIR=$(PROGRAM_FILES)/HTML Help Workshop
693
694 #
695 # Optional: To reduce the size of dlls and exes, which is especially useful for USB device distributions (U3, PortableApps)
696 #
697 # If you have the UPX package, set this to the upx.exe executable.
698 #
699 # UPX can be downloaded from:
700 #   http://upx.sourceforge.net/
701 #
702 # If you don't have UPX, or don't want to pack exes and dlls,
703 # comment this line out, so that UPX isn't defined.
704 #
705
706 UPX=$(WIRESHARK_LIBS)\upx303w\upx.exe
707
708 ##### Flags, PATHs and Miscellaneous #####
709
710 # "convert" the MSVC variant into the required MSC compiler version
711 !IF "$(MSVC_VARIANT)" == "MSVC6"
712 MSC_VER_REQUIRED=1200
713 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2002" || "$(MSVC_VARIANT)" == "DOTNET10"
714 MSC_VER_REQUIRED=1300
715 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2003" || "$(MSVC_VARIANT)" == "DOTNET11"
716 MSC_VER_REQUIRED=1310
717 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2005" || "$(MSVC_VARIANT)" == "MSVC2005EE" || "$(MSVC_VARIANT)" == "DOTNET20"
718 MSC_VER_REQUIRED=1400
719 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2008" ||  "$(MSVC_VARIANT)" == "MSVC2008EE"
720 MSC_VER_REQUIRED=1500
721 !ELSE
722 !ERROR MSVC_VARIANT unknown
723 !ENDIF
724
725 # Compiler flags:
726 # /W3  warning level 3 (0 less - 4 most, 1 default)
727 # /Zi  create .pdb file for debugging
728 # /MD  use "Multithreading Debug" libraries
729 # /D_CRT_SECURE_NO_DEPRECATE        Don't warn for "insecure" calls, see MSDN "Security Enhancements in the CRT"
730 # /D_CRT_NONSTDC_NO_DEPRECATE       Don't warn for "Deprecated CRT Functions" as MSDN calls this
731 # /D_BIND_TO_CURRENT_CRT_VERSION=1  Make sure our CRT and manifest versions match (http://msdn.microsoft.com/en-us/library/cc664727.aspx)
732 # /DWIN32_LEAN_AND_MEAN             Don't include unnecessary Windows include files (see windows.h)
733 # /MP [<number of processes>]       [MSVC2008]: Compiles multiple source files by using multiple processes
734 #                                               Add if desired for compile speedup on machines with 2 or more "effective processors"
735 # /MANIFEST:no                      Don't create a SxS manifest. Makes sure our plugins don't load a second copy of the CRT.
736 #
737 !IF "$(MSVC_VARIANT)" == "MSVC6" || "$(MSVC_VARIANT)" == "MSVC2002" || "$(MSVC_VARIANT)" == "DOTNET10" || "$(MSVC_VARIANT)" == "MSVC2003" || "$(MSVC_VARIANT)" == "DOTNET11"
738 LOCAL_CFLAGS=/Zi /W3 /MD /DWIN32_LEAN_AND_MEAN /DMSC_VER_REQUIRED=$(MSC_VER_REQUIRED)
739 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2005" || "$(MSVC_VARIANT)" == "MSVC2005EE" || "$(MSVC_VARIANT)" == "DOTNET20" || "$(MSVC_VARIANT)" == "MSVC2008" || "$(MSVC_VARIANT)" == "MSVC2008EE"
740 LOCAL_CFLAGS=/Zi /W3 /MD /D_CRT_SECURE_NO_DEPRECATE /D_CRT_NONSTDC_NO_DEPRECATE /DWIN32_LEAN_AND_MEAN /DMSC_VER_REQUIRED=$(MSC_VER_REQUIRED) /D_BIND_TO_CURRENT_CRT_VERSION=1
741 !ELSE
742 !ERROR MSVC_VARIANT unknown
743 !ENDIF
744
745 # http://msdn.microsoft.com/en-us/library/bb385193.aspx
746 # /MP (Build with Multiple Processes)
747 # /MP[processMax]
748 # If you omit the processMax argument, the compiler retrieves the number of effective processors
749 # on your computer from the operating system, and creates a process for each processor.
750 #
751 # The following compiler options and language features that are incompatible with the /MP option:
752 # #import preprocessor directive
753 # /E, /EP
754 # /Gm
755 # /showIncludes
756 # /Yc
757
758 !IF "$(MSVC_VARIANT)" == "MSVC2008" || "$(MSVC_VARIANT)" == "MSVC2008EE"
759 LOCAL_CFLAGS= $(LOCAL_CFLAGS) /MP
760 !ENDIF
761 # Linker flags:
762 # /DEBUG  generate debug info
763 # /PROFILE generate map file(s) for profiling
764 # /DEFAULTLIB:xxx use xxx as the standard C library
765 # /NODEFAULTLIB:xxx don't use xxx as the standard C library
766 #
767 LOCAL_LDFLAGS=/DEBUG /MACHINE:$(TARGET_MACHINE)
768 DLL_LDFLAGS =
769 !IF $(MSC_VER_REQUIRED) >= 1400
770 DLL_LDFLAGS = /MANIFEST:no
771 !ENDIF
772
773 PLUGIN_LDFLAGS = /NOLOGO /INCREMENTAL:no $(LOCAL_LDFLAGS) $(DLL_LDFLAGS)
774
775 #
776 # According to http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=403
777 # XCOPY under Windows NT doesn't support the "/Y" flag.  This works
778 # around that bug.
779 # XXX - This apparently doesn't work for some versions of nmake:
780 # http://support.microsoft.com/default.aspx?scid=kb;en-us;86814
781 # It looks like we'll have to call "set copycmd=/y" before we run xcopy.
782 COPYCMD=/y
783
784 #
785 # If you don't want to build libwireshark.dll, you should comment out the
786 # following line. (Note: for plugin support this option must stay activated)
787 ENABLE_LIBWIRESHARK=USE
788
789 #
790 # install (debug) directory for Wireshark (relative to your source dir)
791 INSTALL_DIR=wireshark-gtk2
792
793
794
795 ##### C-Runtime Redistributable #####
796 #
797 # The C-Runtime since Version 7 must be shipped together with
798 # the program installer, to avoid missing msvcr*.dll files on
799 # the target machine.
800 #
801 # The location of these files differ on the various compiler
802 # packages, the following will use the default paths depending
803 # on the package version.
804 #
805 !IF "$(MSVC_VARIANT)" == "MSVC6"
806 # msvcrt.dll will already be available on target machines - nothing additional to install
807
808 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2002"
809 # you probably need to tweak this directory if you don't use the professional edition!
810 MSVCR_DLL=$(PROGRAM_FILES)\Microsoft Visual Studio .NET\Visual Studio .NET Professional - English\msvcr70.dll
811
812 !ELSEIF "$(MSVC_VARIANT)" == "DOTNET10"
813 # no redistributable available for this package!
814
815 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2003"
816 # you probably need to tweak this directory if you don't use the professional edition!
817 MSVCR_DLL=$(PROGRAM_FILES)\Microsoft Visual Studio .NET 2003\Visual Studio .NET Professional 2003 - English\msvcr71.dll
818
819 !ELSEIF "$(MSVC_VARIANT)" == "DOTNET11"
820 # no redistributable available for this package!
821
822 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2005"
823 MSVCR_DLL=$(PROGRAM_FILES)\Microsoft Visual Studio 8\VC\redist\$(VCREDIST_DLL)\Microsoft.VC80.CRT\*.*
824
825 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2005EE" || "$(MSVC_VARIANT)" == "DOTNET20" || "$(MSVC_VARIANT)" == "MSVC2008EE"
826 # you need to download the redistributable package vcredist_x86.exe from Microsoft first,
827 # and copy it to the lib folder!!!
828 VCREDIST_EXE=$(WIRESHARK_LIBS)\vcredist_$(TARGET_MACHINE).exe
829
830 !ELSEIF "$(MSVC_VARIANT)" == "MSVC2008"
831 MSVCR_DLL=$(PROGRAM_FILES)\Microsoft Visual Studio 9.0\VC\redist\$(VCREDIST_DLL)\Microsoft.VC90.CRT\*.*
832
833 !ELSE
834 !ERROR MSVC_VARIANT unknown
835 !ENDIF
836
837
838
839 ##### Advanced: Docbook/XML documentation generation #####
840 # If you want to generate the Docbook/XML based docs (User's and Developer's
841 # Guide, ...), you'll need some additional tools / libraries compared to the
842 # rest of the build process.
843 #
844 # FOR DETAILED INSTRUCTIONS TO GENERATE THE DOCS, SEE: docbook\readme.txt.
845 #
846 # If you don't call the Makefile.nmake in the docbook dir to generate the
847 # docs, the following settings in this section will have no effect.
848
849 # formatting objects processor executable
850 # Comment this out if you don't have fop installed or you don't want the docs
851 # in PDF format.
852 !IFNDEF FOP
853 FOP=fop-0.20.5\fop.bat
854 !ENDIF
855
856 # Additional options to fop.
857 FOP_OPTS=-Xmx256m
858
859 # html help compiler
860 # Comment this out if you don't have hhc.exe or you don't want the docs in
861 # .chm format.
862 #
863 # Beware: hhc.exe is NOT part of the MSVC packages in HHC_DIR mentioned above,
864 # so you'll need to install the HTML Help Workshop for this.
865 HHC_EXE="$(HHC_DIR)\hhc.exe"
866
867 # html to text converter for text version of release notes, e.g. elinks.
868 # This could also be "lynx", or "true" if neither elinks nor lynx is installed
869 # (cygwin: lynx works, elinks not available, links and true doesn't produce output)
870 #HTML2TXT=elinks -dump -dump-width 72
871 #HTML2TXT=links -dump -width 72
872 #HTML2TXT=lynx -dump -width=72 -nolist -stdin
873
874 !IFNDEF HTML2TXT
875 HTML2TXT=$(PYTHON) $(TOOLS_DIR)\html2text.py --width=72 --no-links
876 !ENDIF
877
878 # the XSL processor (part of cygwin's libxslt package)
879 XSLTPROC="xsltproc"
880
881 # the XML validator (part of cygwin's libxml2 package)
882 XMLLINT="xmllint"
883
884
885
886 ##############################################################################
887 #
888 # You should not have to change anything below this comment.
889 # If you do, it's a deficiency in the Makefile.nmake files;
890 # either tell wireshark-dev@wireshark.org about it, including
891 # details of why you had to change it, or fix config.nmake
892 # and any Makefile.nmake files that need to be changed, and
893 # send us the patches, along with details of why the change
894 # was necessary.
895 #
896 ##############################################################################
897
898 #
899 # The RC_VERSION should be comma-separated, not dot-separated,
900 # as per Graham Bloice's message in
901 #
902 #       http://www.ethereal.com/lists/ethereal-dev/200303/msg00283.html
903 #
904 # "The RC_VERSION variable in config.nmake should be comma separated.
905 # This allows the resources to be built correctly and the version
906 # number to be correctly displayed in the explorer properties dialog
907 # for the executables, and XP's tooltip, rather than 0.0.0.0."
908 #
909
910 VERSION=$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_MICRO)$(VERSION_EXTRA)
911 RC_VERSION=$(VERSION_MAJOR),$(VERSION_MINOR),$(VERSION_MICRO),$(VERSION_BUILD)
912
913 WTAP_VERSION=$(WTAP_VERSION_MAJOR).$(WTAP_VERSION_MINOR).$(WTAP_VERSION_MICRO)
914 RC_WTAP_VERSION=$(WTAP_VERSION_MAJOR),$(WTAP_VERSION_MINOR),$(WTAP_VERSION_MICRO)
915
916
917 GLIB_CFLAGS=/I$(GLIB_DIR)\include\glib-$(GLIB_VERSION) \
918         /I$(GLIB_DIR)\lib\glib-$(GLIB_VERSION)\include
919 GCC_GLIB_CFLAGS=-I$(GLIB_DIR)\include\glib-$(GLIB_VERSION) \
920         -I$(GLIB_DIR)\lib\glib-$(GLIB_VERSION)\include
921 GLIB_LIBS=$(GLIB_DIR)\lib\glib-$(GLIB_VERSION).lib \
922         $(GLIB_DIR)\lib\gmodule-$(GLIB_VERSION).lib \
923         $(GLIB_DIR)\lib\gobject-$(GLIB_VERSION).lib
924
925 # GTK+
926 GTK_CFLAGS=$(GLIB_CFLAGS) /I$(GTK_DIR)\include\gtk-2.0 \
927         /I$(GTK_DIR)\lib\gtk-2.0\include \
928         /I$(GTK_DIR)\include\atk-1.0 \
929         /I$(GTK_DIR)\include\cairo \
930         /I$(GTK_DIR)\include\pango-1.0
931 GTK_LIBS=$(GTK_DIR)\lib\gtk-win32-2.0.lib \
932         $(GTK_DIR)\lib\gdk-win32-2.0.lib \
933         $(GTK_DIR)\lib\gdk_pixbuf-2.0.lib \
934         $(GTK_DIR)\lib\pango-1.0.lib \
935         $(GLIB_LIBS)
936
937 !IF "$(GTK_INST_VERSION)" == "2.16"
938 GTK_LIB_DIR=2.10.0
939 NEED_LIBPNG_DLL=USE
940 NEED_LIBJPEG_DLL=USE
941 NEED_LIBTIFF_DLL=USE
942 NEED_CAIRO_DLL=USE
943 GTK_WIMP_DLLSRC_DIR=$(GTK_DIR)\lib\gtk-2.0\2.10.0\engines
944 GTK_WIMP_DLLDST_DIR=lib\gtk-2.0\2.10.0\engines
945 GTK_WIMP_RCSRC_DIR=$(GTK_DIR)\share\themes\MS-Windows\gtk-2.0
946 GTK_WIMP_RCDST_DIR=etc\gtk-2.0
947 !ELSEIF "$(GTK_INST_VERSION)" == "2.14"
948 GTK_LIB_DIR=2.10.0
949 NEED_LIBPNG_DLL=USE
950 NEED_LIBJPEG_DLL=USE
951 NEED_LIBTIFF_DLL=USE
952 NEED_CAIRO_DLL=USE
953 GTK_WIMP_DLLSRC_DIR=$(GTK_DIR)\lib\gtk-2.0\2.10.0\engines
954 GTK_WIMP_DLLDST_DIR=lib\gtk-2.0\2.10.0\engines
955 GTK_WIMP_RCSRC_DIR=$(GTK_DIR)\share\themes\MS-Windows\gtk-2.0
956 GTK_WIMP_RCDST_DIR=etc\gtk-2.0
957 !ELSEIF "$(GTK_INST_VERSION)" == "2.12"
958 GTK_LIB_DIR=2.10.0
959 NEED_LIBPNG_DLL=USE
960 NEED_LIBJPEG_DLL=USE
961 NEED_LIBTIFF_DLL=USE
962 NEED_CAIRO_DLL=USE
963 GTK_WIMP_DLLSRC_DIR=$(GTK_DIR)\lib\gtk-2.0\2.10.0\engines
964 GTK_WIMP_DLLDST_DIR=lib\gtk-2.0\2.10.0\engines
965 GTK_WIMP_RCSRC_DIR=$(GTK_DIR)\share\themes\MS-Windows\gtk-2.0
966 GTK_WIMP_RCDST_DIR=etc\gtk-2.0
967 !ELSE
968 !ERROR ? Unknown or invalid GTK_INST_VERSION
969 !ENDIF
970
971 !IF "$(PANGO_INST_VERSION)" == "1.24"
972 PANGO_LIB_DIR=1.5.0
973 !ELSEIF "$(PANGO_INST_VERSION)" == "1.22"
974 PANGO_LIB_DIR=1.5.0
975 !ELSEIF "$(PANGO_INST_VERSION)" == "1.18"
976 PANGO_LIB_DIR=1.5.0
977 !ELSEIF "$(PANGO_INST_VERSION)" == "1.16"
978 PANGO_LIB_DIR=1.5.0
979 !ELSE
980 !ERROR ? Unknown or invalid PANGO_INST_VERSION
981 !ENDIF
982
983 !IFDEF AIRPCAP_DIR
984 AIRPCAP_CONFIG=^#define HAVE_AIRPCAP 1
985 AIRPDCAP_CONFIG=^#define HAVE_AIRPDCAP 1
986 #AIRPCAP_CFLAGS=/I$(AIRPCAP_DIR)\include
987 !ELSE
988 AIRPCAP_CONFIG=
989 AIRPDCAP_CONFIG=
990 !ENDIF
991
992 !IFDEF PCAP_DIR
993 # Nmake uses carets to escape special characters
994 WINPCAP_CONFIG=^#define HAVE_LIBPCAP 1
995 PCAP_FINDALLDEVS_CONFIG=^#define HAVE_PCAP_FINDALLDEVS 1
996 PCAP_DATALINK_NAME_TO_VAL_CONFIG=^#define HAVE_PCAP_DATALINK_NAME_TO_VAL 1
997 PCAP_DATALINK_VAL_TO_NAME_CONFIG=^#define HAVE_PCAP_DATALINK_VAL_TO_NAME 1
998 # PCAP_BREAKLOOP won't have any benefit on Win32, but breaks compatibility with 3.0
999 PCAP_BREAKLOOP_CONFIG=
1000 WPCAP_CONSTIFIED_CONFIG=^#define WPCAP_CONSTIFIED 1
1001 !ELSE
1002 # no WpdPack installed
1003 WINPCAP_CONFIG=
1004 PCAP_FINDALLDEVS_CONFIG=
1005 PCAP_DATALINK_NAME_TO_VAL_CONFIG=
1006 PCAP_DATALINK_VAL_TO_NAME_CONFIG=
1007 PCAP_BREAKLOOP_CONFIG=
1008 WPCAP_CONSTIFIED=
1009 !ENDIF
1010
1011 PCAP_LIST_DATALINKS_CONFIG=^#define HAVE_PCAP_LIST_DATALINKS 1
1012 PCAP_SET_DATALINK_CONFIG=^#define HAVE_PCAP_SET_DATALINK 1
1013
1014 !IF DEFINED(PCAP_DIR) && DEFINED(PCAP_REMOTE)
1015 PCAP_HAVE_REMOTE_CONFIG=^#define HAVE_REMOTE 1
1016 PCAP_REMOTE_CONFIG=^#define HAVE_PCAP_REMOTE 1
1017 PCAP_OPEN_CONFIG=^#define HAVE_PCAP_OPEN 1
1018 PCAP_FINDALLDEVS_EX_CONFIG=^#define HAVE_PCAP_FINDALLDEVS_EX 1
1019 PCAP_CREATESRCSTR_CONFIG=^#define HAVE_PCAP_CREATESRCSTR 1
1020 PCAP_SETSAMPLING_CONFIG=^#define HAVE_PCAP_SETSAMPLING 1
1021 !ELSE
1022 PCAP_HAVE_REMOTE_CONFIG=
1023 PCAP_REMOTE_CONFIG=
1024 PCAP_OPEN_CONFIG=
1025 PCAP_FINDALLDEVS_EX_CONFIG=
1026 PCAP_CREATESRCSTR_CONFIG=
1027 PCAP_SETSAMPLING_CONFIG=
1028 !ENDIF
1029
1030 !IFDEF ZLIB_DIR
1031 ZLIB_PATH=$(ZLIB_DIR)
1032 ZLIB_CFLAGS=/I$(ZLIB_DIR)\include
1033 ZLIB_LIBS=$(ZLIB_DIR)\lib\zdll.lib
1034 ZLIB_DLL=$(ZLIB_DIR)\zlib1.dll
1035 # Nmake uses carets to escape special characters
1036 ZLIB_CONFIG=^#define HAVE_LIBZ 1
1037 !else
1038 ZLIB_CFLAGS=
1039 ZLIB_LIBS=
1040 ZLIB_DLL=
1041 ZLIB_CONFIG=
1042 !ENDIF
1043
1044 !IFDEF C_ARES_DIR
1045 !UNDEF ADNS_DIR
1046 C_ARES_CFLAGS=/I$(C_ARES_DIR)
1047 C_ARES_LIBS=$(C_ARES_DIR)\cares.lib
1048 C_ARES_DLL=$(C_ARES_DIR)\cares.dll
1049 # Nmake uses carets to escape special characters
1050 C_ARES_CONFIG=^#define HAVE_C_ARES 1
1051 !else
1052 C_ARES_CFLAGS=
1053 C_ARES_LIBS=
1054 C_ARES_CONFIG=
1055 !IFDEF ADNS_DIR
1056 ADNS_PATH=$(ADNS_DIR)\adns_win32\lib
1057 ADNS_CFLAGS=/I$(ADNS_DIR)\src /I$(ADNS_DIR)\adns_win32
1058 ADNS_LIBS=$(WIRESHARK_LIBS)\$(MSVC_VARIANT)\adns\adns_dll.lib
1059 ADNS_DLL=$(WIRESHARK_LIBS)\$(MSVC_VARIANT)\adns\adns_dll.dll
1060 # Nmake uses carets to escape special characters
1061 ADNS_CONFIG=^#define HAVE_GNU_ADNS 1
1062 !else
1063 ADNS_CFLAGS=
1064 ADNS_LIBS=
1065 ADNS_CONFIG=
1066 !ENDIF # ADNS
1067 !ENDIF # C_ARES
1068
1069 !IFDEF KFW_DIR
1070 KFW_PATH=$(KFW_DIR)\bin
1071 KFW_CFLAGS=/I$(KFW_DIR)\include
1072 KFW_LIBS=$(KFW_DIR)\lib\krb5_32.lib
1073 # Nmake uses carets to escape special characters
1074 KFW_CONFIG=^#define HAVE_MIT_KERBEROS 1
1075 !else
1076 KFW_CFLAGS=
1077 KFW_LIBS=
1078 KFW_CONFIG=
1079 !ENDIF
1080
1081 !IFDEF PCRE_DIR
1082 PCRE_PATH=$(PCRE_DIR)\bin
1083 PCRE_CFLAGS=/I$(PCRE_DIR)\include
1084 PCRE_LIBS=$(PCRE_DIR)\lib\pcre.lib
1085 # Nmake uses carets to escape special characters
1086 PCRE_CONFIG=^#define HAVE_LIBPCRE 1
1087 !else
1088 PCRE_CFLAGS=
1089 PCRE_LIBS=
1090 PCRE_CONFIG=
1091 !ENDIF
1092
1093 !IFDEF NETTLE_DIR
1094 NETTLE_CFLAGS=/I$(NETTLE_DIR)
1095 NETTLE_LIBS=$(NETTLE_DIR)\libnettle.lib
1096 # Nmake uses carets to escape special characters
1097 NETTLE_CONFIG=^#define HAVE_LIBNETTLE 1
1098 !else
1099 NETTLE_CFLAGS=
1100 NETTLE_LIBS=
1101 NETTLE_CONFIG=
1102 !ENDIF
1103
1104 !IFDEF GNUTLS_DIR
1105 GNUTLS_PATH=$(GNUTLS_DIR)
1106 # /DNOCRYPT avoids inclusion of Wincrypt.h, avoiding a X509_NAME define clash
1107 GNUTLS_CFLAGS=/I$(GNUTLS_DIR)\include /DNOCRYPT /DIMPORT_LIGNUTLSDLL
1108 GNUTLS_LIBS=\
1109         $(GNUTLS_DIR)\bin\libtasn1-3.lib        \
1110         $(GNUTLS_DIR)\bin\libgpg-error-0.lib    \
1111         $(GNUTLS_DIR)\bin\libgcrypt-11.lib      \
1112         $(GNUTLS_DIR)\bin\libgnutls-26.lib
1113 # Nmake uses carets to escape special characters
1114 GNUTLS_CONFIG=^#define HAVE_LIBGNUTLS 1
1115 LIBGCRYPT_CONFIG=^#define HAVE_LIBGCRYPT 1
1116 !else
1117 GNUTLS_CFLAGS=
1118 GNUTLS_LIBS=
1119 GNUTLS_CONFIG=
1120 LIBGCRYPT_CONFIG=
1121 !ENDIF
1122
1123 !IFDEF LUA_DIR
1124 LUA_CFLAGS=/I$(LUA_DIR)\include
1125 LUA_LIBS=$(LUA_DIR)\lua5.1.lib
1126 # Nmake uses carets to escape special characters
1127 LUA_CONFIG=^#define HAVE_LUA 1
1128 LUA_VERSION=^#define HAVE_LUA_5_1 1
1129 !else
1130 LUA_CFLAGS=
1131 LUA_LIBS=
1132 LUA_CONFIG=
1133 !ENDIF
1134
1135 !IFDEF PORTAUDIO_DIR
1136 # Nmake uses carets to escape special characters
1137 PORTAUDIO_CONFIG=^#define HAVE_LIBPORTAUDIO 1
1138 !IF "$(PORTAUDIO_VERSION)" == "18"
1139 # V18 uses API version 1 and v19 API version 2
1140 PORTAUDIO_CFLAGS=/I$(PORTAUDIO_DIR)\pa_common
1141 PORTAUDIO_API_CONFIG=^#define PORTAUDIO_API_1 1
1142 !ELSE
1143 PORTAUDIO_CFLAGS=/I$(PORTAUDIO_DIR)\include /I$(PORTAUDIO_DIR)\src\common /I$(PORTAUDIO_DIR)\src\os\win /DPA_NO_DS /DPA_NO_ASIO
1144 !ENDIF
1145 !ELSE
1146 PORTAUDIO_CFLAGS=
1147 PORTAUDIO_CONFIG=
1148 !ENDIF
1149
1150 !IFDEF HHC_DIR
1151 !IF "$(MSVC_VARIANT)" == "MSVC6"
1152 HHC_CFLAGS=/I"$(HHC_DIR)\include" -DHHC_DIR
1153 HHC_LIBS="$(HHC_DIR)\lib\htmlhelp.lib"
1154 !ELSE
1155 HHC_CFLAGS=-DHHC_DIR
1156 HHC_LIBS=htmlhelp.lib
1157 !ENDIF
1158 !ELSE
1159 HHC_CFLAGS=
1160 HHC_LIBS=
1161 !ENDIF
1162
1163 !IFDEF SMI_DIR
1164 SMI_CONFIG=^#define HAVE_LIBSMI 1
1165 SMI_CFLAGS=/I$(SMI_DIR)\include
1166 SMI_LIBS=$(SMI_DIR)\lib\smi.lib
1167 !ELSE
1168 SMI_LIBS=
1169 SMI_CFLAGS=
1170 SMI_CONFIG=
1171 !ENDIF
1172
1173 !IFDEF GEOIP_DIR
1174 GEOIP_CONFIG=^#define HAVE_GEOIP 1
1175 GEOIP_CFLAGS=/I$(GEOIP_DIR)\libGeoIP
1176 GEOIP_LIBS=$(GEOIP_DIR)\libGeoIP\GeoIP.lib
1177 !ELSE
1178 GeoIP_LIBS=
1179 GeoIP_CFLAGS=
1180 GeoIP_CONFIG=
1181 !ENDIF
1182
1183 !IFDEF ENABLE_LIBWIRESHARK
1184 LIBWIRESHARK_CONFIG=^#define HAVE_LIBWIRESHARKDLL 1
1185 # Link plugins with the import library of libwireshark.dll
1186 LINK_PLUGINS_WITH_LIBWIRESHARK=USE
1187 !ELSE
1188 LIBWIRESHARK_CONFIG=
1189 !ENDIF
1190
1191 # Construct the path
1192 !IFDEF ICONV_DIR
1193 PATH=$(PATH);$(CYGWIN_PATH);$(GLIB_DIR)\bin;$(GETTEXT_DIR)\bin;$(ICONV_DIR)\bin;$(ZLIB_PATH);$(ADNS_PATH)
1194 !ELSE
1195 PATH=$(PATH);$(CYGWIN_PATH);$(GLIB_DIR)\bin;$(GETTEXT_DIR)\bin;$(ZLIB_PATH);$(ADNS_PATH)
1196 !ENDIF
1197
1198 # We can't use a lot of IPv6 code with plain Visual C++ 6.0
1199 !IF "$(MSVC_VARIANT)" == "MSVC6" && !DEFINED(MSSDK)
1200 INET6_CONFIG=
1201 !ELSE
1202 INET6_CONFIG=^#define INET6 1
1203 !ENDIF
1204
1205 !IF "$(MSVC_VARIANT)" == "MSVC6" && !DEFINED(MSSDK)
1206 NTDDNDIS_CONFIG=
1207 !ELSE
1208 NTDDNDIS_CONFIG=^#define HAVE_NTDDNDIS_H 1
1209 !ENDIF