diff options
author | Jeff Morriss <jeff.morriss@ulticom.com> | 2008-05-20 21:51:01 +0000 |
---|---|---|
committer | Jeff Morriss <jeff.morriss@ulticom.com> | 2008-05-20 21:51:01 +0000 |
commit | 58459d3fba39398b53294beccc307d539bd0db33 (patch) | |
tree | 7d78ccd8aad555faaf4ef91c0acc48b9a04ff2de | |
parent | 5364227de00058969236206467448325f4c823b6 (diff) |
Create a new "Wireshark utility" library and move the mpeg-audio stuff from
wiretap to this new libwsutil. This solves
http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1677 by making libwireshark
no longer depend on libwiretap.
svn path=/trunk/; revision=25330
-rw-r--r-- | Makefile.am | 16 | ||||
-rw-r--r-- | Makefile.nmake | 31 | ||||
-rw-r--r-- | asn1/mpeg-audio/packet-mpeg-audio-template.c | 2 | ||||
-rw-r--r-- | configure.in | 1 | ||||
-rw-r--r-- | epan/Makefile.nmake | 1 | ||||
-rw-r--r-- | epan/dissectors/packet-mpeg-audio.c | 12 | ||||
-rw-r--r-- | image/Makefile.nmake | 7 | ||||
-rw-r--r-- | image/libwsutil.rc.in | 34 | ||||
-rw-r--r-- | packaging/nsis/Makefile.nmake | 2 | ||||
-rw-r--r-- | packaging/nsis/wireshark.nsi | 1 | ||||
-rw-r--r-- | wiretap/Makefile.am | 2 | ||||
-rw-r--r-- | wiretap/Makefile.common | 2 | ||||
-rw-r--r-- | wiretap/Makefile.nmake | 1 | ||||
-rw-r--r-- | wiretap/libwiretap.vcproj | 8 | ||||
-rw-r--r-- | wiretap/mpeg.c | 2 | ||||
-rw-r--r-- | wiretap/wtap.def | 7 | ||||
-rw-r--r-- | wsutil/Makefile.am | 46 | ||||
-rw-r--r-- | wsutil/Makefile.nmake | 51 | ||||
-rw-r--r-- | wsutil/libwsutil.def | 17 | ||||
-rw-r--r-- | wsutil/mpeg-audio.c (renamed from wiretap/mpeg-audio.c) | 0 | ||||
-rw-r--r-- | wsutil/mpeg-audio.h (renamed from wiretap/mpeg-audio.h) | 0 |
21 files changed, 208 insertions, 35 deletions
diff --git a/Makefile.am b/Makefile.am index 09f23686ca..1056a534b3 100644 --- a/Makefile.am +++ b/Makefile.am @@ -310,6 +310,7 @@ wireshark_LDADD = \ codecs/libcodec.a \ wiretap/libwiretap.la \ epan/libwireshark.la \ + wsutil/libwsutil.la \ @INET_PTON_LO@ \ @SSL_LIBS@ \ $(plugin_ldadd) \ @@ -332,6 +333,7 @@ tshark_LDADD = \ $(wireshark_optional_objects) \ wiretap/libwiretap.la \ epan/libwireshark.la \ + wsutil/libwsutil.la \ @INET_PTON_LO@ \ @SSL_LIBS@ \ $(plugin_ldadd) \ @@ -355,6 +357,7 @@ rawshark_LDADD = \ $(wireshark_optional_objects) \ wiretap/libwiretap.la \ epan/libwireshark.la \ + wsutil/libwsutil.la \ @INET_PTON_LO@ \ @SSL_LIBS@ \ $(plugin_ldadd) \ @@ -375,26 +378,31 @@ text2pcap_optional_objects = @STRERROR_O@ @STRPTIME_O@ text2pcap_LDADD = \ $(text2pcap_optional_objects) \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @GLIB_LIBS@ -lm # Libraries with which to link mergecap. mergecap_LDADD = \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @GLIB_LIBS@ # Libraries with which to link capinfos. capinfos_LDADD = \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @GLIB_LIBS@ # Libraries with which to link editcap. editcap_LDADD = \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @GLIB_LIBS@ # Libraries with which to link randpkt. randpkt_LDADD = \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @GLIB_LIBS@ -lm \ @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @ADNS_LIBS@ @@ -402,6 +410,7 @@ randpkt_LDADD = \ dftest_LDADD = \ $(wireshark_optional_objects) \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ epan/libwireshark.la \ @SSL_LIBS@ \ $(plugin_ldadd) \ @@ -416,6 +425,7 @@ dftest_LDADD = \ # Libraries with which to link dumpcap. dumpcap_LDADD = \ wiretap/libwiretap.la \ + wsutil/libwsutil.la \ @INET_NTOP_LO@ \ @GLIB_LIBS@ \ @PCAP_LIBS@ @SOCKET_LIBS@ @NSL_LIBS@ @FRAMEWORKS@ \ @@ -764,12 +774,12 @@ else install-exec-hook: endif -DIST_SUBDIRS = asn1 codecs doc epan gtk help packaging plugins tools wiretap +DIST_SUBDIRS = asn1 codecs doc epan gtk help packaging plugins tools wiretap wsutil if HAVE_PLUGINS -SUBDIRS = tools wiretap doc epan plugins packaging help @wireshark_SUBDIRS@ +SUBDIRS = tools wsutil wiretap doc epan plugins packaging help @wireshark_SUBDIRS@ else -SUBDIRS = tools wiretap doc epan packaging help @wireshark_SUBDIRS@ +SUBDIRS = tools wsutil wiretap doc epan packaging help @wireshark_SUBDIRS@ endif wireshark.1: doc/wireshark.pod AUTHORS-SHORT-FORMAT diff --git a/Makefile.nmake b/Makefile.nmake index b43418ac42..18c9d7f4ce 100644 --- a/Makefile.nmake +++ b/Makefile.nmake @@ -53,6 +53,7 @@ wireshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ epan\crypt\airpdcap.lib \ epan\dfilter\dfilter.lib \ epan\ftypes\ftypes.lib \ + wsutil\libwsutil.lib \ $(ADNS_LIBS) \ $(PCRE_LIBS) \ $(ZLIB_LIBS) \ @@ -70,6 +71,7 @@ tshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ epan\crypt\airpdcap.lib \ epan\dfilter\dfilter.lib \ epan\ftypes\ftypes.lib \ + wsutil\libwsutil.lib \ $(ADNS_LIBS) \ $(PCRE_LIBS) \ $(ZLIB_LIBS) \ @@ -87,6 +89,7 @@ rawshark_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ epan\crypt\airpdcap.lib \ epan\dfilter\dfilter.lib \ epan\ftypes\ftypes.lib \ + wsutil\libwsutil.lib \ $(ADNS_LIBS) \ $(PCRE_LIBS) \ $(ZLIB_LIBS) \ @@ -95,22 +98,27 @@ 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) editcap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib shell32.lib \ + wsutil\libwsutil.lib \ $(GLIB_LIBS) mergecap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib \ + wsutil\libwsutil.lib \ $(GLIB_LIBS) text2pcap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib \ + wsutil\libwsutil.lib \ $(GLIB_LIBS) dumpcap_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ wsock32.lib user32.lib \ + wsutil\libwsutil.lib \ $(GLIB_LIBS) dftest_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ @@ -122,6 +130,7 @@ dftest_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ epan\dissectors\dissectors.lib \ epan\wireshark.lib \ epan\dfilter\dfilter.lib epan\ftypes\ftypes.lib \ + wsutil\libwsutil.lib \ $(ADNS_LIBS) \ $(PCRE_LIBS) \ $(ZLIB_LIBS) \ @@ -131,6 +140,7 @@ dftest_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ randpkt_LIBS= wiretap\wiretap-$(WTAP_VERSION).lib \ user32.lib \ + wsutil\libwsutil.lib \ $(GLIB_LIBS) EXECUTABLES=wireshark.exe tshark.exe rawshark.exe \ @@ -139,11 +149,11 @@ EXECUTABLES=wireshark.exe tshark.exe rawshark.exe \ RESOURCES=image\wireshark.res image\libwireshark.res image\tshark.res \ image\capinfos.res image\editcap.res image\mergecap.res \ image\text2pcap.res image\wiretap.res image\dumpcap.res \ - image\rawshark.res + image\rawshark.res image\libwsutil.res LIBS_CHECK=_libs_check_ -all: $(LIBS_CHECK) config.h tools image codecs $(ADNS_DLL) $(ZLIB_DLL) wiretap epan $(EXECUTABLES) $(RESOURCES) doc install-all +all: $(LIBS_CHECK) config.h tools image codecs $(ADNS_DLL) $(ZLIB_DLL) wsutil wiretap epan $(EXECUTABLES) $(RESOURCES) doc install-all packaging: all cd packaging @@ -367,13 +377,15 @@ clean-local: clean-deps AUTHORS-SHORT-FORMAT $(LIBS_CHECK) \ dftest.obj dftest.exe randpkt.obj randpkt.ext \ doxygen.cfg \ - $(RESOURCES) libwireshark.dll wiretap-$(WTAP_VERSION).dll + $(RESOURCES) libwireshark.dll wiretap-$(WTAP_VERSION).dll \ + libwsutil.dll clean: clean-local cd asn1 $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean - cd .. - cd wiretap + cd ../wiretap + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean + cd ../wsutil $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean cd ../codecs $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake clean @@ -417,6 +429,8 @@ distclean-local: clean-local distclean: distclean-local cd wiretap $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean + cd ../wsutil + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean cd ../codecs $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake distclean cd ../gtk @@ -450,6 +464,8 @@ maintainer-clean-local: distclean-local maintainer-clean: maintainer-clean-local cd wiretap $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean + cd ../wsutil + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean cd ../codecs $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake maintainer-clean cd ../gtk @@ -541,6 +557,10 @@ $(ZLIB_DLL): rm -r -f zlib.tmp !ENDIF +wsutil:: + cd wsutil + $(MAKE) /$(MAKEFLAGS) -f Makefile.nmake + cd .. wiretap:: cd wiretap @@ -845,6 +865,7 @@ install-generated-files: xcopy ".\wiretap\wiretap-$(WTAP_VERSION).dll" $(INSTALL_DIR) /d if exist ".\wiretap\wiretap-$(WTAP_VERSION).pdb" xcopy ".\wiretap\wiretap-$(WTAP_VERSION).pdb" $(INSTALL_DIR) /d xcopy ".\epan\libwireshark.dll" $(INSTALL_DIR) /d + xcopy ".\wsutil\libwsutil.dll" $(INSTALL_DIR) /d if exist ".\epan\libwireshark.pdb" xcopy ".\epan\libwireshark.pdb" $(INSTALL_DIR) /d if exist wireshark.exe copy wireshark.exe $(INSTALL_DIR)\wireshark.exe if exist wireshark.pdb copy wireshark.pdb $(INSTALL_DIR)\wireshark.pdb diff --git a/asn1/mpeg-audio/packet-mpeg-audio-template.c b/asn1/mpeg-audio/packet-mpeg-audio-template.c index b65eed8b5f..c90a29ba32 100644 --- a/asn1/mpeg-audio/packet-mpeg-audio-template.c +++ b/asn1/mpeg-audio/packet-mpeg-audio-template.c @@ -35,7 +35,7 @@ #include <epan/prefs.h> #include <epan/asn1.h> -#include <wiretap/mpeg-audio.h> +#include <wsutil/mpeg-audio.h> #include "packet-per.h" diff --git a/configure.in b/configure.in index a32cf27322..fa507109e5 100644 --- a/configure.in +++ b/configure.in @@ -1594,6 +1594,7 @@ AC_OUTPUT( tools/idl2wrs.sh tools/lemon/Makefile wiretap/Makefile + wsutil/Makefile ,) dnl AC_CONFIG_FILES([tools/setuid-root.pl], [chmod +x tools/setuid-root.pl]) diff --git a/epan/Makefile.nmake b/epan/Makefile.nmake index aaa06b5d0a..3013e8d2da 100644 --- a/epan/Makefile.nmake +++ b/epan/Makefile.nmake @@ -36,6 +36,7 @@ libwireshark_LIBS = \ $(GNUTLS_LIBS) \ $(LUA_LIBS) \ $(SMI_LIBS) \ + ..\wsutil\wsutil.lib \ ..\wiretap\wiretap-$(WTAP_VERSION).lib \ !IFDEF ICONV_DIR $(ICONV_DIR)\lib\iconv.lib \ diff --git a/epan/dissectors/packet-mpeg-audio.c b/epan/dissectors/packet-mpeg-audio.c index ba5370b631..6a068987e3 100644 --- a/epan/dissectors/packet-mpeg-audio.c +++ b/epan/dissectors/packet-mpeg-audio.c @@ -1,7 +1,7 @@ /* Do not modify this file. */ /* It is created automatically by the ASN.1 to Wireshark dissector compiler */ /* packet-mpeg-audio.c */ -/* ../../../tools/asn2wrs.py -p mpeg-audio -c ../../../asn1/mpeg-audio/mpeg-audio.cnf -s ../../../asn1/mpeg-audio/packet-mpeg-audio-template -D ../../../asn1/mpeg-audio mpeg-audio.asn */ +/* ../../tools/asn2wrs.py -p mpeg-audio -c ./mpeg-audio.cnf -s ./packet-mpeg-audio-template -D . mpeg-audio.asn */ /* Input file: packet-mpeg-audio-template.c */ @@ -43,7 +43,7 @@ #include <epan/prefs.h> #include <epan/asn1.h> -#include <wiretap/mpeg-audio.h> +#include <wsutil/mpeg-audio.h> #include "packet-per.h" @@ -153,7 +153,7 @@ dissect_mpeg_audio_T_protection(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *a static int dissect_mpeg_audio_INTEGER_0_15(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, - 0U, 15U, NULL, FALSE); + 0U, 15U, NULL, FALSE); return offset; } @@ -163,7 +163,7 @@ dissect_mpeg_audio_INTEGER_0_15(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *a static int dissect_mpeg_audio_INTEGER_0_3(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, - 0U, 3U, NULL, FALSE); + 0U, 3U, NULL, FALSE); return offset; } @@ -284,7 +284,7 @@ dissect_mpeg_audio_OCTET_STRING_SIZE_28(tvbuff_t *tvb _U_, int offset _U_, asn1_ static int dissect_mpeg_audio_INTEGER_0_255(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, - 0U, 255U, NULL, FALSE); + 0U, 255U, NULL, FALSE); return offset; } @@ -424,7 +424,7 @@ static const value_string mpeg_audio_T_genre_vals[] = { static int dissect_mpeg_audio_T_genre(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, - 0U, 255U, NULL, FALSE); + 0U, 255U, NULL, FALSE); return offset; } diff --git a/image/Makefile.nmake b/image/Makefile.nmake index 0200094ac1..e0b929fdc8 100644 --- a/image/Makefile.nmake +++ b/image/Makefile.nmake @@ -6,7 +6,7 @@ include ..\config.nmake # Nmake uses an implicit rule to build a .res from a .rc file! -ALL_RC=wireshark.rc libwireshark.rc tshark.rc rawshark.rc capinfos.rc editcap.rc text2pcap.rc mergecap.rc wiretap.rc dumpcap.rc wireshark.exe.manifest +ALL_RC=wireshark.rc libwireshark.rc tshark.rc rawshark.rc capinfos.rc editcap.rc text2pcap.rc mergecap.rc wiretap.rc dumpcap.rc libwsutil.rc wireshark.exe.manifest all : $(ALL_RC) wireshark.exe.manifest: wireshark.exe.manifest.in ..\config.nmake @@ -60,6 +60,11 @@ wiretap.rc : wiretap.rc.in ..\config.nmake -e s/@RC_VERSION@/$(RC_WTAP_VERSION)/ \ < wiretap.rc.in > $@ +libwsutil.rc : libwsutil.rc.in ..\config.nmake + sed -e s/@VERSION@/$(VERSION)/ \ + -e s/@RC_VERSION@/$(RC_VERSION)/ \ + < libwsutil.rc.in > $@ + dumpcap.rc : dumpcap.rc.in ..\config.nmake sed -e s/@VERSION@/$(VERSION)/ \ -e s/@RC_VERSION@/$(RC_VERSION)/ \ diff --git a/image/libwsutil.rc.in b/image/libwsutil.rc.in new file mode 100644 index 0000000000..22209255bb --- /dev/null +++ b/image/libwsutil.rc.in @@ -0,0 +1,34 @@ +#include "winver.h" + +VS_VERSION_INFO VERSIONINFO + FILEVERSION @RC_VERSION@ + PRODUCTVERSION @RC_VERSION@ + FILEFLAGSMASK 0x0L +#ifdef _DEBUG + FILEFLAGS VS_FF_DEBUG +#else + FILEFLAGS 0x0L +#endif + FILEOS VOS_NT_WINDOWS32 + FILETYPE VFT_DLL + FILESUBTYPE 0x0L +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904b0" + BEGIN + VALUE "CompanyName", "The Wireshark developer community, http://www.wireshark.org/\0" + VALUE "FileDescription", "Wireshark utility library\0" + VALUE "FileVersion", "@VERSION@\0" + VALUE "InternalName", "libwsutil @VERSION@\0" + VALUE "LegalCopyright", "Copyright © 2000 Gerald Combs <gerald@wireshark.org>, Gilbert Ramirez <gram@alumni.rice.edu> and others\0" + VALUE "OriginalFilename", "libwsutil.dll\0" + VALUE "ProductName", "Wireshark\0" + VALUE "ProductVersion", "@VERSION@\0" + END + END + BLOCK "VarFileInfo" + BEGIN + VALUE "Translation", 0x409, 1200 + END +END diff --git a/packaging/nsis/Makefile.nmake b/packaging/nsis/Makefile.nmake index 597cd66cc3..c2cb833398 100644 --- a/packaging/nsis/Makefile.nmake +++ b/packaging/nsis/Makefile.nmake @@ -17,7 +17,7 @@ EXE=../../tshark.exe ../../editcap.exe \ ../../wireshark.exe \ !ENDIF ../../text2pcap.exe ../../mergecap.exe ../../capinfos.exe WinPcap_4_0_2.exe -DLL=../../wiretap/wiretap-$(WTAP_VERSION).dll +DLL=../../wiretap/wiretap-$(WTAP_VERSION).dll ../../wsutil/libwsutil.dll DOC=../../doc/ws.css \ ../../doc/capinfos.html \ ../../doc/dumpcap.html \ diff --git a/packaging/nsis/wireshark.nsi b/packaging/nsis/wireshark.nsi index 8586938d88..c264aff698 100644 --- a/packaging/nsis/wireshark.nsi +++ b/packaging/nsis/wireshark.nsi @@ -294,6 +294,7 @@ File "..\..\wiretap\wiretap-${WTAP_VERSION}.dll" !ifdef ENABLE_LIBWIRESHARK File "..\..\epan\libwireshark.dll" !endif +File "..\..\wsutil\libwsutil.dll" File "${GLIB_DIR}\bin\libglib-2.0-0.dll" File "${GLIB_DIR}\bin\libgobject-2.0-0.dll" File "${GLIB_DIR}\bin\libgmodule-2.0-0.dll" diff --git a/wiretap/Makefile.am b/wiretap/Makefile.am index 179f1ec729..273799ecbb 100644 --- a/wiretap/Makefile.am +++ b/wiretap/Makefile.am @@ -35,6 +35,8 @@ if HAVE_WARNINGS_AS_ERRORS AM_NON_GENERATED_CFLAGS = -Werror endif +INCLUDES = -I$(srcdir)/.. + CLEANFILES = \ libwiretap.a \ libwiretap.la \ diff --git a/wiretap/Makefile.common b/wiretap/Makefile.common index 5b86801f37..a9d96e9ef7 100644 --- a/wiretap/Makefile.common +++ b/wiretap/Makefile.common @@ -54,7 +54,6 @@ NONGENERATED_C_FILES = \ lanalyzer.c \ libpcap.c \ mpeg.c \ - mpeg-audio.c \ netmon.c \ netscreen.c \ nettl.c \ @@ -99,7 +98,6 @@ NONGENERATED_HEADER_FILES = \ lanalyzer.h \ libpcap.h \ mpeg.h \ - mpeg-audio.h \ netmon.h \ netscreen.h \ nettl.h \ diff --git a/wiretap/Makefile.nmake b/wiretap/Makefile.nmake index 7b60aef4e0..425de19459 100644 --- a/wiretap/Makefile.nmake +++ b/wiretap/Makefile.nmake @@ -21,6 +21,7 @@ OBJECTS=$(NONGENERATED_C_FILES:.c=.obj) $(GENERATED_C_FILES:.c=.obj) file_util.o wiretap_LIBS = \ $(GLIB_LIBS) \ + ..\wsutil\wsutil.lib \ $(ZLIB_LIBS) all: checkapi wiretap-$(WTAP_VERSION).dll diff --git a/wiretap/libwiretap.vcproj b/wiretap/libwiretap.vcproj index 82ada99379..438d5373c6 100644 --- a/wiretap/libwiretap.vcproj +++ b/wiretap/libwiretap.vcproj @@ -156,10 +156,6 @@ >
</File>
<File
- RelativePath=".\mpeg-audio.c"
- >
- </File>
- <File
RelativePath=".\mpeg.c"
>
</File>
@@ -322,10 +318,6 @@ >
</File>
<File
- RelativePath=".\mpeg-audio.h"
- >
- </File>
- <File
RelativePath=".\mpeg.h"
>
</File>
diff --git a/wiretap/mpeg.c b/wiretap/mpeg.c index 1e15045cc0..8ec9e65fbe 100644 --- a/wiretap/mpeg.c +++ b/wiretap/mpeg.c @@ -35,7 +35,7 @@ #endif #include "mpeg.h" -#include "mpeg-audio.h" +#include "wsutil/mpeg-audio.h" #include "wtap-int.h" #include "buffer.h" diff --git a/wiretap/wtap.def b/wiretap/wtap.def index 573a0e0eed..ce8f7eeaeb 100644 --- a/wiretap/wtap.def +++ b/wiretap/wtap.def @@ -28,13 +28,6 @@ file_seek file_tell file_error -mpa_bitrate -mpa_frequency -mpa_layer -mpa_padding -mpa_samples -mpa_version - wtap_buf_ptr wtap_close wtap_dump diff --git a/wsutil/Makefile.am b/wsutil/Makefile.am new file mode 100644 index 0000000000..f99671e773 --- /dev/null +++ b/wsutil/Makefile.am @@ -0,0 +1,46 @@ +# Makefile.am +# +# $Id$ +# +# Wireshark - Network traffic analyzer +# By Gerald Combs <gerald@wireshark.org> +# Copyright 1998 Gerald Combs +# +# +# This program is free software; you can redistribute it and/or +# modify it under the terms of the GNU General Public License +# as published by the Free Software Foundation; either version 2 +# of the License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +if HAVE_WARNINGS_AS_ERRORS +AM_CFLAGS = -Werror +endif + +lib_LTLIBRARIES = libwsutil.la + +CLEANFILES = \ + libwsutil.a \ + libwsutil.la \ + *~ + +MAINTAINERCLEANFILES = \ + Makefile.in + +libwsutil_la_SOURCES = \ + mpeg-audio.c \ + mpeg-audio.h + +libwsutil_la_LIBADD = @GLIB_LIBS@ + +EXTRA_DIST = \ + Makefile.nmake + diff --git a/wsutil/Makefile.nmake b/wsutil/Makefile.nmake new file mode 100644 index 0000000000..1a275bfd64 --- /dev/null +++ b/wsutil/Makefile.nmake @@ -0,0 +1,51 @@ +## Makefile for building wireshark.exe with Microsoft C and nmake +## Use: $(MAKE) /$(MAKEFLAGS) -f makefile.nmake +# +# $Id$ + +include ..\config.nmake +include <win32.mak> +include ..\Makefile.nmake.inc + +############### no need to modify below this line ######### + +CFLAGS=-WX -DHAVE_CONFIG_H /I. /I.. $(GLIB_CFLAGS) \ + /I$(PCAP_DIR)\include -D_U_="" $(LOCAL_CFLAGS) + +CVARSDLL=-DWIN32 -DNULL=0 -D_MT -D_DLL + +.c.obj:: + $(CC) $(CVARSDLL) $(CFLAGS) -Fd.\ -c $< + + +libwsutil_LIBS = + +OBJECTS = \ + mpeg-audio.obj + + +libwsutil.lib: libwsutil.dll +libwsutil.exp: libwsutil.dll + +libwsutil.dll : $(OBJECTS) libwsutil.def ..\image\libwsutil.res + $(link) $(dlllflags) $(conlibsdll) \ + $(LOCAL_LDFLAGS) \ + /DEF:libwsutil.def /OUT:libwsutil.dll \ + /IMPLIB:libwsutil.lib \ + ..\image\libwsutil.res \ + $(OBJECTS) $(libwsutil_LIBS) +!IF "$(MSVC_VARIANT)" == "MSVC2005" || "$(MSVC_VARIANT)" == "MSVC2005EE" || "$(MSVC_VARIANT)" == "DOTNET20" + mt.exe -nologo -manifest "libwsutil.dll.manifest" -outputresource:libwsutil.dll;2 +!ENDIF + +clean : + rm -f $(OBJECTS) \ + libwsutil.lib \ + libwsutil.exp \ + libwsutil.dll \ + libwsutil.dll.manifest \ + *.pdb + +distclean: clean + +maintainer-clean: distclean diff --git a/wsutil/libwsutil.def b/wsutil/libwsutil.def new file mode 100644 index 0000000000..be1cd2822d --- /dev/null +++ b/wsutil/libwsutil.def @@ -0,0 +1,17 @@ +; wsutil.def +; $Id$ + +; Add symbols that should be exported out of libwsutil.dll +; +; DATA symbols must be declared WS_VAR_IMPORT in the header file! +; +; NOTE: TABS DON'T WORK IN THIS FILE, USE SPACES INSTEAD!!! +; +EXPORTS + +mpa_bitrate +mpa_frequency +mpa_layer +mpa_padding +mpa_samples +mpa_version diff --git a/wiretap/mpeg-audio.c b/wsutil/mpeg-audio.c index cca12be56b..cca12be56b 100644 --- a/wiretap/mpeg-audio.c +++ b/wsutil/mpeg-audio.c diff --git a/wiretap/mpeg-audio.h b/wsutil/mpeg-audio.h index d0dfd26da2..d0dfd26da2 100644 --- a/wiretap/mpeg-audio.h +++ b/wsutil/mpeg-audio.h |