Export libwiretap symbols using WS_DLL_PUBLIC define
authorBalint Reczey <balint@balintreczey.hu>
Thu, 28 Feb 2013 19:35:59 +0000 (19:35 -0000)
committerBalint Reczey <balint@balintreczey.hu>
Thu, 28 Feb 2013 19:35:59 +0000 (19:35 -0000)
TODO: hide flex-generated functions

svn path=/trunk/; revision=47948

58 files changed:
wiretap/5views.h
wiretap/CMakeLists.txt
wiretap/Makefile.am
wiretap/Makefile.nmake
wiretap/aethra.h
wiretap/ascend-int.h
wiretap/ascendtext.h
wiretap/atm.h
wiretap/ber.h
wiretap/btsnoop.h
wiretap/buffer.h
wiretap/catapult_dct2000.h
wiretap/commview.h
wiretap/cosine.h
wiretap/csids.h
wiretap/daintree-sna.h
wiretap/dbs-etherwatch.h
wiretap/dct3trace.h
wiretap/erf.h
wiretap/eyesdn.h
wiretap/file_wrappers.h
wiretap/hcidump.h
wiretap/i4btrace.h
wiretap/ipfix.h
wiretap/iptrace.h
wiretap/iseries.h
wiretap/k12.h
wiretap/lanalyzer.h
wiretap/libpcap.h
wiretap/libwiretap.vcproj
wiretap/mime_file.h
wiretap/mp2t.h
wiretap/mpeg.h
wiretap/netmon.h
wiretap/netscaler.h
wiretap/netscreen.h
wiretap/nettl.h
wiretap/network_instruments.h
wiretap/netxray.h
wiretap/ngsniffer.h
wiretap/packetlogger.h
wiretap/pcap-common.h
wiretap/pcap-encap.h
wiretap/pcapng.h
wiretap/peekclassic.h
wiretap/peektagged.h
wiretap/pppdump.h
wiretap/radcom.h
wiretap/snoop.h
wiretap/tnef.h
wiretap/toshiba.h
wiretap/visual.h
wiretap/vms.h
wiretap/vwr.h
wiretap/wtap-int.h
wiretap/wtap.c
wiretap/wtap.def [deleted file]
wiretap/wtap.h

index 74f7c8cb4c5a9120c689fbe2f8dd57edc4950574..98382013cc4e2dc84eecd561fe7daff0d06994a6 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int _5views_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean _5views_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int _5views_dump_can_write_encap(int encap);
 
 #endif
index a81fb1ea7dbccc3cd605b0eac75d0875b8802e43..bc9c57197d94a2f15f1605b9f581298aee7c92fc 100644 (file)
@@ -109,6 +109,10 @@ add_library(wiretap ${LINK_MODE_LIB}
 
 set(FULL_SO_VERSION "0.0.0")
 
+set_target_properties(wiretap PROPERTIES COMPILE_DEFINITIONS "WS_BUILD_DLL")
+if(DEFINED COMPILE_HIDE_SYMBOLS)
+       set_target_properties(wiretap PROPERTIES COMPILE_FLAGS ${COMPILE_HIDE_SYMBOLS})
+endif()
 set_target_properties(wiretap PROPERTIES LINK_FLAGS "${WS_LINK_FLAGS}")
 set_target_properties(wiretap PROPERTIES VERSION ${FULL_SO_VERSION} SOVERSION 0)
 
@@ -125,7 +129,7 @@ configure_file(../abi-descriptor.template abi-descriptor.xml)
 file(GLOB HEADERS *.h)
 file(MAKE_DIRECTORY abi-check-headers)
 
-file(COPY ${HEADERS} DESTINATION abi-check-headers)
+file(COPY ${HEADERS} ../ws_symbol_export.h DESTINATION abi-check-headers)
 
 add_custom_command(OUTPUT libwiretap.abi.tar.gz
        COMMAND cp ../config.h abi-check-headers/
index 30a16717056d4f6e2802b804f3df4a440f4406af..e1a8178b4e3149a7dbc2405dac9962f288e06ef7 100644 (file)
@@ -30,10 +30,12 @@ include Makefile.common
 noinst_LTLIBRARIES = libwiretap_generated.la
 lib_LTLIBRARIES = libwiretap.la
 # http://www.gnu.org/software/libtool/manual/html_node/Updating-version-info.html
-libwiretap_la_LDFLAGS = -version-info 0:0:0 -export-symbols wtap.sym @LDFLAGS_SHAREDLIB@
+libwiretap_la_LDFLAGS = -version-info 0:0:0 @LDFLAGS_SHAREDLIB@
+
+AM_NON_GENERATED_CFLAGS =-DWS_BUILD_DLL @COMPILE_HIDE_SYMBOLS@
 
 if HAVE_WARNINGS_AS_ERRORS
-AM_NON_GENERATED_CFLAGS = -Werror
+AM_NON_GENERATED_CFLAGS += -Werror
 endif
 
 INCLUDES = -I$(srcdir)/..
@@ -43,7 +45,6 @@ CLEANFILES = \
        libwiretap.la           \
        libwiretap_generated.a  \
        libwiretap_generated.la \
-       wtap.sym                \
        *~
 
 MAINTAINERCLEANFILES = \
@@ -68,12 +69,11 @@ EXTRA_DIST = \
        Makefile.common         \
        Makefile.nmake          \
        libwiretap.vcproj       \
-       wtap.def                \
        $(GENERATOR_FILES)      \
        $(GENERATED_FILES)
 
 libwiretap_la_LIBADD = libwiretap_generated.la ${top_builddir}/wsutil/libwsutil.la $(GLIB_LIBS)
-libwiretap_la_DEPENDENCIES = libwiretap_generated.la ${top_builddir}/wsutil/libwsutil.la wtap.sym
+libwiretap_la_DEPENDENCIES = libwiretap_generated.la ${top_builddir}/wsutil/libwsutil.la
 
 RUNLEX = $(top_srcdir)/tools/runlex.sh
 
@@ -96,7 +96,7 @@ ascend.c ascend.h: ascend.y
 dumpabi-libwiretap: all abi-descriptor.xml
        rm -rf abi-check-headers abi_dumps .libs/*.abi.tar.gz
        mkdir abi-check-headers
-       cp *.h abi-check-headers/
+       cp *.h ../ws_symbol_export.h abi-check-headers/
        abi-compliance-checker -l libwiretap -v1 `readlink .libs/libwiretap.so | sed 's/.*\.so\.//'` \
                -relpath $(abs_srcdir) -dump-abi abi-descriptor.xml || \
                cat logs/libwiretap/[0-9]*/log.txt
index a036c44b2c241cbcf16455cab974748b0feb2d2e..3160036cee41280d258f625cc80b527505cd9f72 100644 (file)
@@ -32,10 +32,10 @@ all: wiretap-$(WTAP_VERSION).dll
 wiretap-$(WTAP_VERSION).lib: wiretap-$(WTAP_VERSION).dll
 wiretap-$(WTAP_VERSION).exp: wiretap-$(WTAP_VERSION).dll
 
-wiretap-$(WTAP_VERSION).dll : $(OBJECTS) wtap.def ..\image\wiretap.res
+wiretap-$(WTAP_VERSION).dll : $(OBJECTS) ..\image\wiretap.res
        $(link) $(dlllflags) $(conlibsdll) \
                $(LOCAL_LDFLAGS) $(DLL_LDFLAGS) \
-               /DEF:wtap.def /OUT:wiretap-$(WTAP_VERSION).dll \
+               /OUT:wiretap-$(WTAP_VERSION).dll \
                /IMPLIB:wiretap-$(WTAP_VERSION).lib \
                ..\image\wiretap.res \
                $(OBJECTS) $(wiretap_LIBS)
index 1fdd19d54f61269acdabab9378916a00e09eb198..96590cc83c3061700280238167677f243cd0a60d 100644 (file)
@@ -26,6 +26,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int aethra_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 2d04eb5714cf56d94350ff37e44a7425c2b043d2..1c33877e87d1a7b883f56165d65a5b86b078a422 100644 (file)
@@ -31,6 +31,7 @@
 #endif
 
 #include <glib.h>
+#include "ws_symbol_export.h"
 
 typedef struct {
   time_t start_time;
@@ -50,15 +51,19 @@ extern const gchar *ascend_parse_error;
 extern struct ascend_phdr *pseudo_header;
 
 /* Here we provide interfaces to make our scanner act and look like lex */
+WS_DLL_LOCAL
 int ascendlex(void);
 
+WS_DLL_LOCAL
 void init_parse_ascend(void);
+WS_DLL_LOCAL
 void ascend_init_lexer(FILE_T fh);
 typedef enum {
     PARSED_RECORD,
     PARSED_NONRECORD,
     PARSE_FAILED
 } parse_t;
+WS_DLL_LOCAL
 parse_t parse_ascend(FILE_T fh, guint8 *pd, struct ascend_phdr *phdr,
                ascend_pkthdr *hdr, gint64 *start_of_data);
 
index 1e75a230bece9f4ca9ae78a556a60ae473515a9f..e54a86ffb531bf3a38d95140347adba646429568 100644 (file)
@@ -29,6 +29,7 @@
 #define ASCEND_MAX_DATA_COLS 16
 #define ASCEND_MAX_PKT_LEN (ASCEND_MAX_DATA_ROWS * ASCEND_MAX_DATA_COLS)
 
+WS_DLL_LOCAL
 int ascend_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index d6a6a0ca8a5a1cd085fbeded5c0088716601ec58..9afc109b5eaed39a18c177337b8b4e61fc73a6d2 100644 (file)
@@ -23,6 +23,7 @@
 #ifndef __ATM_H__
 #define __ATM_H__
 #include <glib.h>
+#include "ws_symbol_export.h"
 
 /*
  * Routines to use with ATM capture file types that don't include information
  * that information).
  */
 
+WS_DLL_LOCAL
 extern void
 atm_guess_traffic_type(const guint8 *pd, guint32 len,
     union wtap_pseudo_header *pseudo_header);
 
+WS_DLL_LOCAL
 extern void
 atm_guess_lane_type(const guint8 *pd, guint32 len,
     union wtap_pseudo_header *pseudo_header);
index 5d1469ddcc0181e7f21c276c23a95bf9e4d0be8c..c920317da12810da46c4f34c5a2c7361e1a1f3c1 100644 (file)
@@ -23,7 +23,9 @@
 #ifndef __BER_H__
 #define __BER_H__
 #include <glib.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int ber_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 86fe2a5f37b0581d829575975c34a7c483094e40..a3d032d4366a9562caf6af2170130d1ab3af5047 100644 (file)
 #ifndef __W_BTSNOOP_H__
 #define __W_BTSNOOP_H__
 #include <glib.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int btsnoop_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean btsnoop_dump_open_h1(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 gboolean btsnoop_dump_open_h4(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int btsnoop_dump_can_write_encap(int encap);
 
 #endif
index e9326e36be1c34da148eb421741dc60a45f976b7..17265e1b6b8ccfefd3c03ca4530aeca6f0ce6c42 100644 (file)
@@ -23,7 +23,9 @@
 
 #ifndef __W_BUFFER_H__
 #define __W_BUFFER_H__
+
 #include <glib.h>
+#include "ws_symbol_export.h"
 
 #define SOME_FUNCTIONS_ARE_DEFINES
 
@@ -34,10 +36,15 @@ typedef struct Buffer {
        gsize   first_free;
 } Buffer;
 
+WS_DLL_PUBLIC
 void buffer_init(Buffer* buffer, gsize space);
+WS_DLL_PUBLIC
 void buffer_free(Buffer* buffer);
+WS_DLL_PUBLIC
 void buffer_assure_space(Buffer* buffer, gsize space);
+WS_DLL_PUBLIC
 void buffer_append(Buffer* buffer, guint8 *from, gsize bytes);
+WS_DLL_PUBLIC
 void buffer_remove_start(Buffer* buffer, gsize bytes);
 
 #ifdef SOME_FUNCTIONS_ARE_DEFINES
index 494203d500cf95dcf4ab683609218a0b100b06e4..9de081f0ca4aa576e510a106b2fb7e41c52a4c2f 100644 (file)
 #define __W_CAT_DCT2K_H__
 
 #include <glib.h>
+#include "ws_symbol_export.h"
+
+WS_DLL_LOCAL
 int catapult_dct2000_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean catapult_dct2000_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int catapult_dct2000_dump_can_write_encap(int encap);
 
 #define DCT2000_ENCAP_UNHANDLED 0
index b0b7a80333798ef06ca8f38b352942428654566a..3385f32569c4aab7921994be872c217d52db7129 100644 (file)
 #ifndef __COMMVIEW_H__
 #define __COMMVIEW_H__
 #include <glib.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int commview_open(wtap *wth, int *err, gchar **err_info _U_);
+WS_DLL_LOCAL
 int commview_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 gboolean commview_dump_open(wtap_dumper *wdh, int *err);
 
 #endif /* __COMMVIEW_H__ */
index e1ddbba36c6182683be1ba7fd7caa8177e5e3eba..54b886bd6fd61c45627e53ad2b4f331d05ab103b 100644 (file)
@@ -28,7 +28,9 @@
 #define __W_COSINE_H__
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int cosine_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 9b4ff71dff731a60d5b7b2386773db4a2a520232..cbb0b17a98f2eb546dae3ec1e50ce5d14e0e92fb 100644 (file)
@@ -25,7 +25,9 @@
 #define __CSIDS_H__
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int csids_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index d47384a9e64cd928b7214c96b185d45a992c00c3..f10d53def7d1bbd6affb19eb1e4d0d9d2a86df82 100644 (file)
@@ -27,7 +27,9 @@
 #define __DAINTREE_SNA_H__
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int daintree_sna_open(wtap *wth, int *err, gchar **err_info _U_);
 
 #endif /* __DAINTREE_SNA_H__ */
index 06c118dfb92989c5097ba449ddc3ada63d7dd9aa..3fc60fa0f9ef5e7fb229416e141c76c0be991fb7 100644 (file)
@@ -25,7 +25,9 @@
 #define __W_DBS_ETHERWATCH_H__
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int dbs_etherwatch_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index ef2b123bc054d51b837436cc9ad4c958782e4040..2c23c96cac25acc585ee9d4940953fd65d97a1c8 100644 (file)
@@ -24,7 +24,9 @@
 #define __W_DCT3TRACE_H__
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int dct3trace_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 012afba575a12d5deb7ec5717cbcb5785e5e0986..a666796e2bb350b4c23242f58e1db300a8696cda 100644 (file)
@@ -40,6 +40,7 @@
 
 #include <glib.h>
 #include <wiretap/wtap.h>
+#include "ws_symbol_export.h"
 
 /* Record type defines */
 #define ERF_TYPE_LEGACY             0
@@ -104,10 +105,14 @@ union erf_subhdr {
 #define RECORDS_FOR_ERF_CHECK 20
 #define FCS_BITS       32
 
+WS_DLL_LOCAL
 int erf_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 int erf_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 int erf_dump_open(wtap_dumper *wdh, int *err);
 
+WS_DLL_LOCAL
 int erf_populate_interfaces(wtap *wth);
 
 #endif /* __W_ERF_H__ */
index 4874c26328443e6ca9445f02488b65ce32788b00..46cee9e53c50b614aad0ae3e9558e20cded6bb88 100644 (file)
@@ -26,7 +26,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int eyesdn_open(wtap *wth, int *err, gchar **err_info);
 
 enum EyeSDN_TYPES {
@@ -41,7 +43,9 @@ enum EyeSDN_TYPES {
     EYESDN_ENCAP_V5_EF
 };
 
+WS_DLL_LOCAL
 gboolean eyesdn_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int eyesdn_dump_can_write_encap(int encap);
 
 #endif
index fcc320599bf184f3337f6de170f5dcc7b078503a..ca02fbbab51cab9b0aed9129c2da4d03917a4ea3 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 #include <wsutil/file_util.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 extern FILE_T file_open(const char *path);
+WS_DLL_LOCAL
 extern FILE_T file_fdopen(int fildes);
+WS_DLL_LOCAL
 extern void file_set_random_access(FILE_T stream, gboolean random_flag, GPtrArray *seek);
+WS_DLL_PUBLIC
 extern gint64 file_seek(FILE_T stream, gint64 offset, int whence, int *err);
+WS_DLL_LOCAL
 extern gint64 file_skip(FILE_T file, gint64 delta, int *err);
+WS_DLL_PUBLIC
 extern gint64 file_tell(FILE_T stream);
+WS_DLL_LOCAL
 extern gint64 file_tell_raw(FILE_T stream);
+WS_DLL_LOCAL
 extern int file_fstat(FILE_T stream, ws_statb64 *statb, int *err);
+WS_DLL_LOCAL
 extern gboolean file_iscompressed(FILE_T stream);
+WS_DLL_PUBLIC
 extern int file_read(void *buf, unsigned int count, FILE_T file);
+WS_DLL_PUBLIC
 extern int file_getc(FILE_T stream);
+WS_DLL_PUBLIC
 extern char *file_gets(char *buf, int len, FILE_T stream);
+WS_DLL_PUBLIC
 extern int file_eof(FILE_T stream);
+WS_DLL_PUBLIC
 extern int file_error(FILE_T fh, gchar **err_info);
+WS_DLL_LOCAL
 extern void file_clearerr(FILE_T stream);
+WS_DLL_LOCAL
 extern void file_fdclose(FILE_T file);
+WS_DLL_LOCAL
 extern int file_fdreopen(FILE_T file, const char *path);
+WS_DLL_LOCAL
 extern void file_close(FILE_T file);
 
 #ifdef HAVE_LIBZ
 typedef struct wtap_writer *GZWFILE_T;
 
+WS_DLL_LOCAL
 extern GZWFILE_T gzwfile_open(const char *path);
+WS_DLL_LOCAL
 extern GZWFILE_T gzwfile_fdopen(int fd);
+WS_DLL_LOCAL
 extern guint gzwfile_write(GZWFILE_T state, const void *buf, guint len);
+WS_DLL_LOCAL
 extern int gzwfile_flush(GZWFILE_T state);
+WS_DLL_LOCAL
 extern int gzwfile_close(GZWFILE_T state);
+WS_DLL_LOCAL
 extern int gzwfile_geterr(GZWFILE_T state);
 #endif /* HAVE_LIBZ */
 
index 2b76c3a94151ac9266af58ad24b166d45455434b..2d669959996bd2c3c6f7698d0d35820bbe4d8031 100644 (file)
@@ -25,7 +25,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int hcidump_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 1ab785d55900ca9326907ceb42490cac588e1cb3..1a8ccf4ae51c86fe9ea6dee9f1d635946ced487a 100644 (file)
@@ -26,7 +26,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int i4btrace_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 4374e03c33fea1619e520528ba7ad40d49e40b37..04969599a15d7bcab1bb505846c17f1ae4fc9c51 100644 (file)
@@ -25,7 +25,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int ipfix_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index edd376ad962e286e404e6b0cea4f0f2f9d42ee90..aa729e3d2b281be1d21b8d7167cf98fa5a8d525c 100644 (file)
@@ -27,6 +27,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int iptrace_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 35b4880a502efbf717fd8bd0c68bef8e8580dc19..dc4388bc7249edc5c540e20413be9b5335f32bcf 100644 (file)
@@ -26,6 +26,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int iseries_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 01f2c552b230da6195e558511382d1063cd5f3c4..0c214b9532f16fe3442fbc0948bb876fb4c696e8 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int k12_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 int k12_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 gboolean k12_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int k12text_open(wtap *wth, int *err, gchar **err_info _U_);
+WS_DLL_LOCAL
 int k12text_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 gboolean k12text_dump_open(wtap_dumper *wdh, int *err);
 
 #endif
index f225170c9f4bc1f683860dcb2b6a77143e882bb6..532e0b4d23034a830e1904dac77ca72385981d91 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int         lanalyzer_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean    lanalyzer_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int         lanalyzer_dump_can_write_encap(int encap);
 
 #endif
index 84d2bf0874c61509b61cefdfc2228c6f1d43b29b..dee0122376faa1561e8e9da2171c8b5511a48e6c 100644 (file)
@@ -25,6 +25,7 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
 /* Magic numbers in "libpcap" files.
 
@@ -101,8 +102,11 @@ struct pcaprec_nokia_hdr {
        guint8 stuff[4];        /* mysterious stuff */
 };
 
+WS_DLL_LOCAL
 int libpcap_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean libpcap_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int libpcap_dump_can_write_encap(int encap);
 
 #endif
index 5149f6fb6a67267e9fe7f5a249bf4ab3ea53bb9a..f533b116e575fd012709aed3bafeb0fc504765cf 100644 (file)
@@ -61,7 +61,7 @@
        <Files>
                <Filter
                        Name="Source Files"
-                       Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+                       Filter="cpp;c;cc;cxx;odl;idl;hpj;bat;asm;asmx"
                        UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
                        >
                        <File
                        RelativePath=".\runlex.sh"
                        >
                </File>
-               <File
-                       RelativePath=".\wtap.def"
-                       >
-               </File>
        </Files>
        <Globals>
        </Globals>
index 35b9e3a65f059c0706b5d3756f687701526aa387..2f03d80e2497d3034a79587e39e18117b6276a7e 100644 (file)
@@ -26,6 +26,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int mime_file_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 0bc8dd63a6defc0f5300720d7c7a5d0565b7b55e..f7f765d06917f06939e4a801050db62c12193b46 100644 (file)
@@ -28,6 +28,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int mp2t_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 5cce7cee0ad0b94001bcaa811ffd4da633eb3b3c..ac86c534616f876df902a459c6af69ca28825328 100644 (file)
@@ -28,6 +28,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int mpeg_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index cca5be35573c4d1f7aabccf348de6b28b34595f6..d70085a30e9a9435f75cadbbb1c5e52ed8e3b513 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int netmon_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean netmon_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int netmon_dump_can_write_encap_1_x(int encap);
+WS_DLL_LOCAL
 int netmon_dump_can_write_encap_2_x(int encap);
 
 #endif
index 04eddb339702c56e194adfa7a03e62d435199caa..3beee57c96c717acd6abb4870f3ef14b2de2f503 100644 (file)
 #define NSPR_HEADER_VERSION203 0x23
 #define NSPR_HEADER_VERSION204 0x24
 #define NSPR_HEADER_VERSION205 0x25
+WS_DLL_LOCAL
 int nstrace_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 int nstrace_10_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 int nstrace_20_dump_can_write_encap(int encap);
 
+WS_DLL_LOCAL
 gboolean nstrace_dump_open(wtap_dumper *wdh, int *err);
 
 
index 9d6e9fe0e412453cfb8a59b3954e930bee40b8bb..f048520c2916d7f4761f4b45f3461775a916ddc0 100644 (file)
@@ -51,6 +51,7 @@
 
 #define NETSCREEN_MAX_PACKET_LEN       65536
 
+WS_DLL_LOCAL
 int netscreen_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 3e5227a91d761a87420cc835bae643486af7640b..d03765b97a1a4799dd4e08ebdf5f1af28d994473 100644 (file)
 
 #define NETTL_HDR_PDU_MASK              0x30000000
 
+WS_DLL_LOCAL
 int nettl_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean nettl_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int nettl_dump_can_write_encap(int encap);
 
 #endif
index a89e2a63baf499d326e12d97a692b560d47b169a..4ca16400b3c6b1275d258625d53d26727d777099 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int network_instruments_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 int network_instruments_dump_can_write_encap(int encap);
+WS_DLL_LOCAL
 gboolean network_instruments_dump_open(wtap_dumper *wdh, int *err);
 
 /*
index 9225537207bad94b0aedf263a70bdc148de57817..36e275732caa57d9a052e48c7098b4d39e473314 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int netxray_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 int netxray_dump_can_write_encap_1_1(int encap);
+WS_DLL_LOCAL
 gboolean netxray_dump_open_1_1(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int netxray_dump_can_write_encap_2_0(int encap);
+WS_DLL_LOCAL
 gboolean netxray_dump_open_2_0(wtap_dumper *wdh, int *err);
 
 #endif
index 5c4cd5afe9b64ad1a474342ad55346446517e790..7176270faa1dfb9d9c566a068f089c4df1bde6a9 100644 (file)
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int ngsniffer_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean ngsniffer_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int ngsniffer_dump_can_write_encap(int encap);
 
 #endif
index a150c9ecf664a50079ca548945dda580b8e07ca0..a82256dd4a32c9dfa9e6f1a5128446ced072ac59 100644 (file)
@@ -29,6 +29,7 @@
 #include <glib.h>
 #include <wtap.h>
 
+WS_DLL_LOCAL
 int packetlogger_open(wtap *wth, int *err, gchar **err_info _U_);
 
 #endif /* __PACKETLOGGER_H__ */
index 8fafb728c82cfb10053c6203b13196467de00093..1753b792caea59fed64f8edf428d6c371b7970a4 100644 (file)
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 extern int pcap_process_pseudo_header(FILE_T fh, int file_type, int wtap_encap,
     guint packet_size, gboolean check_packet_size, struct wtap_pkthdr *phdr,
     union wtap_pseudo_header *pseudo_header, int *err, gchar **err_info);
 
+WS_DLL_LOCAL
 extern void pcap_read_post_process(int file_type, int wtap_encap,
     union wtap_pseudo_header *pseudo_header,
     guint8 *pd, guint packet_size, gboolean bytes_swapped, int fcs_len);
 
+WS_DLL_LOCAL
 extern int pcap_get_phdr_size(int encap,
     const union wtap_pseudo_header *pseudo_header);
 
+WS_DLL_LOCAL
 extern gboolean pcap_write_phdr(wtap_dumper *wdh, int wtap_encap,
     const union wtap_pseudo_header *pseudo_header, int *err);
 
index 6d0fa74fdd9077ecec02e5d6b16c483967a12b7e..c86cbfcb56fdfb554d56fd74bda8539daadcfb7b 100644 (file)
 extern "C" {
 #endif /* __cplusplus */
 
+WS_DLL_PUBLIC
 extern int wtap_pcap_encap_to_wtap_encap(int encap);
+WS_DLL_PUBLIC
 extern int wtap_wtap_encap_to_pcap_encap(int encap);
+WS_DLL_PUBLIC
 extern gboolean wtap_encap_requires_phdr(int encap);
 
 #ifdef __cplusplus
index 314ad326bdff07051acca7628caedadb8449ee05..41c46129ec0f2f326226892188a78ce4fa34540b 100644 (file)
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int pcapng_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean pcapng_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int pcapng_dump_can_write_encap(int encap);
 
 #endif
index 99c902ee453f62fdf872ff920025889d99fcfdac..14121d82c54ca07d26b6db0af7f5262b394db6ff 100644 (file)
@@ -26,7 +26,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int peekclassic_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index e73da0c0bdd91db15263c6e985ccfaa1f19542cc..ad6626434a8a7ae067ac8c09b17a81c4b9ddaf97 100644 (file)
@@ -23,7 +23,9 @@
 #ifndef __W_PEEKTAGGED_H__
 #define __W_PEEKTAGGED_H__
 #include <glib.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int peektagged_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 21fb2f127e25b14e631ba97be94ebc8547879f99..d89084d0cc2777c6e78290e4705afdfe0e6cf05b 100644 (file)
@@ -25,7 +25,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int pppdump_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 1d2013e369abb7965ea4c80ca5185e8a2e981dcc..8d9af6460b882ea711a3733288b95ec581fed9db 100644 (file)
@@ -26,7 +26,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int radcom_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index c3210533295477d1921a332de9abf72a4de8068b..8010899661ae47b94b2ec3a8446cfe141f3f60f1 100644 (file)
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int snoop_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean snoop_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int snoop_dump_can_write_encap(int encap);
 
 #endif
index ca8c72bdd81b5dd7fb20afbf8a8e69f0c899461e..cbe5d8b18a3da9ad5ee467b28a8f8bbebc381ac2 100644 (file)
 
 #include <glib.h>
 #include <wiretap/wtap.h>
+#include "ws_symbol_export.h"
 
 #define TNEF_SIGNATURE 0x223E9F78
 
+WS_DLL_LOCAL
 int tnef_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index cf67bd5ead98eece7a4c17b97069c96642dfee18..26d1432afda89e3c48522995b5733a397134a093 100644 (file)
@@ -25,7 +25,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int toshiba_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 324d91b47f7b82529628cce7a9663212d4ff52e9..e15bd256ff138077b1278021653082cce352cf55 100644 (file)
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int visual_open(wtap *wth, int *err, gchar **err_info);
+WS_DLL_LOCAL
 gboolean visual_dump_open(wtap_dumper *wdh, int *err);
+WS_DLL_LOCAL
 int visual_dump_can_write_encap(int encap);
 
 #endif
index dd9e6e4298a9abfa9a4bca07265343d754bbf12f..b4122083de607ce8630b82836151d151649b82af 100644 (file)
@@ -26,7 +26,9 @@
 
 #include <glib.h>
 #include <wtap.h>
+#include "ws_symbol_export.h"
 
+WS_DLL_LOCAL
 int vms_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index 82bbd7e67ea63b5fb1139348498b98349ff20f80..7cacc54c8c20073efc18bd1d32ee91075571f2e5 100644 (file)
@@ -24,6 +24,9 @@
 #ifndef __VWR_H__
 #define __VWR_H__
 
+#include "ws_symbol_export.h"
+
+WS_DLL_LOCAL
 int vwr_open(wtap *wth, int *err, gchar **err_info);
 
 #endif
index a52b228baa638889d301158a144d7dea95be2d83..1e62df935eb3324c6de2ba2b3524f0a33ad3b879 100644 (file)
@@ -39,6 +39,7 @@
 
 #include "wtap.h"
 
+WS_DLL_PUBLIC
 int wtap_fstat(wtap *wth, ws_statb64 *statb, int *err);
 
 typedef gboolean (*subtype_read_func)(struct wtap*, int*, char**, gint64*);
@@ -112,12 +113,14 @@ struct wtap_dumper {
     GArray                  *interface_data;        /**< An array holding the interface data from pcapng IDB:s or equivalent(?) NULL if not present.*/
 };
 
-extern gboolean wtap_dump_file_write(wtap_dumper *wdh, const void *buf,
+WS_DLL_LOCAL
+gboolean wtap_dump_file_write(wtap_dumper *wdh, const void *buf,
     size_t bufsize, int *err);
 extern gint64 wtap_dump_file_seek(wtap_dumper *wdh, gint64 offset, int whence, int *err);
 extern gint64 wtap_dump_file_tell(wtap_dumper *wdh);
 
 
+WS_DLL_LOCAL
 extern gint wtap_num_file_types;
 
 /* Macros to byte-swap 64-bit, 32-bit and 16-bit quantities. */
@@ -363,6 +366,7 @@ extern gint wtap_num_file_types;
 #endif
 
 /*** get GSList of all compressed file extensions ***/
+WS_DLL_LOCAL
 GSList *wtap_get_compressed_file_extensions(void);
 
 #endif /* __WTAP_INT_H__ */
index 9f7fa3e3ca35ff24c26965f92132992837e9ce7d..dcc04716e5336ecd13296eed78450bd7190dc6a7 100644 (file)
@@ -601,6 +601,7 @@ static struct encap_type_info encap_table_base[] = {
        { "SCTP", "sctp" },
 };
 
+WS_DLL_LOCAL
 gint wtap_num_encap_types = sizeof(encap_table_base) / sizeof(struct encap_type_info);
 static GArray* encap_table_arr = NULL;
 static const struct encap_type_info* encap_table = NULL;
diff --git a/wiretap/wtap.def b/wiretap/wtap.def
deleted file mode 100644 (file)
index d680b94..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-; wtap.def
-; $Id$
-
-; Add symbols that should be exported out of libwiretap.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
-
-buffer_assure_space
-buffer_append
-buffer_free
-buffer_init
-buffer_remove_start
-
-file_eof
-file_error
-file_getc
-file_gets
-file_seek
-file_read
-file_tell
-
-wtap_buf_ptr
-wtap_cleareof
-wtap_close
-wtap_default_file_extension
-wtap_dump
-wtap_dump_can_open
-wtap_dump_can_write_encap
-wtap_dump_can_write_encaps
-wtap_dump_can_compress
-wtap_dump_close
-wtap_dump_fdopen
-wtap_dump_fdopen_ng
-wtap_dump_file_encap_type
-wtap_dump_flush
-wtap_dump_open
-wtap_dump_open_ng
-wtap_dump_set_addrinfo_list
-wtap_encap_requires_phdr
-wtap_encap_short_string
-wtap_encap_string
-wtap_fdclose
-wtap_fdreopen
-wtap_file_encap
-wtap_get_savable_file_types
-wtap_get_file_extensions_list
-wtap_free_file_extensions_list
-wtap_file_get_idb_info
-wtap_file_get_shb_info
-wtap_file_size
-wtap_file_tsprecision
-wtap_file_type
-wtap_file_type_short_string
-wtap_file_type_string
-wtap_fstat
-wtap_get_bytes_dumped
-wtap_get_num_encap_types
-wtap_get_num_file_types
-wtap_iscompressed
-wtap_open_offline
-wtap_pcap_encap_to_wtap_encap
-wtap_phdr
-wtap_read
-wtap_read_so_far
-wtap_register_encap_type
-wtap_register_file_type
-wtap_register_open_routine
-wtap_seek_read
-wtap_sequential_close
-wtap_set_bytes_dumped
-wtap_set_cb_new_ipv4
-wtap_set_cb_new_ipv6
-wtap_short_string_to_encap
-wtap_short_string_to_file_type
-wtap_snapshot_length
-wtap_strerror
-wtap_write_shb_comment
-wtap_wtap_encap_to_pcap_encap
-
-
index 0990a2dff3fbf446d4baae554849fb034b723ef3..fc28b740dc41b145cad3ffbb50f0ff703da08426 100644 (file)
@@ -29,6 +29,7 @@
 
 #include <glib.h>
 #include <time.h>
+#include "ws_symbol_export.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -1052,6 +1053,7 @@ typedef int (*wtap_open_routine_t)(struct wtap*, int *, char **);
  * @param do_random TRUE if random access to the file will be done,
  * FALSE if not
  */
+WS_DLL_PUBLIC
 struct wtap* wtap_open_offline(const char *filename, int *err,
     gchar **err_info, gboolean do_random);
 
@@ -1060,6 +1062,7 @@ struct wtap* wtap_open_offline(const char *filename, int *err,
  * wtap_read/gzread has a chance to succeed. This is necessary if
  * we're tailing a file.
  */
+WS_DLL_PUBLIC
 void wtap_cleareof(wtap *wth);
 
 /**
@@ -1067,88 +1070,124 @@ void wtap_cleareof(wtap *wth);
  * MUST match add_ipv4_name and add_ipv6_name in addr_resolv.c.
  */
 typedef void (*wtap_new_ipv4_callback_t) (const guint addr, const gchar *name);
+WS_DLL_PUBLIC
 void wtap_set_cb_new_ipv4(wtap *wth, wtap_new_ipv4_callback_t add_new_ipv4);
 
 typedef void (*wtap_new_ipv6_callback_t) (const void *addrp, const gchar *name);
+WS_DLL_PUBLIC
 void wtap_set_cb_new_ipv6(wtap *wth, wtap_new_ipv6_callback_t add_new_ipv6);
 
 /** Returns TRUE if read was successful. FALSE if failure. data_offset is
  * set to the offset in the file where the data for the read packet is
  * located. */
+WS_DLL_PUBLIC
 gboolean wtap_read(wtap *wth, int *err, gchar **err_info,
     gint64 *data_offset);
 
+WS_DLL_PUBLIC
 gboolean wtap_seek_read (wtap *wth, gint64 seek_off,
        struct wtap_pkthdr *phdr, guint8 *pd, int len,
        int *err, gchar **err_info);
 
 /*** get various information snippets about the current packet ***/
+WS_DLL_PUBLIC
 struct wtap_pkthdr *wtap_phdr(wtap *wth);
+WS_DLL_PUBLIC
 guint8 *wtap_buf_ptr(wtap *wth);
 
 /*** get various information snippets about the current file ***/
 
 /** Return an approximation of the amount of data we've read sequentially
  * from the file so far. */
+WS_DLL_PUBLIC
 gint64 wtap_read_so_far(wtap *wth);
+WS_DLL_PUBLIC
 gint64 wtap_file_size(wtap *wth, int *err);
+WS_DLL_PUBLIC
 gboolean wtap_iscompressed(wtap *wth);
+WS_DLL_PUBLIC
 guint wtap_snapshot_length(wtap *wth); /* per file */
+WS_DLL_PUBLIC
 int wtap_file_type(wtap *wth);
+WS_DLL_PUBLIC
 int wtap_file_encap(wtap *wth);
+WS_DLL_PUBLIC
 int wtap_file_tsprecision(wtap *wth);
+WS_DLL_PUBLIC
 wtapng_section_t* wtap_file_get_shb_info(wtap *wth);
+WS_DLL_PUBLIC
 wtapng_iface_descriptions_t *wtap_file_get_idb_info(wtap *wth);
+WS_DLL_PUBLIC
 void wtap_write_shb_comment(wtap *wth, gchar *comment);
 
 /*** close the file descriptors for the current file ***/
+WS_DLL_PUBLIC
 void wtap_fdclose(wtap *wth);
 
 /*** reopen the random file descriptor for the current file ***/
+WS_DLL_PUBLIC
 gboolean wtap_fdreopen(wtap *wth, const char *filename, int *err);
 
 /*** close the current file ***/
+WS_DLL_PUBLIC
 void wtap_sequential_close(wtap *wth);
+WS_DLL_PUBLIC
 void wtap_close(wtap *wth);
 
 /*** dump packets into a capture file ***/
+WS_DLL_PUBLIC
 gboolean wtap_dump_can_open(int filetype);
+WS_DLL_PUBLIC
 gboolean wtap_dump_can_write_encap(int filetype, int encap);
 
 /**
  * Given a GArray of WTAP_ENCAP_ types, return the per-file encapsulation
  * type that would be needed to write out a file with those types.
  */
+WS_DLL_PUBLIC
 int wtap_dump_file_encap_type(const GArray *file_encaps);
 
 /**
  * Return TRUE if a capture with a given GArray of WTAP_ENCAP_ types
  * can be written in a specified format, and FALSE if it can't.
  */
+WS_DLL_PUBLIC
 gboolean wtap_dump_can_write_encaps(int ft, const GArray *file_encaps);
 
+WS_DLL_PUBLIC
 gboolean wtap_dump_can_compress(int filetype);
+WS_DLL_LOCAL
 gboolean wtap_dump_has_name_resolution(int filetype);
 
+WS_DLL_PUBLIC
 wtap_dumper* wtap_dump_open(const char *filename, int filetype, int encap,
        int snaplen, gboolean compressed, int *err);
 
+WS_DLL_PUBLIC
 wtap_dumper* wtap_dump_open_ng(const char *filename, int filetype, int encap,
        int snaplen, gboolean compressed, wtapng_section_t *shb_hdr, wtapng_iface_descriptions_t *idb_inf, int *err);
 
+WS_DLL_PUBLIC
 wtap_dumper* wtap_dump_fdopen(int fd, int filetype, int encap, int snaplen,
        gboolean compressed, int *err);
 
+WS_DLL_PUBLIC
 wtap_dumper* wtap_dump_fdopen_ng(int fd, int filetype, int encap, int snaplen,
                                gboolean compressed, wtapng_section_t *shb_hdr, wtapng_iface_descriptions_t *idb_inf, int *err);
 
 
+WS_DLL_PUBLIC
 gboolean wtap_dump(wtap_dumper *, const struct wtap_pkthdr *, const guint8 *, int *err);
+WS_DLL_PUBLIC
 void wtap_dump_flush(wtap_dumper *);
+WS_DLL_PUBLIC
 gint64 wtap_get_bytes_dumped(wtap_dumper *);
+WS_DLL_PUBLIC
 void wtap_set_bytes_dumped(wtap_dumper *wdh, gint64 bytes_dumped);
 struct addrinfo;
+WS_DLL_PUBLIC
 gboolean wtap_dump_set_addrinfo_list(wtap_dumper *wdh, struct addrinfo *addrinfo_list);
+WS_DLL_PUBLIC
 gboolean wtap_dump_close(wtap_dumper *, int *);
 
 /**
@@ -1156,31 +1195,47 @@ gboolean wtap_dump_close(wtap_dumper *, int *);
  * to save a file of a given type with a given GArray of WTAP_ENCAP_
  * types.
  */
+WS_DLL_PUBLIC
 GArray *wtap_get_savable_file_types(int file_type, const GArray *file_encaps);
 
 /*** various string converter functions ***/
+WS_DLL_PUBLIC
 const char *wtap_file_type_string(int filetype);
+WS_DLL_PUBLIC
 const char *wtap_file_type_short_string(int filetype);
+WS_DLL_PUBLIC
 int wtap_short_string_to_file_type(const char *short_name);
 
 /*** various file extension functions ***/
+WS_DLL_PUBLIC
 const char *wtap_default_file_extension(int filetype);
+WS_DLL_PUBLIC
 GSList *wtap_get_file_extensions_list(int filetype, gboolean include_compressed);
+WS_DLL_PUBLIC
 void wtap_free_file_extensions_list(GSList *extensions);
 
+WS_DLL_PUBLIC
 const char *wtap_encap_string(int encap);
+WS_DLL_PUBLIC
 const char *wtap_encap_short_string(int encap);
+WS_DLL_PUBLIC
 int wtap_short_string_to_encap(const char *short_name);
 
+WS_DLL_PUBLIC
 const char *wtap_strerror(int err);
 
 /*** get available number of file types and encapsulations ***/
+WS_DLL_PUBLIC
 int wtap_get_num_encap_types(void);
+WS_DLL_PUBLIC
 int wtap_get_num_file_types(void);
 
 /*** dynamically register new file types and encapsulations ***/
+WS_DLL_PUBLIC
 void wtap_register_open_routine(wtap_open_routine_t, gboolean has_magic);
+WS_DLL_PUBLIC
 int wtap_register_file_type(const struct file_type_info* fi);
+WS_DLL_PUBLIC
 int wtap_register_encap_type(const char* name, const char* short_name);