X-Git-Url: http://git.samba.org/samba.git/?p=obnox%2Fwireshark%2Fwip.git;a=blobdiff_plain;f=Makefile.nmake;h=9029d6e176ed51460bcef5866bdb715bf3824322;hp=0d1e12ac6ada67bfe504d5378523140e3efaf69b;hb=dc5ab1f85d35669f50a48b6df587b8779dac44c0;hpb=fb89f604d5cdd93ad8f4efe6a9705f347950eeda diff --git a/Makefile.nmake b/Makefile.nmake index 0d1e12ac6a..9029d6e176 100644 --- a/Makefile.nmake +++ b/Makefile.nmake @@ -15,26 +15,24 @@ CC = cl LINK= link BSCMAKE= bscmake -WIN_SETUP=tools\$(WIRESHARK_TARGET_PLATFORM)-setup.sh +WIN_SETUP=tools/$(WIRESHARK_TARGET_PLATFORM)-setup.sh # ------------- -# Check that the Wireshark Libraries are up-to-date (checktag) -# 1. winxx-setup.sh --checktag is invoked during nmake "preprocessing". -# 2. If an error status is returned (ie: the libraries are not up-to-date) -# then LIBS_CHECK is defined as a non-null string. -# When $(LIBS_CHECK) is first referenced as a dependency -# during the make, the $(LIBS_CHECK) target will be invoked -# causing an error message and an error exit. -# 3. If a success status is returned, then LIBS_CHECK is defined as a -# null string and thus any use of $(LIBS_CHECK) as a -# dependency is effectively ignored. -# The net result: If the Wireshark libraries are not current, a -# "libraries not up to date" error exit will occur for -# the specific targets which have $(LIBS_CHECK) as a dependency. -!IF [$(SH) $(WIN_SETUP) --checktag "$(WIRESHARK_LIBS)"] != 0 +# Checking that the Wireshark Libraries are up-to-date: +# 1. win??-setup.sh --checktag is invoked during nmake "preprocessing". +# If an error status is returned (ie: the libraries are not up-to-date) +# then CHECK_TAG is defined as a non-null string. +# 2. The $(LIBS_CHECK) target is invoked during the nmake: +# If $(CHECK_TAG) is non-null, then a "libraries not up to date" exit will occur. +# If $(CHECK_TAG) is null, but either config.nmake or Makefile.nmake +# are newer than the $(LIBS_CHECK) target, then a detailed verification +# as to the required library package files will be made. +# LIBS_CHECK=_libs_check_ +!IF [$(SH) $(WIN_SETUP) --checktag "$(WIRESHARK_LIBS)"] != 0 +CHECK_TAG=_check_tag_ !ELSE -LIBS_CHECK= +CHECK_TAG= !ENDIF # ------------- @@ -42,10 +40,9 @@ LDFLAGS = /NOLOGO /INCREMENTAL:no $(LOCAL_LDFLAGS) # We use GENERATED_CFLAGS to get around flex's non-LLP64-compliant output GENERATED_CFLAGS=-DHAVE_CONFIG_H $(LOCAL_CFLAGS) $(GLIB_CFLAGS) /I. /Iwiretap \ - $(ZLIB_CFLAGS) /I$(PCAP_DIR)\include \ - $(AIRPCAP_CFLAGS) \ + $(ZLIB_CFLAGS) /I$(PCAP_DIR)\include $(AIRPCAP_CFLAGS) \ $(C_ARES_CFLAGS) $(ADNS_CFLAGS) $(PCRE_CFLAGS) $(GNUTLS_CFLAGS) \ - $(LUA_CFLAGS) $(SMI_CFLAGS) $(GEOIP_CFLAGS) \ + $(PYTHON_CFLAGS) $(SMI_CFLAGS) $(GEOIP_CFLAGS) \ -D_U_="" -D_NEED_VAR_IMPORT_ CFLAGS=-WX $(GENERATED_CFLAGS) @@ -74,18 +71,12 @@ dftest_OBJECTS = $(dftest_SOURCES:.c=.obj) dumpcap_OBJECTS = $(dumpcap_SOURCES:.c=.obj) randpkt_OBJECTS = $(randpkt_SOURCES:.c=.obj) -EXTRA_OBJECTS = \ - getopt.obj \ - inet_ntop.obj \ - inet_pton.obj \ - mkstemp.obj \ - strptime.obj - wireshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib shell32.lib comctl32.lib \ $(HHC_LIBS) \ wsutil\libwsutil.lib \ $(GNUTLS_LIBS) \ + $(PYTHON_LIBS) \ !IFDEF ENABLE_LIBWIRESHARK epan\libwireshark.lib \ !ELSE @@ -105,6 +96,7 @@ tshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ $(GLIB_LIBS) \ wsutil\libwsutil.lib \ $(GNUTLS_LIBS) \ + $(PYTHON_LIBS) \ !IFDEF ENABLE_LIBWIRESHARK epan\libwireshark.lib \ !ELSE @@ -124,6 +116,7 @@ rawshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ $(GLIB_LIBS) \ wsutil\libwsutil.lib \ $(GNUTLS_LIBS) \ + $(PYTHON_LIBS) \ !IFDEF ENABLE_LIBWIRESHARK epan\libwireshark.lib \ !ELSE @@ -141,7 +134,8 @@ rawshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ capinfos_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib shell32.lib \ wsutil\libwsutil.lib \ - $(GLIB_LIBS) + $(GLIB_LIBS) \ + $(GCRYPT_LIBS) editcap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib shell32.lib \ @@ -162,7 +156,8 @@ dumpcap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib \ wsutil\libwsutil.lib \ $(GLIB_LIBS) \ - $(GNUTLS_LIBS) + $(GTHREAD_LIBS) \ + $(PYTHON_LIBS) dftest_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib \ @@ -198,12 +193,19 @@ RESOURCES=image\wireshark.res image\libwireshark.res image\tshark.res \ all: $(LIBS_CHECK) config.h tools image codecs $(C_ARES_DLL) $(ADNS_DLL) $(ZLIB_DLL) wsutil wiretap epan $(EXECUTABLES) $(RESOURCES) doc help install-all +!IFDEF MAKENSIS packaging: all cd packaging cd nsis $(MAKE) /$(MAKEFLAGS) -f makefile.nmake cd .. cd .. +!ELSE +packaging: _FORCE_ + @echo \? NSIS not available (MAKENSIS not defined in config.nmake) + @echo. + @exit 1 +!ENDIF packaging_u3: all cd packaging @@ -229,87 +231,95 @@ packaging_zip: all xcopy "$(MSVCR_DLL)" $(INSTALL_DIR) !ENDIF !IFDEF VCREDIST_EXE - @echo Including vcredist_x86.exe -- your recipient may need to run it! + @echo Including vcredist_$(TARGET_MACHINE).exe -- your recipient may need to run it! xcopy "$(VCREDIST_EXE)" $(INSTALL_DIR) !ENDIF rm -f wireshark.zip zip -r -9 wireshark.zip $(INSTALL_DIR)/ -wireshark.bsc: *.sbr epan\*.sbr epan\dfilter\*.sbr epan\ftypes\*.sbr epan\wslua\*.sbr epan\dissectors\*.sbr gtk\*.sbr wiretap\*.sbr +wireshark.bsc: *.sbr epan\*.sbr epan\dfilter\*.sbr epan\ftypes\*.sbr epan\wslua\*.sbr epan\dissectors\*.sbr gtk\*.sbr win32\*.sbr wiretap\*.sbr rm -f $@ $(BSCMAKE) @<< /o $@ $? << xcopy $@ $(INSTALL_DIR)\ /d +pdb_zip: all + cd $(INSTALL_DIR) + rm -f ../wireshark-pdb-$(WIRESHARK_TARGET_PLATFORM)-$(VERSION).zip + zip -9 ../wireshark-pdb-$(WIRESHARK_TARGET_PLATFORM)-$(VERSION).zip *.pdb + cd .. + $(RESOURCES): image wiretap\wiretap-$(WTAP_VERSION).lib: image $(ZLIB_DLL) wiretap -wireshark.exe : $(LIBS_CHECK) config.h svnversion.h $(wireshark_OBJECTS) getopt.obj inet_ntop.obj inet_pton.obj codecs epan gtk image\wireshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib codecs\codecs.lib gtk\libui.lib plugins +wireshark.exe : $(LIBS_CHECK) config.h $(wireshark_OBJECTS) codecs epan gtk win32 image\wireshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib codecs\codecs.lib gtk\libui.lib win32\libui_win32.lib plugins @echo Linking $@ $(LINK) @<< - /OUT:wireshark.exe $(guiflags) $(guilibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:windows $(wireshark_LIBS) getopt.obj inet_ntop.obj inet_pton.obj $(GTK_LIBS) codecs\codecs.lib gtk\libui.lib $(wireshark_OBJECTS) image\wireshark.res + /OUT:wireshark.exe $(guiflags) $(guilibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:windows $(wireshark_LIBS) $(GTK_LIBS) codecs\codecs.lib gtk\libui.lib win32\libui_win32.lib $(wireshark_OBJECTS) image\wireshark.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "wireshark.exe.manifest" -outputresource:wireshark.exe;1 !ENDIF -tshark.exe : $(LIBS_CHECK) config.h svnversion.h $(tshark_OBJECTS) getopt.obj inet_ntop.obj epan image\tshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib plugins +tshark.exe : $(LIBS_CHECK) config.h $(tshark_OBJECTS) epan image\tshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib plugins @echo Linking $@ $(LINK) @<< - /OUT:tshark.exe $(conflags) $(conlibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:console $(tshark_LIBS) $(tshark_OBJECTS) getopt.obj inet_ntop.obj image\tshark.res + /OUT:tshark.exe $(conflags) $(conlibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:console $(tshark_LIBS) $(tshark_OBJECTS) image\tshark.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "tshark.exe.manifest" -outputresource:tshark.exe;1 !ENDIF -rawshark.exe : $(LIBS_CHECK) config.h svnversion.h $(rawshark_OBJECTS) getopt.obj inet_ntop.obj epan image\rawshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib plugins +rawshark.exe : $(LIBS_CHECK) config.h $(rawshark_OBJECTS) epan image\rawshark.res wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib plugins @echo Linking $@ $(LINK) @<< - /OUT:rawshark.exe $(conflags) $(conlibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:console $(rawshark_LIBS) $(rawshark_OBJECTS) getopt.obj inet_ntop.obj image\rawshark.res + /OUT:rawshark.exe $(conflags) $(conlibsdll) $(LDFLAGS) /LARGEADDRESSAWARE /SUBSYSTEM:console $(rawshark_LIBS) $(rawshark_OBJECTS) image\rawshark.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "rawshark.exe.manifest" -outputresource:rawshark.exe;1 !ENDIF # XXX: This makefile does not properly handle doing a 'nmake ... capinfos.exe' directly since some of the .objs # (e.g. epan\plugins.obj) must be built first using epan\Makefile.nmake (which happens for 'nmake ... all'). -capinfos.exe : $(LIBS_CHECK) config.h $(capinfos_OBJECTS) getopt.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\capinfos.res +# Linking with setargv.obj enables "wildcard expansion" of command-line arguments +capinfos.exe : $(LIBS_CHECK) config.h $(capinfos_OBJECTS) wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\capinfos.res @echo Linking $@ $(LINK) @<< - /OUT:capinfos.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(capinfos_OBJECTS) getopt.obj $(capinfos_LIBS) image\capinfos.res + /OUT:capinfos.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(capinfos_OBJECTS) $(capinfos_LIBS) setargv.obj image\capinfos.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "capinfos.exe.manifest" -outputresource:capinfos.exe;1 !ENDIF # XXX: This makefile does not properly handle doing a 'nmake ... editcap.exe' directly since some of the .objs # (e.g. epan\plugins.obj) must be built first using epan\Makefile.nmake (which happens for 'nmake ... all'). -editcap.exe : $(LIBS_CHECK) config.h $(editcap_OBJECTS) getopt.obj strptime.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\editcap.res +editcap.exe : $(LIBS_CHECK) config.h $(editcap_OBJECTS) wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\editcap.res @echo Linking $@ $(LINK) @<< - /OUT:editcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(editcap_OBJECTS) getopt.obj strptime.obj $(editcap_LIBS) image\editcap.res + /OUT:editcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(editcap_OBJECTS) $(editcap_LIBS) image\editcap.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "editcap.exe.manifest" -outputresource:editcap.exe;1 !ENDIF -mergecap.exe : $(LIBS_CHECK) config.h svnversion.h mergecap.obj merge.obj getopt.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\mergecap.res +# Linking with setargv.obj enables "wildcard expansion" of command-line arguments +mergecap.exe : $(LIBS_CHECK) config.h mergecap.obj merge.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\mergecap.res @echo Linking $@ $(LINK) @<< - /OUT:mergecap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console mergecap.obj merge.obj getopt.obj $(mergecap_LIBS) image\mergecap.res + /OUT:mergecap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console mergecap.obj merge.obj $(mergecap_LIBS) setargv.obj image\mergecap.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "mergecap.exe.manifest" -outputresource:mergecap.exe;1 !ENDIF -text2pcap.exe : $(LIBS_CHECK) config.h text2pcap.obj text2pcap-scanner.obj getopt.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib strptime.obj image\text2pcap.res +text2pcap.exe : $(LIBS_CHECK) config.h text2pcap.obj text2pcap-scanner.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\text2pcap.res @echo Linking $@ $(LINK) @<< - /OUT:text2pcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console text2pcap.obj text2pcap-scanner.obj getopt.obj $(text2pcap_LIBS) strptime.obj image\text2pcap.res + /OUT:text2pcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console text2pcap.obj text2pcap-scanner.obj $(text2pcap_LIBS) image\text2pcap.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "text2pcap.exe.manifest" -outputresource:text2pcap.exe;1 !ENDIF @@ -318,25 +328,25 @@ dftest.exe : $(dftest_OBJECTS) epan $(LINK) @<< /OUT:dftest.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(dftest_LIBS) $(dftest_OBJECTS) << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "dftest.exe.manifest" -outputresource:dftest.exe;1 !ENDIF -randpkt.exe : $(randpkt_OBJECTS) getopt.obj +randpkt.exe : $(randpkt_OBJECTS) @echo Linking $@ $(LINK) @<< - /OUT:randpkt.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(randpkt_LIBS) $(randpkt_OBJECTS) getopt.obj + /OUT:randpkt.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(randpkt_LIBS) $(randpkt_OBJECTS) << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "randpkt.exe.manifest" -outputresource:randpkt.exe;1 !ENDIF -dumpcap.exe : $(LIBS_CHECK) config.h svnversion.h $(dumpcap_OBJECTS) getopt.obj inet_ntop.obj mkstemp.obj wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\dumpcap.res +dumpcap.exe : $(LIBS_CHECK) config.h $(dumpcap_OBJECTS) wsutil\libwsutil.lib wiretap\wiretap-$(WTAP_VERSION).lib image\dumpcap.res @echo Linking $@ $(LINK) @<< - /OUT:dumpcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(dumpcap_LIBS) $(dumpcap_OBJECTS) getopt.obj inet_ntop.obj mkstemp.obj image\dumpcap.res + /OUT:dumpcap.exe $(conflags) $(conlibsdll) $(LDFLAGS) /SUBSYSTEM:console $(dumpcap_LIBS) $(dumpcap_OBJECTS) image\dumpcap.res << -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "dumpcap.exe.manifest" -outputresource:dumpcap.exe;1 !ENDIF @@ -349,38 +359,42 @@ config.h : config.h.win32 config.nmake -e "s/@HAVE_KFW@/$(KFW_CONFIG)/" \ -e "s/@HAVE_NETTLE@/$(NETTLE_CONFIG)/" \ -e "s/@HAVE_LIBZ@/$(ZLIB_CONFIG)/" \ + -e "s/@HAVE_GZCLEARERR@/$(ZLIB_GZCLEARERR_CONFIG)/" \ -e "s/@HAVE_LIBPCAP@/$(WINPCAP_CONFIG)/" \ -e "s/@HAVE_PCAP_FINDALLDEVS@/$(PCAP_FINDALLDEVS_CONFIG)/" \ -e "s/@HAVE_PCAP_DATALINK_NAME_TO_VAL@/$(PCAP_DATALINK_NAME_TO_VAL_CONFIG)/" \ -e "s/@HAVE_PCAP_DATALINK_VAL_TO_NAME@/$(PCAP_DATALINK_VAL_TO_NAME_CONFIG)/" \ + -e "s/@HAVE_PCAP_DATALINK_VAL_TO_DESCRIPTION@/$(PCAP_DATALINK_VAL_TO_DESCRIPTION_CONFIG)/" \ -e "s/@HAVE_PCAP_BREAKLOOP@/$(PCAP_BREAKLOOP_CONFIG)/" \ -e "s/@HAVE_REMOTE@/$(PCAP_HAVE_REMOTE_CONFIG)/" \ -e "s/@HAVE_PCAP_REMOTE@/$(PCAP_REMOTE_CONFIG)/" \ -e "s/@HAVE_PCAP_OPEN@/$(PCAP_OPEN_CONFIG)/" \ - -e "s/@HAVE_PCAP_LIST_DATALINKS@/$(PCAP_LIST_DATALINKS_CONFIG)/" \ - -e "s/@HAVE_PCAP_SET_DATALINK@/$(PCAP_SET_DATALINK_CONFIG)/" \ - -e "s/@HAVE_PCAP_FINDALLDEVS_EX@/$(PCAP_FINDALLDEVS_EX_CONFIG)/" \ - -e "s/@HAVE_PCAP_CREATESRCSTR@/$(PCAP_CREATESRCSTR_CONFIG)/" \ + -e "s/@HAVE_PCAP_OPEN_DEAD@/$(PCAP_OPEN_DEAD_CONFIG)/" \ + -e "s/@HAVE_PCAP_LIST_DATALINKS@/$(PCAP_LIST_DATALINKS_CONFIG)/" \ + -e "s/@HAVE_PCAP_FREE_DATALINKS@/$(PCAP_FREE_DATALINKS_CONFIG)/" \ + -e "s/@HAVE_PCAP_SET_DATALINK@/$(PCAP_SET_DATALINK_CONFIG)/" \ -e "s/@HAVE_PCAP_SETSAMPLING@/$(PCAP_SETSAMPLING_CONFIG)/" \ + -e "s/@HAVE_BPF_IMAGE@/$(BPF_IMAGE_CONFIG)/" \ -e "s/@HAVE_LIBWIRESHARKDLL@/$(LIBWIRESHARK_CONFIG)/" \ - -e "s/@WPCAP_CONSTIFIED@/$(WPCAP_CONSTIFIED_CONFIG)/" \ -e "s/@HAVE_LIBGNUTLS@/$(GNUTLS_CONFIG)/" \ -e "s/@HAVE_LIBGCRYPT@/$(LIBGCRYPT_CONFIG)/" \ -e "s/@HAVE_LUA@/$(LUA_CONFIG)/" \ -e "s/@HAVE_LUA_5_1@/$(LUA_VERSION)/" \ + -e "s/@HAVE_PYTHON@/$(PYTHON_CONFIG)/" \ -e "s/@HAVE_AIRPCAP@/$(AIRPCAP_CONFIG)/" \ -e "s/@HAVE_AIRPDCAP@/$(AIRPDCAP_CONFIG)/" \ -e "s/@HAVE_LIBPORTAUDIO@/$(PORTAUDIO_CONFIG)/" \ -e "s/@PORTAUDIO_API_1@/$(PORTAUDIO_API_CONFIG)/" \ -e "s/@HAVE_SMI@/$(SMI_CONFIG)/" \ -e "s/@HAVE_GEOIP@/$(GEOIP_CONFIG)/" \ + -e "s/@HAVE_NEW_PACKET_LIST@/$(NEW_PACKET_LIST_CONFIG)/" \ -e "s/@INET6@/$(INET6_CONFIG)/" \ -e "s/@HAVE_NTDDNDIS_H@/$(NTDDNDIS_CONFIG)/" \ < config.h.win32 > $@ -ps.c : rdps.py print.ps - $(PYTHON) rdps.py print.ps ps.c +ps.c: tools\rdps.py print.ps + $(PYTHON) tools\rdps.py print.ps ps.c # # Build the version string # @@ -393,18 +407,6 @@ svnversion.h: $(SVNENTRIES) rm -f svnversion.h $(PERL) make-version.pl -# -# Build the short version of the authors file for the about dialog -# -AUTHORS-SHORT: AUTHORS make-authors-short.pl - $(PERL) perlnoutf.pl make-authors-short.pl < AUTHORS > AUTHORS-SHORT - -# -# Build the short version of the authors file with formatting codes for -# the man page -# -AUTHORS-SHORT-FORMAT: AUTHORS-SHORT make-authors-format.pl - $(PERL) perlnoutf.pl make-authors-format.pl < AUTHORS-SHORT > AUTHORS-SHORT-FORMAT # # Build "tshark-tap-register.c", which contains a function @@ -421,9 +423,9 @@ AUTHORS-SHORT-FORMAT: AUTHORS-SHORT make-authors-format.pl # The second argument is the directory in which the source files live. # All subsequent arguments are the files to scan. # -tshark-tap-register.c: $(TSHARK_TAP_SRC) make-tapreg-dotc +tshark-tap-register.c: $(TSHARK_TAP_SRC) tools\make-tapreg-dotc @echo Making tshark-tap-register.c - @$(SH) make-tapreg-dotc tshark-tap-register.c . $(TSHARK_TAP_SRC) + @$(SH) tools/make-tapreg-dotc tshark-tap-register.c . $(TSHARK_TAP_SRC) text2pcap-scanner.c : text2pcap-scanner.l $(LEX) -otext2pcap-scanner.c text2pcap-scanner.l @@ -431,14 +433,33 @@ text2pcap-scanner.c : text2pcap-scanner.l text2pcap-scanner.obj : text2pcap-scanner.c $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $? +# +# The following targets will rebuild their respective objs +# if and when svnversion.h should change. +# + +text2pcap.obj : $*.c svnversion.h + $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $*.c + +mergecap.obj : $*.c svnversion.h + $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $*.c + +capinfos.obj : $*.c svnversion.h + $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $*.c + +editcap.obj : $*.c svnversion.h + $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $*.c + +version_info.obj : $*.c svnversion.h + $(CC) $(CVARSDLL) $(GENERATED_CFLAGS) -Fd.\ -c $*.c + clean-local: clean-deps rm -f $(wireshark_OBJECTS) $(tshark_OBJECTS) $(dumpcap_OBJECTS) $(rawshark_OBJECTS) \ - $(EXTRA_OBJECTS) $(EXECUTABLES) *.pdb *.exe.manifest \ + $(EXECUTABLES) *.pdb *.exe.manifest \ capinfos.obj editcap.obj mergecap.obj text2pcap.obj \ nio-ie5.obj update.obj \ text2pcap-scanner.obj text2pcap-scanner.c rdps.obj \ - rdps.pdb rdps.exe rdps.ilk config.h ps.c AUTHORS-SHORT \ - AUTHORS-SHORT-FORMAT $(LIBS_CHECK) \ + rdps.pdb rdps.exe rdps.ilk config.h ps.c $(LIBS_CHECK) \ dftest.obj dftest.exe randpkt.obj randpkt.ext \ doxygen.cfg \ $(RESOURCES) libwireshark.dll wiretap-$(WTAP_VERSION).dll \ @@ -456,6 +477,8 @@ clean: clean-local $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean cd ../gtk $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean + cd ../win32 + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean cd ../epan $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean cd ../plugins @@ -500,6 +523,8 @@ distclean: distclean-local $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean cd ../gtk $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean + cd ../win32 + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean cd ../epan $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean cd ../plugins @@ -535,6 +560,8 @@ maintainer-clean: maintainer-clean-local $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean cd ../gtk $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean + cd ../win32 + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean cd ../epan $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean cd ../plugins @@ -588,7 +615,7 @@ $(ADNS_DLL): set CFG=adns_dll - Win32 Release $(MAKE) /$(MAKEFLAGS) -f adns_dll.mak LOC="$(LOCAL_CFLAGS)" cd ..\lib -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "adns_dll.dll.manifest" -outputresource:adns_dll.dll;2 !ENDIF if not exist $(WIRESHARK_LIBS)\$(MSVC_VARIANT)\adns mkdir $(WIRESHARK_LIBS)\$(MSVC_VARIANT)\adns @@ -611,7 +638,7 @@ $(ZLIB_DLL): if not exist $(ZLIB_DIR) mkdir $(ZLIB_DIR) if not exist $(ZLIB_DIR)\lib mkdir $(ZLIB_DIR)\lib if not exist $(ZLIB_DIR)\include mkdir $(ZLIB_DIR)\include -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt.exe -nologo -manifest "zlib1.dll.manifest" -outputresource:zlib1.dll;2 !ENDIF copy zlib1.dll $(ZLIB_DIR) @@ -637,11 +664,16 @@ codecs:: $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake cd .. -gtk:: help config.h svnversion.h AUTHORS-SHORT doxygen +gtk:: help config.h svnversion.h doxygen cd gtk $(MAKE) /$(MAKEFLAGS) /f Makefile.nmake libui.lib cd .. +win32:: + cd win32 + $(MAKE) /$(MAKEFLAGS) /f Makefile.nmake libui_win32.lib + cd .. + epan:: $(RESOURCES) $(ZLIB_DLL) wiretap\wiretap-$(WTAP_VERSION).lib $(BUILT_SOURCES) doxygen cd epan $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake @@ -672,7 +704,9 @@ doxygen-run: !ENDIF doxygen: doxygen.cfg doxygen-run - + +services: tools\make-services.pl + $(PERL) tools/make-services.pl ################################################################################ # Prepare build environment by downloading and installing required libraries @@ -687,7 +721,7 @@ REQUIRED_TOOLS=\ $(CC) \ $(LINK) \ nmake \ -!IF $(MSC_VER_REQUIRED) >= 1400 +!IFDEF MANIFEST_INFO_REQUIRED mt \ !ENDIF $(SH_PROG) \ @@ -711,36 +745,33 @@ verify_tools: WIN_SETUP_OPT=--download !ENDIF -!IF 0 #### The library "tag" is now checked at the beginning of the make # Verify that the required library 'package' (zip) files have been downloaded. # (It seems reasonable to assume that if the files have been downloaded # then they have been installed). check_libs: $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake WIN_SETUP_OPT=--libverify process_libs -# Verify library packages only if Makefile.nmake has been updated -# (or dummy file doesn't exist because of 'make clean' or whatever) -# (To disable library verification when Makefile.nmake changes, -# comment out the commands for the following target). +# Verify library packages: +# If $(CHECK_TAG) is non-null then checktag failed; Exit with an error message. (See beginning of this Makefile). +# Otherwise do detailed library package files verification only if Makefile.nmake or config.make have been updated +# (or dummy file doesn't exist because of 'make clean' or whatever). +# Note that the creation/modification time of a file after an svn update of that file +# is the time of the update (not the time of the file in the repository). # touch is only called if libverify succeeds. -# (One microsec is added to the makefile.nmake time since the time set by [cygwin ?] 'touch --reference' -# apparently has the nanosecs truncated from the reference file time [at least on Windows Vista]). -$(LIBS_CHECK): Makefile.nmake - $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake WIN_SETUP_OPT=--libverify process_libs - @touch --reference=Makefile.nmake -d "+0.000001 sec" $@ -!ENDIF ### - -# Target for "libraries not up-to-date" -# Defined only if "checktag" failed (see beginning of Makefile). -!IF "$(LIBS_CHECK)" != "" -$(LIBS_CHECK): FORCE - @echo ^? Wireshark Libraries not up-to-date ^? - @echo ^? Do you need to run "nmake -f makefile.nmake setup" ^? +$(LIBS_CHECK): $(CHECK_TAG) config.nmake Makefile.nmake + @echo Verifying library package files ... + @$(MAKE) /$(MAKEFLAGS) -f Makefile.nmake WIN_SETUP_OPT=--libverify process_libs + @touch $@ + +# Target for "checktag failed" (libraries not up to date). +# Defined only if "checktag" failed (see beginning of this Makefile). +!IF "$(CHECK_TAG)" != "" +$(CHECK_TAG): _FORCE_ + @echo \? Wireshark Libraries not up-to-date \? + @echo \? Do you need to run "nmake -f Makefile.nmake setup" \? @echo. @exit 1 -FORCE: ## Assumption: no file named FORCE exists in the current directory - !ENDIF # Download (if needed) and install all the required libraries into WIRESHARK_LIBS. @@ -752,34 +783,16 @@ setup: verify_tools clean_setup process_libs # The process_libs target when invoked causes either a --libverify or a --download for all the required libraries. # (The choice is determined by the value of the macro WIN_SETUP_OPT). process_libs: -!IF 0 #### The library "tag" is now checked at the beginning of the make -!IF "$(WIN_SETUP_OPT)" == "--libverify" - @$(SH) $(WIN_SETUP) --checktag "$(WIRESHARK_LIBS)" -!ENDIF -!ENDIF - if not exist $(WIRESHARK_LIBS) md $(WIRESHARK_LIBS) -!IF "$(GTK_INST_VERSION)" == "2.16" || "$(GTK_INST_VERSION)" == "2.14" || "$(GTK_INST_VERSION)" == "2.12" - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - glib gtk$(GTK_INST_VERSION)/glib_$(GLIB_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - glib gtk$(GTK_INST_VERSION)/glib-dev_$(GLIB_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip -!ELSE -!ERROR ? Unknown or invalid GTK_INST_VERSION -!ENDIF -!IFDEF ICONV_DIR - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - libiconv-1.9.1.bin.woe32 libiconv-1.9.1.bin.woe32.zip -!ENDIF -!IF "$(WIRESHARK_TARGET_PLATFORM)" == "win32" - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gettext-runtime-0.17-1 gettext-runtime-0.17-1.zip -!ELSE + @if not exist $(WIRESHARK_LIBS) md $(WIRESHARK_LIBS) +!IFDEF GTK_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gettext-0.17-1 gettext$(GETTEXT_PKG).zip + gtk2 gtk+-bundle_$(GTK_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip !ENDIF !IFDEF KFW_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - . kfw-3.2.2-ws1.zip + . kfw-3-2-2-i386-ws-vc6.zip +# @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ +# . kfw-3-2-2.zip !ENDIF !IFDEF PCAP_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ @@ -787,11 +800,11 @@ process_libs: !ENDIF !IFDEF AIRPCAP_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - AirPcap_Devpack_1_0_0_594 AirPcap_Devpack_1_0_0_594.zip + AirPcap_Devpack_4_1_0_1622 AirPcap_Devpack_4_1_0_1622.zip !ENDIF !IFDEF C_ARES_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - . c-ares-1.6.0ws.zip + . c-ares-$(C_ARES_PKG)-$(WIRESHARK_TARGET_PLATFORM)ws.zip !ENDIF !IFDEF ADNS_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ @@ -812,9 +825,9 @@ process_libs: lua5.1.4 lua$(LUA_DIST)_lib.zip !ENDIF -!IFDEF GNUTLS_DIR +!IFDEF GNUTLS_PKG @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - . gnutls-2.6.4-1.zip + . gnutls-$(GNUTLS_PKG)-$(WIRESHARK_TARGET_PLATFORM)ws.zip !ENDIF !IFDEF PORTAUDIO_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ @@ -826,48 +839,15 @@ process_libs: !ENDIF !IFDEF GEOIP_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - . GeoIP-1.4.5ws.zip -!ENDIF - -!IFDEF GTK_DIR -!IF "$(GTK_INST_VERSION)" == "2.16" || "$(GTK_INST_VERSION)" == "2.14" || "$(GTK_INST_VERSION)" == "2.12" - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/gtk+_$(GTK_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/gtk+-dev_$(GTK_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/cairo_$(CAIRO_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/cairo-dev_$(CAIRO_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/atk_$(ATK_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/atk-dev_$(ATK_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/libpng_$(LIBPNG_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/$(TIFF_PKG).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/$(JPEG_PKG).zip -!ELSE -!ERROR ? Unknown or invalid GTK_INST_VERSION -!ENDIF -!IF "$(PANGO_INST_VERSION)" == "1.24" || "$(PANGO_INST_VERSION)" == "1.22" - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/pango_$(PANGO_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip - @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - gtk2 gtk$(GTK_INST_VERSION)/pango-dev_$(PANGO_PKG)_$(WIRESHARK_TARGET_PLATFORM).zip -!ELSE -!ERROR ? Unknown or invalid PANGO_INST_VERSION -!ENDIF + . GeoIP-1.4.6-$(WIRESHARK_TARGET_PLATFORM)ws.zip !ENDIF !IFDEF HHC_DIR @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - user-guide user-guide-28526.zip + user-guide user-guide-34434.zip !ENDIF !IFDEF UPX @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ - . upx301w.zip + . upx303w.zip !ENDIF !IFDEF NASM @$(SH) $(WIN_SETUP) "$(WIN_SETUP_OPT)" "$(WIRESHARK_LIBS)" \ @@ -884,39 +864,48 @@ process_libs: # WHEN UPDATING LIBRARY VERSIONS, KEEP ALSO ONE FORMER VERSION SO # UPDATING REMOVES THE FORMER USER DIRS clean_setup: - rm -r -f $(WIRESHARK_LIBS)/adns-1.0-win32-05ws - rm -r -f $(WIRESHARK_LIBS)/c-ares-1.5.3ws - rm -r -f $(WIRESHARK_LIBS)/c-ares-1.6.0ws - rm -r -f $(WIRESHARK_LIBS)/gettext-0.14.5 - rm -r -f $(WIRESHARK_LIBS)/gettext-runtime-0.17 - rm -r -f $(WIRESHARK_LIBS)/gettext-runtime-0.17-1 - rm -r -f $(WIRESHARK_LIBS)/gettext-0.17-1 # win64 - rm -r -f $(WIRESHARK_LIBS)/glib - rm -r -f $(WIRESHARK_LIBS)/gnutls-2.6.3-1 - rm -r -f $(WIRESHARK_LIBS)/gnutls-2.6.4-1 - rm -r -f $(WIRESHARK_LIBS)/gtk2 - rm -r -f $(WIRESHARK_LIBS)/gtk+ - rm -r -f $(WIRESHARK_LIBS)/gtk-wimp - rm -r -f $(WIRESHARK_LIBS)/kfw-2.5 - rm -r -f $(WIRESHARK_LIBS)/kfw-3.2.2-ws1 - rm -r -f $(WIRESHARK_LIBS)/libiconv-1.9.1.bin.woe32 - rm -r -f $(WIRESHARK_LIBS)/lua5.1 - rm -r -f $(WIRESHARK_LIBS)/lua5.1.4 - rm -r -f $(WIRESHARK_LIBS)/libsmi-0.4.5 - rm -r -f $(WIRESHARK_LIBS)/libsmi-0.4.8 - rm -r -f $(WIRESHARK_LIBS)/nasm-2.00 - rm -r -f $(WIRESHARK_LIBS)/nasm-2.02 - rm -r -f $(WIRESHARK_LIBS)/pcre-6.4 - rm -r -f $(WIRESHARK_LIBS)/pcre-7.0 - rm -r -f $(WIRESHARK_LIBS)/portaudio_v19 - rm -r -f $(WIRESHARK_LIBS)/portaudio_v19_2 - rm -r -f $(WIRESHARK_LIBS)/user-guide - rm -r -f $(WIRESHARK_LIBS)/WpdPack - rm -r -f $(WIRESHARK_LIBS)/AirPcap_Devpack_1_0_0_594 - rm -r -f $(WIRESHARK_LIBS)/zlib123 - rm -r -f $(WIRESHARK_LIBS)/zlib123-dll - rm -r -f $(WIRESHARK_LIBS)/upx301w - rm -r -f $(WIRESHARK_LIBS)/GeoIP-1.4.5ws + cd $(WIRESHARK_LIBS) + rm -r -f adns-1.0-win32-05ws + rm -r -f c-ares-1.5.3ws + rm -r -f c-ares-1.6.0ws + rm -r -f c-ares-1.7.0-win??ws + rm -r -f c-ares-1.7.1-win??ws + rm -r -f gettext-0.14.5 + rm -r -f gettext-runtime-0.17 + rm -r -f gettext-runtime-0.17-1 + rm -r -f gettext-0.17-1 # win64 + rm -r -f glib + rm -r -f gnutls-2.8.1-1 + rm -r -f gnutls-2.8.5-*-win??ws + rm -r -f gtk2 + rm -r -f gtk+ + rm -r -f gtk-wimp + rm -r -f kfw-2.5 + rm -r -f kfw-3.2.2-ws1 + rm -r -f kfw-3.2.2-i386-ws-vc6 + rm -r -f libiconv-1.9.1.bin.woe32 + rm -r -f lua5.1 + rm -r -f lua5.1.4 + rm -r -f libsmi-0.4.5 + rm -r -f libsmi-0.4.8 + rm -r -f nasm-2.00 + rm -r -f nasm-2.02 + rm -r -f pcre-6.4 + rm -r -f pcre-7.0 + rm -r -f portaudio_v19 + rm -r -f portaudio_v19_2 + rm -r -f user-guide + rm -r -f WpdPack + rm -r -f AirPcap_Devpack_1_0_0_594 + rm -r -f AirPcap_Devpack_4_0_0_1480 + rm -r -f AirPcap_Devpack_4_1_0_1622 + rm -r -f zlib123 + rm -r -f zlib123-dll + rm -r -f upx301w + rm -r -f upx303w + rm -r -f GeoIP-1.4.5ws + rm -r -f GeoIP-1.4.6-win??ws + cd $(MAKEDIR) ################################################################################ # Prepare the debug trees for running Wireshark/Tshark from there. @@ -940,7 +929,7 @@ debug-dumpcap: dumpcap.exe install-generated-files install-generated-files: set copycmd=/y if not exist $(INSTALL_DIR) mkdir $(INSTALL_DIR) -!IF "$(MSVC_VARIANT)" == "MSVC2008" +!IF DEFINED (MSVCR_DLL) && "$(MSVC_VARIANT)" == "MSVC2008" xcopy "$(MSVCR_DLL)" $(INSTALL_DIR)\*.* /d !ENDIF !IFDEF ENABLE_LIBWIRESHARK @@ -967,14 +956,13 @@ install-generated-files: if exist capinfos.pdb xcopy capinfos.pdb $(INSTALL_DIR) /d if exist editcap.exe xcopy editcap.exe $(INSTALL_DIR) /d if exist editcap.pdb xcopy editcap.pdb $(INSTALL_DIR) /d - xcopy ".\AUTHORS-SHORT" $(INSTALL_DIR) /d + xcopy "doc\AUTHORS-SHORT" $(INSTALL_DIR) /d xcopy ".\manuf" $(INSTALL_DIR) /d xcopy ".\services" $(INSTALL_DIR) /d - xcopy ".\README" $(INSTALL_DIR) /d - xcopy ".\README.win32" $(INSTALL_DIR) /d - xcopy ".\AUTHORS-SHORT" $(INSTALL_DIR) /d - xcopy ".\COPYING" $(INSTALL_DIR) /d - copy ".\NEWS" $(INSTALL_DIR)\NEWS.txt + $(TEXTIFY) "./COPYING" $(INSTALL_DIR) + $(TEXTIFY) "./NEWS" $(INSTALL_DIR) + $(TEXTIFY) "./README" $(INSTALL_DIR) + $(TEXTIFY) "./README.windows" $(INSTALL_DIR) xcopy ".\cfilters" $(INSTALL_DIR) /d xcopy ".\colorfilters" $(INSTALL_DIR) /d xcopy ".\dfilters" $(INSTALL_DIR) /d @@ -982,6 +970,12 @@ install-generated-files: !IFDEF LUA_DIR xcopy ".\epan\wslua\init.lua" $(INSTALL_DIR) /d xcopy ".\epan\wslua\console.lua" $(INSTALL_DIR) /d +!ENDIF +!IFDEF PYTHON_DIR + if not exist $(INSTALL_DIR)\python mkdir $(INSTALL_DIR)\python + xcopy ".\epan\wspython\register-dissector.py" $(INSTALL_DIR)\python /d + xcopy ".\epan\wspython\wspy_dissector.py" $(INSTALL_DIR)\python /d + xcopy ".\epan\wspython\wspy_libws.py" $(INSTALL_DIR)\python /d !ENDIF xcopy ipmap.html $(INSTALL_DIR) /d xcopy doc\*.html $(INSTALL_DIR) /d @@ -989,8 +983,7 @@ install-generated-files: xcopy ".\help\*.*" $(INSTALL_DIR)\help /d # you can't reliably use xcopy to rename files "on the fly" (so copy first, then rename) xcopy ".\help\faq.txt" $(INSTALL_DIR) /d - if exist $(INSTALL_DIR)\FAQ del $(INSTALL_DIR)\FAQ - ren $(INSTALL_DIR)\faq.txt FAQ + $(UNIX2DOS) $(INSTALL_DIR)/help/*.txt if not exist $(INSTALL_DIR)\dtds mkdir $(INSTALL_DIR)\dtds xcopy ".\dtds\*.*" $(INSTALL_DIR)\dtds /d if not exist $(INSTALL_DIR)\asn1 mkdir $(INSTALL_DIR)\asn1 @@ -1006,9 +999,9 @@ install-generated-files: xcopy ".\wimaxasncp\*.*" $(INSTALL_DIR)\wimaxasncp /d if not exist $(INSTALL_DIR)\plugins mkdir $(INSTALL_DIR)\plugins if not exist $(INSTALL_DIR)\plugins\$(VERSION) mkdir $(INSTALL_DIR)\plugins\$(VERSION) - cd plugins - $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake install-plugins - cd .. + cd plugins + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake install-plugins + cd .. # "install-all" will copy all files needed to run Wireshark/Tshark # to the INSTALL_DIR, so you can run/debug Wireshark/Tshark from there. @@ -1029,21 +1022,14 @@ install-all: install-generated-files if not exist $(INSTALL_DIR)\lib\gtk-2.0\modules mkdir $(INSTALL_DIR)\lib\gtk-2.0\modules if not exist $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR) mkdir $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR) if not exist $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\loaders mkdir $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\loaders -# if not exist $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\immodules mkdir $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\immodules if not exist $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\engines mkdir $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\engines -# if not exist $(INSTALL_DIR)\lib\pango mkdir $(INSTALL_DIR)\lib\pango -# if not exist $(INSTALL_DIR)\lib\pango\$(PANGO_LIB_DIR) mkdir $(INSTALL_DIR)\lib\pango\$(PANGO_LIB_DIR) -# if not exist $(INSTALL_DIR)\lib\pango\$(PANGO_LIB_DIR)\modules mkdir $(INSTALL_DIR)\lib\pango\$(PANGO_LIB_DIR)\modules xcopy $(GTK_DIR)\etc\gtk-2.0\*.* $(INSTALL_DIR)\etc\gtk-2.0 /d if exist $(GTK_DIR)\etc\pango xcopy $(GTK_DIR)\etc\pango\pango.* $(INSTALL_DIR)\etc\pango /d if exist $(GTK_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\loaders xcopy $(GTK_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\loaders\libpixbufloader-*.dll $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\loaders /d xcopy $(GTK_DIR)\lib\gtk-2.0\modules\libgail.dll $(INSTALL_DIR)\lib\gtk-2.0\modules /d xcopy $(GTK_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\engines\libpixmap.dll $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\engines /d -# xcopy $(GTK_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\immodules\im-*.dll $(INSTALL_DIR)\lib\gtk-2.0\$(GTK_LIB_DIR)\immodules /d -# xcopy $(GTK_DIR)\lib\pango\$(PANGO_LIB_DIR)\modules\pango-*.dll $(INSTALL_DIR)\lib\pango\$(PANGO_LIB_DIR)\modules /d !IFDEF NEED_LIBPNG_DLL -# xcopy $(GTK_DIR)\bin\libpng13.dll $(INSTALL_DIR) /d - xcopy $(GTK_DIR)\bin\libpng12-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\$(PNG_DLL) $(INSTALL_DIR) /d !ENDIF !IFDEF NEED_LIBTIFF_DLL xcopy $(GTK_DIR)\bin\$(TIFF_DLL) $(INSTALL_DIR) /d @@ -1054,19 +1040,27 @@ install-all: install-generated-files !IFDEF NEED_CAIRO_DLL xcopy $(GTK_DIR)\bin\libcairo-2.dll $(INSTALL_DIR) /d xcopy $(GTK_DIR)\bin\libpangocairo-1.0-0.dll $(INSTALL_DIR) /d +!ENDIF +!IFDEF NEED_FREETYPE_DLL + xcopy $(GTK_DIR)\bin\libpangoft2-1.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\$(FREETYPE_DLL) $(INSTALL_DIR) /d +!ENDIF +!IFDEF NEED_FONTCONFIG_DLL + xcopy $(GTK_DIR)\bin\$(FONTCONFIG_DLL) $(INSTALL_DIR) /d +!ENDIF +!IFDEF NEED_EXPAT_DLL + xcopy $(GTK_DIR)\bin\$(EXPAT_DLL) $(INSTALL_DIR) /d !ENDIF if not exist $(INSTALL_DIR)\$(GTK_WIMP_DLLDST_DIR) mkdir $(INSTALL_DIR)\$(GTK_WIMP_DLLDST_DIR) xcopy "$(GTK_WIMP_DLLSRC_DIR)\libwimp.dll" $(INSTALL_DIR)\$(GTK_WIMP_DLLDST_DIR) /d if not exist $(INSTALL_DIR)\$(GTK_WIMP_RCDST_DIR) mkdir $(INSTALL_DIR)\$(GTK_WIMP_RCDST_DIR) xcopy "$(GTK_WIMP_RCSRC_DIR)\gtkrc" $(INSTALL_DIR)\$(GTK_WIMP_RCDST_DIR) /d - xcopy $(GLIB_DIR)\bin\libgio-2.0-0.dll $(INSTALL_DIR) /d - xcopy $(GLIB_DIR)\bin\libglib-2.0-0.dll $(INSTALL_DIR) /d - xcopy $(GLIB_DIR)\bin\libgmodule-2.0-0.dll $(INSTALL_DIR) /d - xcopy $(GLIB_DIR)\bin\libgobject-2.0-0.dll $(INSTALL_DIR) /d -!IFDEF ICONV_DIR - xcopy $(ICONV_DIR)\bin\iconv.dll $(INSTALL_DIR) /d -!ENDIF - xcopy $(GETTEXT_DIR)\bin\$(GETTEXT_DLL) $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\libgio-2.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\libglib-2.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\libgmodule-2.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\libgobject-2.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\libgthread-2.0-0.dll $(INSTALL_DIR) /d + xcopy $(GTK_DIR)\bin\$(INTL_DLL) $(INSTALL_DIR) /d !IFDEF ZLIB_DIR xcopy $(ZLIB_DLL) $(INSTALL_DIR) /d !ENDIF @@ -1081,15 +1075,13 @@ install-all: install-generated-files xcopy $(PCRE_DIR)\man\cat3\pcrepattern.3.txt $(INSTALL_DIR) /d !ENDIF !IFDEF KFW_DIR - xcopy $(KFW_DIR)\bin\comerr32.dll $(INSTALL_DIR) /d - xcopy $(KFW_DIR)\bin\krb5_32.dll $(INSTALL_DIR) /d - xcopy $(KFW_DIR)\bin\k5sprt32.dll $(INSTALL_DIR) /d + xcopy $(KFW_PATH)\comerr32.dll $(INSTALL_DIR) /d + xcopy $(KFW_PATH)\krb5_32.dll $(INSTALL_DIR) /d + xcopy $(KFW_PATH)\k5sprt32.dll $(INSTALL_DIR) /d !ENDIF !IFDEF GNUTLS_DIR xcopy $(GNUTLS_DIR)\bin\libgcrypt-11.dll $(INSTALL_DIR) /d xcopy $(GNUTLS_DIR)\bin\libgnutls-26.dll $(INSTALL_DIR) /d - xcopy $(GNUTLS_DIR)\bin\libgnutls-extra-26.dll $(INSTALL_DIR) /d - xcopy $(GNUTLS_DIR)\bin\libgnutls-openssl-26.dll $(INSTALL_DIR) /d xcopy $(GNUTLS_DIR)\bin\libgpg-error-0.dll $(INSTALL_DIR) /d xcopy $(GNUTLS_DIR)\bin\libtasn1-3.dll $(INSTALL_DIR) /d !ENDIF @@ -1122,6 +1114,8 @@ checkapi: checkapi_local $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi cd ../gtk $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi + cd ../win32 + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi cd ../epan ## $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi cd ../epan/crypt @@ -1139,3 +1133,7 @@ checkapi: checkapi_local $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi cd ../wsutil $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake checkapi + +#### +_FORCE_: ## Assumption: no file named _FORCE_ exists in the current directory +