forked from osmocom/wireshark
Added support for compiling on win32 with Visual C and 'nmake'. It compiles,
but does not link. Perhaps someone who understands the MS tools can help out. I made it link a few months ago, but with different version of glib/gtk+. I can't remember how I made it link. Most of the compatibility issues were resolved with adding #ifdef HAVE_UNISTD_H the the source code. Please be sure to add this to all future code. svn path=/trunk/; revision=359
This commit is contained in:
parent
093f28c382
commit
601c52f0fb
|
@ -61,6 +61,7 @@ POST_UNINSTALL = :
|
|||
host_alias = @host_alias@
|
||||
host_triplet = @host@
|
||||
CC = @CC@
|
||||
CPP = @CPP@
|
||||
DATAFILE_DIR = @DATAFILE_DIR@
|
||||
GTK_CFLAGS = @GTK_CFLAGS@
|
||||
GTK_CONFIG = @GTK_CONFIG@
|
||||
|
|
|
@ -0,0 +1,53 @@
|
|||
## Makefile for building ethereal.exe with Microsoft C and nmake
|
||||
## Use: nmake -f makefile.nmake
|
||||
|
||||
GTK_VERSION=1.3
|
||||
GLIB_VERSION=1.3
|
||||
|
||||
GLIB_DIR=d:\prj\w\src\glib
|
||||
GTK_DIR=d:\prj\w\src\gtk+
|
||||
|
||||
LOCAL_CFLAGS=/Ic:\tools\msdev\include
|
||||
|
||||
############### no need to modify below this line #########
|
||||
|
||||
CC = cl
|
||||
LDFLAGS = /link
|
||||
|
||||
CFLAGS=-DHAVE_CONFIG_H $(LOCAL_CFLAGS) /I$(GLIB_DIR) /I$(GTK_DIR) /Iwiretap \
|
||||
/I$(GTK_DIR)\gdk\win32
|
||||
|
||||
OBJECTS=capture.obj column.obj dfilter-grammar.obj dfilter.obj \
|
||||
display.obj ethereal.obj ethertype.obj file.obj filter.obj \
|
||||
follow.obj gtkpacket.obj menu.obj \
|
||||
packet-aarp.obj packet-arp.obj \
|
||||
packet-atalk.obj packet-bootp.obj packet-cdp.obj packet-data.obj \
|
||||
packet-dns.obj packet-eth.obj packet-fddi.obj packet-ftp.obj \
|
||||
packet-giop.obj packet-gre.obj packet-http.obj packet-icmpv6.obj \
|
||||
packet-ip.obj packet-ipsec.obj packet-ipv6.obj packet-ipx.obj \
|
||||
packet-isakmp.obj packet-llc.obj packet-lpd.obj packet-nbipx.obj \
|
||||
packet-nbns.obj packet-ncp.obj packet-nntp.obj packet-null.obj \
|
||||
packet-osi.obj packet-ospf.obj packet-pop.obj packet-ppp.obj \
|
||||
packet-pppoe.obj packet-pptp.obj packet-radius.obj packet-raw.obj \
|
||||
packet-rip.obj packet-rsvp.obj packet-rtsp.obj packet-sdp.obj \
|
||||
packet-smb.obj packet-snmp.obj packet-tcp.obj packet-telnet.obj \
|
||||
packet-tftp.obj packet-tr.obj packet-trmac.obj packet-udp.obj \
|
||||
packet-vines.obj packet.obj prefs.obj print.obj proto.obj \
|
||||
resolv.obj snprintf.obj strerror.obj summary.obj util.obj
|
||||
|
||||
LIBS=wiretap\libwtap.lib \
|
||||
$(GTK_DIR)\gtk\gtk-$(GTK_VERSION).lib \
|
||||
$(GTK_DIR)\gdk\win32\gdk-$(GTK_VERSION).lib \
|
||||
$(GLIB_DIR)\glib-$(GTK_VERSION).lib \
|
||||
$(GLIB_DIR)\gmodule-$(GTK_VERSION).lib
|
||||
|
||||
|
||||
ethereal.exe : config.h $(OBJECTS) $(LIBS)
|
||||
$(CC) $(CFLAGS) -Feethereal.exe $(OBJECTS) $(LIBS) $(LDFLAGS)
|
||||
|
||||
config.h : config.h.win32
|
||||
copy config.h.win32 $@
|
||||
|
||||
ps.c : rdps.exe print.ps
|
||||
rdps print.ps ps.c
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
$Id: README.win32,v 1.1 1999/07/13 02:52:46 gram Exp $
|
||||
|
||||
Ethereal can be compiled on Win32 platforms. Some libraries are
|
||||
needed, however.
|
||||
|
||||
The glib, gtk, glib-dev, and gtk-dev packages for win32 can be found
|
||||
at http://www.gimp.org/~tml/gimp/win32 You will definitely need these.
|
||||
|
||||
I have seen mention of a UCD SNMP library for win32 on the cygwin
|
||||
home page, but I have not tried it with ethereal.
|
||||
|
||||
There is no open-source libpcap for win32 yet.
|
||||
|
||||
|
||||
Instructions for MS Visual C
|
||||
----------------------------
|
||||
Download and install the glib-dev and gtk-dev packages. Modify
|
||||
the top lines of Makefile.nmake and wiretap/Makefile.nmake accordingly.
|
||||
In the wiretap directory, type "nmake -f makefile.nmake"
|
||||
Then in the ethereal directory, type "nmake -f makefile.nmake"
|
||||
|
||||
You must set your HOME environment variable for ethereal to work.
|
||||
|
||||
|
||||
Instructions for cygwin
|
||||
-----------------------
|
||||
No one has ever compiled ethereal with cygwin. It should not be difficult,
|
||||
however. This spot is reserverd for your instructions on how to compile
|
||||
ethereal with cygwin.
|
||||
|
31
acinclude.m4
31
acinclude.m4
|
@ -159,3 +159,34 @@ yes
|
|||
fi
|
||||
AC_MSG_RESULT(["$v6type, $v6lib"])
|
||||
])
|
||||
|
||||
#
|
||||
# AC_ETHEREAL_PCAP_CHECK
|
||||
#
|
||||
AC_DEFUN(AC_ETHEREAL_PCAP_CHECK,
|
||||
[
|
||||
# Evidently, some systems have pcap.h, etc. in */include/pcap
|
||||
AC_MSG_CHECKING(for extraneous pcap header directories)
|
||||
found_pcap_dir=""
|
||||
for pcap_dir in /usr/include/pcap /usr/local/include/pcap
|
||||
do
|
||||
if test -d $pcap_dir ; then
|
||||
LIBS="$LIBS -L$pcap_dir"
|
||||
CFLAGS="$CFLAGS -I$pcap_dir"
|
||||
CPPFLAGS="$CPPFLAGS -I$pcap_dir"
|
||||
found_pcap_dir=" $found_pcap_dir -L$pcap_dir"
|
||||
fi
|
||||
done
|
||||
|
||||
if test "$found_pcap_dir" != "" ; then
|
||||
AC_MSG_RESULT(found --$found_pcap_dir added to LIBS)
|
||||
else
|
||||
AC_MSG_RESULT(not found)
|
||||
fi
|
||||
|
||||
# Pcap checks
|
||||
AC_CHECK_HEADER(net/bpf.h,, AC_MSG_ERROR(Header file net/bpf.h not found.))
|
||||
AC_CHECK_HEADER(pcap.h,, AC_MSG_ERROR(Header file pcap.h not found.))
|
||||
AC_CHECK_LIB(pcap, pcap_open_offline,, AC_MSG_ERROR(Library libpcap not found.))
|
||||
])
|
||||
|
||||
|
|
|
@ -172,6 +172,37 @@ yes
|
|||
AC_MSG_RESULT(["$v6type, $v6lib"])
|
||||
])
|
||||
|
||||
#
|
||||
# AC_ETHEREAL_PCAP_CHECK
|
||||
#
|
||||
AC_DEFUN(AC_ETHEREAL_PCAP_CHECK,
|
||||
[
|
||||
# Evidently, some systems have pcap.h, etc. in */include/pcap
|
||||
AC_MSG_CHECKING(for extraneous pcap header directories)
|
||||
found_pcap_dir=""
|
||||
for pcap_dir in /usr/include/pcap /usr/local/include/pcap
|
||||
do
|
||||
if test -d $pcap_dir ; then
|
||||
LIBS="$LIBS -L$pcap_dir"
|
||||
CFLAGS="$CFLAGS -I$pcap_dir"
|
||||
CPPFLAGS="$CPPFLAGS -I$pcap_dir"
|
||||
found_pcap_dir=" $found_pcap_dir -L$pcap_dir"
|
||||
fi
|
||||
done
|
||||
|
||||
if test "$found_pcap_dir" != "" ; then
|
||||
AC_MSG_RESULT(found --$found_pcap_dir added to LIBS)
|
||||
else
|
||||
AC_MSG_RESULT(not found)
|
||||
fi
|
||||
|
||||
# Pcap checks
|
||||
AC_CHECK_HEADER(net/bpf.h,, AC_MSG_ERROR(Header file net/bpf.h not found.))
|
||||
AC_CHECK_HEADER(pcap.h,, AC_MSG_ERROR(Header file pcap.h not found.))
|
||||
AC_CHECK_LIB(pcap, pcap_open_offline,, AC_MSG_ERROR(Library libpcap not found.))
|
||||
])
|
||||
|
||||
|
||||
# Do all the work for Automake. This macro actually does too much --
|
||||
# some checks are only needed if your package does certain things.
|
||||
# But this isn't really a big deal.
|
||||
|
|
6
column.c
6
column.c
|
@ -1,7 +1,7 @@
|
|||
/* column.c
|
||||
* Routines for handling column preferences
|
||||
*
|
||||
* $Id: column.c,v 1.14 1999/06/21 19:04:34 gram Exp $
|
||||
* $Id: column.c,v 1.15 1999/07/13 02:52:46 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -36,7 +36,11 @@
|
|||
#include <stdio.h>
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "timestamp.h"
|
||||
|
|
|
@ -18,6 +18,12 @@
|
|||
/* Define if you have the <fcntl.h> header file. */
|
||||
#undef HAVE_FCNTL_H
|
||||
|
||||
/* Define if you have the <net/if.h> header file. */
|
||||
#undef HAVE_NET_IF_H
|
||||
|
||||
/* Define if you have the <netdb.h> header file. */
|
||||
#undef HAVE_NETDB_H
|
||||
|
||||
/* Define if you have the <netinet/in.h> header file. */
|
||||
#undef HAVE_NETINET_IN_H
|
||||
|
||||
|
@ -30,6 +36,9 @@
|
|||
/* Define if you have the <sys/ioctl.h> header file. */
|
||||
#undef HAVE_SYS_IOCTL_H
|
||||
|
||||
/* Define if you have the <sys/socket> header file. */
|
||||
#undef HAVE_SYS_SOCKET
|
||||
|
||||
/* Define if you have the <sys/sockio.h> header file. */
|
||||
#undef HAVE_SYS_SOCKIO_H
|
||||
|
||||
|
|
|
@ -0,0 +1,63 @@
|
|||
/* config.h. Generated automatically by configure. */
|
||||
/* config.h.in. Generated automatically from configure.in by autoheader. */
|
||||
|
||||
/* Define if you have the ANSI C header files. */
|
||||
#define STDC_HEADERS 1
|
||||
|
||||
/* Define if your processor stores words with the most significant
|
||||
byte first (like Motorola and SPARC, unlike Intel and VAX). */
|
||||
/* #undef WORDS_BIGENDIAN */
|
||||
|
||||
/* #undef HAVE_SA_LEN */
|
||||
|
||||
#define DATAFILE_DIR "/usr/local/etc"
|
||||
|
||||
/* #undef NEED_SNPRINTF_H */
|
||||
|
||||
/* #undef NEED_STRERROR_H */
|
||||
|
||||
/* Define if you have the <fcntl.h> header file. */
|
||||
#define HAVE_FCNTL_H 1
|
||||
|
||||
/* Define if you have the <netinet/in.h> header file. */
|
||||
/* #define HAVE_NETINET_IN_H 1 */
|
||||
|
||||
/* Define if you have the <snmp/snmp.h> header file. */
|
||||
/* #undef HAVE_SNMP_SNMP_H */
|
||||
|
||||
/* Define if you have the <stdarg.h> header file. */
|
||||
#define HAVE_STDARG_H 1
|
||||
|
||||
/* Define if you have the <sys/ioctl.h> header file. */
|
||||
/* #undef HAVE_SYS_IOCTL_H */
|
||||
|
||||
/* Define if you have the <sys/sockio.h> header file. */
|
||||
/* #undef HAVE_SYS_SOCKIO_H */
|
||||
|
||||
/* Define if you have the <sys/time.h> header file. */
|
||||
/* #define HAVE_SYS_TIME_H 1 */
|
||||
|
||||
/* Define if you have the <sys/types.h> header file. */
|
||||
#define HAVE_SYS_TYPES_H 1
|
||||
|
||||
/* Define if you have the <ucd-snmp/snmp.h> header file. */
|
||||
/* #undef HAVE_UCD_SNMP_SNMP_H */
|
||||
|
||||
/* Define if you have the <unistd.h> header file. */
|
||||
/* #define HAVE_UNISTD_H 1 */
|
||||
|
||||
/* Define if you have the pcap library (-lpcap). */
|
||||
/* #define HAVE_LIBPCAP 1 */
|
||||
|
||||
/* Name of package */
|
||||
#define PACKAGE "ethereal"
|
||||
|
||||
/* Version number of package */
|
||||
#define VERSION "0.6.3"
|
||||
|
||||
#define HAVE_WINSOCK_H
|
||||
#define snprintf _snprintf
|
||||
#define vsnprintf _vsnprintf
|
||||
#define HAVE_DIRECT_H
|
||||
#define HAVE_IO_H
|
||||
#define strncasecmp strnicmp
|
|
@ -1038,10 +1038,90 @@ else
|
|||
fi
|
||||
fi
|
||||
|
||||
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
|
||||
echo "configure:1043: checking how to run the C preprocessor" >&5
|
||||
# On Suns, sometimes $CPP names a directory.
|
||||
if test -n "$CPP" && test -d "$CPP"; then
|
||||
CPP=
|
||||
fi
|
||||
if test -z "$CPP"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
# This must be in double quotes, not single quotes, because CPP may get
|
||||
# substituted into the Makefile and "${CC-cc}" will confuse make.
|
||||
CPP="${CC-cc} -E"
|
||||
# On the NeXT, cc -E runs the code through the compiler's parser,
|
||||
# not just through cpp.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1058 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1064: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -E -traditional-cpp"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1075 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1081: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -nologo -E"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1092 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1098: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP=/lib/cpp
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
CPP="$ac_cv_prog_CPP"
|
||||
else
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
echo "$ac_t""$CPP" 1>&6
|
||||
|
||||
# Extract the first word of "ranlib", so it can be a program name with args.
|
||||
set dummy ranlib; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1045: checking for $ac_word" >&5
|
||||
echo "configure:1125: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1073,7 +1153,7 @@ do
|
|||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1077: checking for $ac_word" >&5
|
||||
echo "configure:1157: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1106,7 +1186,7 @@ test -n "$YACC" || YACC="yacc"
|
|||
|
||||
# If we're running gcc, add '-Wall' to CFLAGS.
|
||||
echo $ac_n "checking to see if we can add '-Wall' to CFLAGS""... $ac_c" 1>&6
|
||||
echo "configure:1110: checking to see if we can add '-Wall' to CFLAGS" >&5
|
||||
echo "configure:1190: checking to see if we can add '-Wall' to CFLAGS" >&5
|
||||
if test x$GCC != x ; then
|
||||
CFLAGS="-Wall $CFLAGS"
|
||||
echo "$ac_t""yes" 1>&6
|
||||
|
@ -1134,7 +1214,7 @@ EOF
|
|||
case "$host_os" in
|
||||
solaris*)
|
||||
echo $ac_n "checking for LD_LIBRARY_PATH""... $ac_c" 1>&6
|
||||
echo "configure:1138: checking for LD_LIBRARY_PATH" >&5
|
||||
echo "configure:1218: checking for LD_LIBRARY_PATH" >&5
|
||||
if test x$LD_LIBRARY_PATH != x ; then
|
||||
LIBS="$LIBS -R$LD_LIBRARY_PATH"
|
||||
echo "$ac_t""yes -- added LD_LIBRARY_PATH to run-time linker path" 1>&6
|
||||
|
@ -1195,7 +1275,7 @@ fi
|
|||
# Extract the first word of "gtk-config", so it can be a program name with args.
|
||||
set dummy gtk-config; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1199: checking for $ac_word" >&5
|
||||
echo "configure:1279: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1230,7 +1310,7 @@ fi
|
|||
|
||||
min_gtk_version=1.2.0
|
||||
echo $ac_n "checking for GTK - version >= $min_gtk_version""... $ac_c" 1>&6
|
||||
echo "configure:1234: checking for GTK - version >= $min_gtk_version" >&5
|
||||
echo "configure:1314: checking for GTK - version >= $min_gtk_version" >&5
|
||||
no_gtk=""
|
||||
if test "$GTK_CONFIG" = "no" ; then
|
||||
no_gtk=yes
|
||||
|
@ -1253,7 +1333,7 @@ echo "configure:1234: checking for GTK - version >= $min_gtk_version" >&5
|
|||
echo $ac_n "cross compiling; assumed OK... $ac_c"
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1257 "configure"
|
||||
#line 1337 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
|
@ -1331,7 +1411,7 @@ main ()
|
|||
}
|
||||
|
||||
EOF
|
||||
if { (eval echo configure:1335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:1415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
:
|
||||
else
|
||||
|
@ -1365,7 +1445,7 @@ fi
|
|||
CFLAGS="$CFLAGS $GTK_CFLAGS"
|
||||
LIBS="$LIBS $GTK_LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1369 "configure"
|
||||
#line 1449 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
|
@ -1375,7 +1455,7 @@ int main() {
|
|||
return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version));
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
echo "*** The test program compiled, but did not run. This usually means"
|
||||
echo "*** that the run-time linker is not finding GTK or finding the wrong"
|
||||
|
@ -1424,14 +1504,15 @@ fi
|
|||
|
||||
|
||||
echo $ac_n "checking whether to use libpcap for packet capture""... $ac_c" 1>&6
|
||||
echo "configure:1428: checking whether to use libpcap for packet capture" >&5
|
||||
echo "configure:1508: checking whether to use libpcap for packet capture" >&5
|
||||
if test "x$enable_pcap" = "xno" ; then
|
||||
echo "$ac_t""no" 1>&6
|
||||
else
|
||||
echo "$ac_t""yes" 1>&6
|
||||
|
||||
# Evidently, some systems have pcap.h, etc. in */include/pcap
|
||||
echo $ac_n "checking for extraneous pcap header directories""... $ac_c" 1>&6
|
||||
echo "configure:1435: checking for extraneous pcap header directories" >&5
|
||||
echo "configure:1516: checking for extraneous pcap header directories" >&5
|
||||
found_pcap_dir=""
|
||||
for pcap_dir in /usr/include/pcap /usr/local/include/pcap
|
||||
do
|
||||
|
@ -1450,99 +1531,19 @@ echo "configure:1435: checking for extraneous pcap header directories" >&5
|
|||
fi
|
||||
|
||||
# Pcap checks
|
||||
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
|
||||
echo "configure:1455: checking how to run the C preprocessor" >&5
|
||||
# On Suns, sometimes $CPP names a directory.
|
||||
if test -n "$CPP" && test -d "$CPP"; then
|
||||
CPP=
|
||||
fi
|
||||
if test -z "$CPP"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
# This must be in double quotes, not single quotes, because CPP may get
|
||||
# substituted into the Makefile and "${CC-cc}" will confuse make.
|
||||
CPP="${CC-cc} -E"
|
||||
# On the NeXT, cc -E runs the code through the compiler's parser,
|
||||
# not just through cpp.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1470 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1476: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -E -traditional-cpp"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1487 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1493: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -nologo -E"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1504 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1510: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP=/lib/cpp
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
CPP="$ac_cv_prog_CPP"
|
||||
else
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
echo "$ac_t""$CPP" 1>&6
|
||||
|
||||
ac_safe=`echo "net/bpf.h" | sed 'y%./+-%__p_%'`
|
||||
ac_safe=`echo "net/bpf.h" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for net/bpf.h""... $ac_c" 1>&6
|
||||
echo "configure:1536: checking for net/bpf.h" >&5
|
||||
echo "configure:1537: checking for net/bpf.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1541 "configure"
|
||||
#line 1542 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <net/bpf.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1546: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1547: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
@ -1566,17 +1567,17 @@ fi
|
|||
|
||||
ac_safe=`echo "pcap.h" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for pcap.h""... $ac_c" 1>&6
|
||||
echo "configure:1570: checking for pcap.h" >&5
|
||||
echo "configure:1571: checking for pcap.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1575 "configure"
|
||||
#line 1576 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <pcap.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1580: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1581: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
@ -1599,7 +1600,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for pcap_open_offline in -lpcap""... $ac_c" 1>&6
|
||||
echo "configure:1603: checking for pcap_open_offline in -lpcap" >&5
|
||||
echo "configure:1604: checking for pcap_open_offline in -lpcap" >&5
|
||||
ac_lib_var=`echo pcap'_'pcap_open_offline | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
@ -1607,7 +1608,7 @@ else
|
|||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-lpcap $LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1611 "configure"
|
||||
#line 1612 "configure"
|
||||
#include "confdefs.h"
|
||||
/* Override any gcc2 internal prototype to avoid an error. */
|
||||
/* We use char because int might match the return type of a gcc2
|
||||
|
@ -1618,7 +1619,7 @@ int main() {
|
|||
pcap_open_offline()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||
else
|
||||
|
@ -1646,8 +1647,8 @@ else
|
|||
{ echo "configure: error: Library libpcap not found." 1>&2; exit 1; }
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
fi
|
||||
|
||||
# Check whether --enable-ipv6 or --disable-ipv6 was given.
|
||||
if test "${enable_ipv6+set}" = set; then
|
||||
|
@ -1659,7 +1660,7 @@ fi
|
|||
|
||||
|
||||
echo $ac_n "checking whether to enable ipv6 name resolution if available""... $ac_c" 1>&6
|
||||
echo "configure:1663: checking whether to enable ipv6 name resolution if available" >&5
|
||||
echo "configure:1664: checking whether to enable ipv6 name resolution if available" >&5
|
||||
if test "x$enable_ipv6" = "xno" ; then
|
||||
echo "$ac_t""no" 1>&6
|
||||
else
|
||||
|
@ -1669,12 +1670,12 @@ else
|
|||
v6lib=none
|
||||
|
||||
echo $ac_n "checking ipv6 stack type""... $ac_c" 1>&6
|
||||
echo "configure:1673: checking ipv6 stack type" >&5
|
||||
echo "configure:1674: checking ipv6 stack type" >&5
|
||||
for i in v6d toshiba kame inria zeta linux; do
|
||||
case $i in
|
||||
v6d)
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1678 "configure"
|
||||
#line 1679 "configure"
|
||||
#include "confdefs.h"
|
||||
dnl
|
||||
#include </usr/local/v6/include/sys/types.h>
|
||||
|
@ -1694,7 +1695,7 @@ rm -f conftest*
|
|||
;;
|
||||
toshiba)
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1698 "configure"
|
||||
#line 1699 "configure"
|
||||
#include "confdefs.h"
|
||||
dnl
|
||||
#include <sys/param.h>
|
||||
|
@ -1714,7 +1715,7 @@ rm -f conftest*
|
|||
;;
|
||||
kame)
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1718 "configure"
|
||||
#line 1719 "configure"
|
||||
#include "confdefs.h"
|
||||
dnl
|
||||
#include <netinet/in.h>
|
||||
|
@ -1734,7 +1735,7 @@ rm -f conftest*
|
|||
;;
|
||||
inria)
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1738 "configure"
|
||||
#line 1739 "configure"
|
||||
#include "confdefs.h"
|
||||
dnl
|
||||
#include <netinet/in.h>
|
||||
|
@ -1752,7 +1753,7 @@ rm -f conftest*
|
|||
;;
|
||||
zeta)
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1756 "configure"
|
||||
#line 1757 "configure"
|
||||
#include "confdefs.h"
|
||||
dnl
|
||||
#include <sys/param.h>
|
||||
|
@ -1801,12 +1802,12 @@ fi
|
|||
|
||||
|
||||
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
|
||||
echo "configure:1805: checking for ANSI C header files" >&5
|
||||
echo "configure:1806: checking for ANSI C header files" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1810 "configure"
|
||||
#line 1811 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <stdlib.h>
|
||||
#include <stdarg.h>
|
||||
|
@ -1814,7 +1815,7 @@ else
|
|||
#include <float.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1818: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
@ -1831,7 +1832,7 @@ rm -f conftest*
|
|||
if test $ac_cv_header_stdc = yes; then
|
||||
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1835 "configure"
|
||||
#line 1836 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <string.h>
|
||||
EOF
|
||||
|
@ -1849,7 +1850,7 @@ fi
|
|||
if test $ac_cv_header_stdc = yes; then
|
||||
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1853 "configure"
|
||||
#line 1854 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <stdlib.h>
|
||||
EOF
|
||||
|
@ -1870,7 +1871,7 @@ if test "$cross_compiling" = yes; then
|
|||
:
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1874 "configure"
|
||||
#line 1875 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <ctype.h>
|
||||
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
|
||||
|
@ -1881,7 +1882,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
|
|||
exit (0); }
|
||||
|
||||
EOF
|
||||
if { (eval echo configure:1885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:1886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
:
|
||||
else
|
||||
|
@ -1904,21 +1905,21 @@ EOF
|
|||
|
||||
fi
|
||||
|
||||
for ac_hdr in fcntl.h sys/ioctl.h sys/time.h unistd.h stdarg.h
|
||||
for ac_hdr in fcntl.h sys/ioctl.h sys/time.h unistd.h stdarg.h netdb.h
|
||||
do
|
||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||
echo "configure:1912: checking for $ac_hdr" >&5
|
||||
echo "configure:1913: checking for $ac_hdr" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1917 "configure"
|
||||
#line 1918 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <$ac_hdr>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1922: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1923: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
@ -1944,8 +1945,7 @@ else
|
|||
fi
|
||||
done
|
||||
|
||||
|
||||
for ac_hdr in sys/sockio.h sys/types.h netinet/in.h
|
||||
for ac_hdr in sys/sockio.h sys/types.h netinet/in.h sys/socket net/if.h
|
||||
do
|
||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||
|
@ -1986,7 +1986,6 @@ fi
|
|||
done
|
||||
|
||||
|
||||
|
||||
# Check whether --enable-snmp or --disable-snmp was given.
|
||||
if test "${enable_snmp+set}" = set; then
|
||||
enableval="$enable_snmp"
|
||||
|
@ -1999,7 +1998,7 @@ fi
|
|||
SNMP_A=''
|
||||
SNMP_O=''
|
||||
echo $ac_n "checking whether to use SNMP library if available""... $ac_c" 1>&6
|
||||
echo "configure:2003: checking whether to use SNMP library if available" >&5
|
||||
echo "configure:2002: checking whether to use SNMP library if available" >&5
|
||||
if test "x$enable_snmp" = "xno" ; then
|
||||
echo "$ac_t""no" 1>&6
|
||||
else
|
||||
|
@ -2008,17 +2007,17 @@ else
|
|||
do
|
||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||
echo "configure:2012: checking for $ac_hdr" >&5
|
||||
echo "configure:2011: checking for $ac_hdr" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2017 "configure"
|
||||
#line 2016 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <$ac_hdr>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:2022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:2021: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
@ -2045,7 +2044,7 @@ fi
|
|||
done
|
||||
|
||||
echo $ac_n "checking for asn_parse_header in -lsnmp""... $ac_c" 1>&6
|
||||
echo "configure:2049: checking for asn_parse_header in -lsnmp" >&5
|
||||
echo "configure:2048: checking for asn_parse_header in -lsnmp" >&5
|
||||
ac_lib_var=`echo snmp'_'asn_parse_header | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
@ -2053,7 +2052,7 @@ else
|
|||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-lsnmp $LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2057 "configure"
|
||||
#line 2056 "configure"
|
||||
#include "confdefs.h"
|
||||
/* Override any gcc2 internal prototype to avoid an error. */
|
||||
/* We use char because int might match the return type of a gcc2
|
||||
|
@ -2064,7 +2063,7 @@ int main() {
|
|||
asn_parse_header()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:2067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||
else
|
||||
|
@ -2097,12 +2096,12 @@ fi
|
|||
# for get_interface_list().
|
||||
|
||||
echo $ac_n "checking for sa_len in struct sockaddr""... $ac_c" 1>&6
|
||||
echo "configure:2101: checking for sa_len in struct sockaddr" >&5
|
||||
echo "configure:2100: checking for sa_len in struct sockaddr" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_ethereal_struct_sa_len'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2106 "configure"
|
||||
#line 2105 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
|
@ -2110,7 +2109,7 @@ int main() {
|
|||
struct sockaddr s; s.sa_len;
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2114: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2113: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
ac_cv_ethereal_struct_sa_len=yes
|
||||
else
|
||||
|
@ -2133,14 +2132,14 @@ fi
|
|||
|
||||
# We must know our byte order
|
||||
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
|
||||
echo "configure:2137: checking whether byte ordering is bigendian" >&5
|
||||
echo "configure:2136: checking whether byte ordering is bigendian" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
ac_cv_c_bigendian=unknown
|
||||
# See if sys/param.h defines the BYTE_ORDER macro.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2144 "configure"
|
||||
#line 2143 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
@ -2151,11 +2150,11 @@ int main() {
|
|||
#endif
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2155: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2154: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
# It does; now see whether it defined to BIG_ENDIAN or not.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2159 "configure"
|
||||
#line 2158 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
@ -2166,7 +2165,7 @@ int main() {
|
|||
#endif
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2170: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2169: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
ac_cv_c_bigendian=yes
|
||||
else
|
||||
|
@ -2186,7 +2185,7 @@ if test "$cross_compiling" = yes; then
|
|||
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2190 "configure"
|
||||
#line 2189 "configure"
|
||||
#include "confdefs.h"
|
||||
main () {
|
||||
/* Are we little or big endian? From Harbison&Steele. */
|
||||
|
@ -2199,7 +2198,7 @@ main () {
|
|||
exit (u.c[sizeof (long) - 1] == 1);
|
||||
}
|
||||
EOF
|
||||
if { (eval echo configure:2203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:2202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
ac_cv_c_bigendian=no
|
||||
else
|
||||
|
@ -2225,13 +2224,13 @@ fi
|
|||
|
||||
if test $ac_cv_prog_gcc = yes; then
|
||||
echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
|
||||
echo "configure:2229: checking whether ${CC-cc} needs -traditional" >&5
|
||||
echo "configure:2228: checking whether ${CC-cc} needs -traditional" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
ac_pattern="Autoconf.*'x'"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2235 "configure"
|
||||
#line 2234 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sgtty.h>
|
||||
Autoconf TIOCGETP
|
||||
|
@ -2249,7 +2248,7 @@ rm -f conftest*
|
|||
|
||||
if test $ac_cv_prog_gcc_traditional = no; then
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2253 "configure"
|
||||
#line 2252 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <termio.h>
|
||||
Autoconf TCGETA
|
||||
|
@ -2271,12 +2270,12 @@ echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for socket""... $ac_c" 1>&6
|
||||
echo "configure:2275: checking for socket" >&5
|
||||
echo "configure:2274: checking for socket" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2280 "configure"
|
||||
#line 2279 "configure"
|
||||
#include "confdefs.h"
|
||||
/* System header to define __stub macros and hopefully few prototypes,
|
||||
which can conflict with char socket(); below. */
|
||||
|
@ -2299,7 +2298,7 @@ socket();
|
|||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:2302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_func_socket=yes"
|
||||
else
|
||||
|
@ -2325,12 +2324,12 @@ fi
|
|||
SNPRINTF_C=""
|
||||
SNPRINTF_O=""
|
||||
echo $ac_n "checking for snprintf""... $ac_c" 1>&6
|
||||
echo "configure:2329: checking for snprintf" >&5
|
||||
echo "configure:2328: checking for snprintf" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_func_snprintf'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2334 "configure"
|
||||
#line 2333 "configure"
|
||||
#include "confdefs.h"
|
||||
/* System header to define __stub macros and hopefully few prototypes,
|
||||
which can conflict with char snprintf(); below. */
|
||||
|
@ -2353,7 +2352,7 @@ snprintf();
|
|||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:2356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_func_snprintf=yes"
|
||||
else
|
||||
|
@ -2384,12 +2383,12 @@ fi
|
|||
|
||||
|
||||
echo $ac_n "checking for strerror""... $ac_c" 1>&6
|
||||
echo "configure:2388: checking for strerror" >&5
|
||||
echo "configure:2387: checking for strerror" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_func_strerror'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2393 "configure"
|
||||
#line 2392 "configure"
|
||||
#include "confdefs.h"
|
||||
/* System header to define __stub macros and hopefully few prototypes,
|
||||
which can conflict with char strerror(); below. */
|
||||
|
@ -2412,7 +2411,7 @@ strerror();
|
|||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:2415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_func_strerror=yes"
|
||||
else
|
||||
|
@ -2599,13 +2598,13 @@ s%@host_cpu@%$host_cpu%g
|
|||
s%@host_vendor@%$host_vendor%g
|
||||
s%@host_os@%$host_os%g
|
||||
s%@CC@%$CC%g
|
||||
s%@CPP@%$CPP%g
|
||||
s%@RANLIB@%$RANLIB%g
|
||||
s%@YACC@%$YACC%g
|
||||
s%@DATAFILE_DIR@%$DATAFILE_DIR%g
|
||||
s%@GTK_CONFIG@%$GTK_CONFIG%g
|
||||
s%@GTK_CFLAGS@%$GTK_CFLAGS%g
|
||||
s%@GTK_LIBS@%$GTK_LIBS%g
|
||||
s%@CPP@%$CPP%g
|
||||
s%@SNMP_A@%$SNMP_A%g
|
||||
s%@SNMP_O@%$SNMP_O%g
|
||||
s%@SNPRINTF_C@%$SNPRINTF_C%g
|
||||
|
|
34
configure.in
34
configure.in
|
@ -1,4 +1,4 @@
|
|||
# $Id: configure.in,v 1.29 1999/07/09 04:18:33 gram Exp $
|
||||
# $Id: configure.in,v 1.30 1999/07/13 02:52:48 gram Exp $
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
AC_INIT(etypes.h)
|
||||
|
||||
|
@ -9,6 +9,7 @@ AC_CANONICAL_HOST
|
|||
|
||||
dnl Checks for programs.
|
||||
AC_PROG_CC
|
||||
AC_PROG_CPP
|
||||
AC_PROG_RANLIB
|
||||
AC_PROG_YACC
|
||||
|
||||
|
@ -60,32 +61,9 @@ if test "x$enable_pcap" = "xno" ; then
|
|||
AC_MSG_RESULT(no)
|
||||
else
|
||||
AC_MSG_RESULT(yes)
|
||||
# Evidently, some systems have pcap.h, etc. in */include/pcap
|
||||
AC_MSG_CHECKING(for extraneous pcap header directories)
|
||||
found_pcap_dir=""
|
||||
for pcap_dir in /usr/include/pcap /usr/local/include/pcap
|
||||
do
|
||||
if test -d $pcap_dir ; then
|
||||
LIBS="$LIBS -L$pcap_dir"
|
||||
CFLAGS="$CFLAGS -I$pcap_dir"
|
||||
CPPFLAGS="$CPPFLAGS -I$pcap_dir"
|
||||
found_pcap_dir=" $found_pcap_dir -L$pcap_dir"
|
||||
fi
|
||||
done
|
||||
|
||||
if test "$found_pcap_dir" != "" ; then
|
||||
AC_MSG_RESULT(found --$found_pcap_dir added to LIBS)
|
||||
else
|
||||
AC_MSG_RESULT(not found)
|
||||
fi
|
||||
|
||||
# Pcap checks
|
||||
AC_CHECK_HEADER(net/bpf.h,, AC_MSG_ERROR(Header file net/bpf.h not found.))
|
||||
AC_CHECK_HEADER(pcap.h,, AC_MSG_ERROR(Header file pcap.h not found.))
|
||||
AC_CHECK_LIB(pcap, pcap_open_offline,, AC_MSG_ERROR(Library libpcap not found.))
|
||||
AC_ETHEREAL_PCAP_CHECK
|
||||
fi
|
||||
|
||||
|
||||
dnl ipv6 check
|
||||
AC_ARG_ENABLE(ipv6,
|
||||
[ --enable-ipv6 use ipv6 name resolution, if available. [default=yes]],,enable_ipv6=yes)
|
||||
|
@ -101,10 +79,8 @@ fi
|
|||
|
||||
dnl Checks for header files.
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS(fcntl.h sys/ioctl.h sys/time.h unistd.h stdarg.h)
|
||||
|
||||
AC_CHECK_HEADERS(sys/sockio.h sys/types.h netinet/in.h)
|
||||
|
||||
AC_CHECK_HEADERS(fcntl.h sys/ioctl.h sys/time.h unistd.h stdarg.h netdb.h)
|
||||
AC_CHECK_HEADERS(sys/sockio.h sys/types.h netinet/in.h sys/socket net/if.h)
|
||||
|
||||
dnl SNMP Check
|
||||
AC_ARG_ENABLE(snmp,
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* dfilter.h
|
||||
* Definitions for display filters
|
||||
*
|
||||
* $Id: dfilter.h,v 1.2 1999/07/07 23:54:12 guy Exp $
|
||||
* $Id: dfilter.h,v 1.3 1999/07/13 02:52:48 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -51,6 +51,10 @@ gboolean fill_array_bytes_variable(GNode *gnode, gpointer data);
|
|||
gboolean fill_array_boolean_value(GNode *gnode, gpointer data);
|
||||
gboolean fill_array_boolean_variable(GNode *gnode, gpointer data);
|
||||
|
||||
#ifdef WIN32
|
||||
#define boolean truth_value
|
||||
#endif
|
||||
|
||||
enum node_type {
|
||||
relation, /* eq, ne, gt, ge, lt, le */
|
||||
logical, /* and, or, not, xor */
|
||||
|
|
20
display.c
20
display.c
|
@ -1,7 +1,7 @@
|
|||
/* display.c
|
||||
* Routines for packet display windows
|
||||
*
|
||||
* $Id: display.c,v 1.8 1999/07/09 04:18:34 gram Exp $
|
||||
* $Id: display.c,v 1.9 1999/07/13 02:52:48 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -37,11 +37,29 @@
|
|||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <time.h>
|
||||
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINSOCK_H
|
||||
#include <winsock.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_IOCTL_H
|
||||
#include <sys/ioctl.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NET_IF_H
|
||||
#include <net/if.h>
|
||||
#endif
|
||||
|
||||
#include <signal.h>
|
||||
#include <errno.h>
|
||||
|
||||
|
|
47
ethereal.c
47
ethereal.c
|
@ -1,6 +1,6 @@
|
|||
/* ethereal.c
|
||||
*
|
||||
* $Id: ethereal.c,v 1.52 1999/07/11 08:40:52 guy Exp $
|
||||
* $Id: ethereal.c,v 1.53 1999/07/13 02:52:49 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -49,12 +49,24 @@
|
|||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <errno.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <fcntl.h>
|
||||
|
||||
#ifdef HAVE_DIRECT_H
|
||||
#include <direct.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
#include <netinet/in.h>
|
||||
#endif
|
||||
|
||||
#include <signal.h>
|
||||
|
||||
#ifdef NEED_SNPRINTF_H
|
||||
|
@ -110,11 +122,13 @@ ts_type timestamp_type = RELATIVE;
|
|||
|
||||
GtkStyle *item_style;
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
int sync_mode; /* allow sync */
|
||||
int sync_pipe[2]; /* used to sync father */
|
||||
int fork_mode; /* fork a child to do the capture */
|
||||
int sigusr2_received = 0;
|
||||
int quit_after_cap; /* Makes a "capture only mode". Implies -k */
|
||||
#endif
|
||||
|
||||
/* Specifies byte offsets for object selected in tree */
|
||||
static gint tree_selected_start=-1, tree_selected_len=-1;
|
||||
|
@ -398,7 +412,11 @@ file_open_cmd_cb(GtkWidget *w, gpointer data) {
|
|||
(file_sel)->cancel_button), "clicked", (GtkSignalFunc)
|
||||
gtk_widget_destroy, GTK_OBJECT (file_sel));
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
if( fork_mode && (cf.save_file != NULL) )
|
||||
#else
|
||||
if( cf.save_file != NULL )
|
||||
#endif
|
||||
gtk_file_selection_set_filename(GTK_FILE_SELECTION(file_sel), cf.save_file);
|
||||
else
|
||||
gtk_file_selection_set_filename(GTK_FILE_SELECTION(file_sel), "");
|
||||
|
@ -553,10 +571,14 @@ file_print_cmd_cb(GtkWidget *widget, gpointer data) {
|
|||
void
|
||||
packet_list_select_cb(GtkWidget *w, gint row, gint col, gpointer evt) {
|
||||
|
||||
#ifdef HAVE_PCAP
|
||||
if (!sync_mode) {
|
||||
#endif
|
||||
if (cf.wth)
|
||||
return;
|
||||
#ifdef HAVE_PCAP
|
||||
}
|
||||
#endif
|
||||
blank_packetinfo();
|
||||
gtk_text_freeze(GTK_TEXT(byte_view));
|
||||
gtk_text_set_point(GTK_TEXT(byte_view), 0);
|
||||
|
@ -644,11 +666,13 @@ main_realize_cb(GtkWidget *w, gpointer data) {
|
|||
#endif
|
||||
}
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
static void
|
||||
sigusr2_handler(int sig) {
|
||||
sigusr2_received = 1;
|
||||
signal(SIGUSR2, sigusr2_handler);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* call initialization routines at program startup time */
|
||||
static void
|
||||
|
@ -674,8 +698,11 @@ print_usage(void) {
|
|||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
int opt, i;
|
||||
int i;
|
||||
#ifndef WIN32
|
||||
int opt;
|
||||
extern char *optarg;
|
||||
#endif
|
||||
char *pf_path;
|
||||
int pf_open_errno = 0;
|
||||
int err;
|
||||
|
@ -746,6 +773,7 @@ main(int argc, char *argv[])
|
|||
#endif
|
||||
);
|
||||
|
||||
#ifndef WIN32
|
||||
/* Now get our args */
|
||||
while ((opt = getopt(argc, argv, "b:B:c:f:Fhi:km:nP:Qr:Ss:t:T:w:v")) != EOF) {
|
||||
switch (opt) {
|
||||
|
@ -758,14 +786,14 @@ main(int argc, char *argv[])
|
|||
case 'c': /* Capture xxx packets */
|
||||
cf.count = atoi(optarg);
|
||||
break;
|
||||
case 'f':
|
||||
#ifdef HAVE_LIBPCAP
|
||||
case 'f':
|
||||
cf.cfilter = g_strdup(optarg);
|
||||
#endif
|
||||
break;
|
||||
case 'F': /* Fork to capture */
|
||||
fork_mode = 1;
|
||||
break;
|
||||
#endif
|
||||
case 'h': /* Print help and exit */
|
||||
print_usage();
|
||||
exit(0);
|
||||
|
@ -779,19 +807,24 @@ main(int argc, char *argv[])
|
|||
case 'n': /* No name resolution */
|
||||
g_resolving_actif = 0;
|
||||
break;
|
||||
#ifdef HAVE_LIBPCAP
|
||||
case 'k': /* Start capture immediately */
|
||||
start_capture = 1;
|
||||
break;
|
||||
#endif
|
||||
case 'P': /* Packet list pane height */
|
||||
pl_size = atoi(optarg);
|
||||
break;
|
||||
#ifdef HAVE_LIBPCAP
|
||||
case 'Q': /* Quit after capture (just capture to file) */
|
||||
quit_after_cap = 1;
|
||||
start_capture = 1; /*** -Q implies -k !! ***/
|
||||
break;
|
||||
#endif
|
||||
case 'r': /* Read capture file xxx */
|
||||
cf_name = g_strdup(optarg);
|
||||
break;
|
||||
#ifdef HAVE_LIBPCAP
|
||||
case 's': /* Set the snapshot (capture) length */
|
||||
cf.snap = atoi(optarg);
|
||||
break;
|
||||
|
@ -799,6 +832,7 @@ main(int argc, char *argv[])
|
|||
sync_mode = 1;
|
||||
fork_mode = 1; /* -S implies -F */
|
||||
break;
|
||||
#endif
|
||||
case 't': /* Time stamp type */
|
||||
if (strcmp(optarg, "r") == 0)
|
||||
timestamp_type = RELATIVE;
|
||||
|
@ -821,11 +855,14 @@ main(int argc, char *argv[])
|
|||
printf("%s %s, with %s\n", PACKAGE, VERSION, comp_info_str);
|
||||
exit(0);
|
||||
break;
|
||||
#ifdef HAVE_LIBPCAP
|
||||
case 'w': /* Write capture file xxx */
|
||||
cf.save_file = g_strdup(optarg);
|
||||
break;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (start_capture) {
|
||||
if (cf.iface == NULL) {
|
||||
|
@ -838,8 +875,10 @@ main(int argc, char *argv[])
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
if (sync_mode)
|
||||
signal(SIGUSR2, sigusr2_handler);
|
||||
#endif
|
||||
|
||||
/* Build the column format array */
|
||||
col_fmt = (gint *) g_malloc(sizeof(gint) * cf.cinfo.num_cols);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* ethereal.h
|
||||
* Global defines, etc.
|
||||
*
|
||||
* $Id: ethereal.h,v 1.15 1999/06/24 16:25:59 gram Exp $
|
||||
* $Id: ethereal.h,v 1.16 1999/07/13 02:52:49 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -34,8 +34,11 @@
|
|||
#define MONO_BOLD_FONT "-*-lucidatypewriter-bold-r-normal-*-*-120-*-*-*-*-iso8859-1"
|
||||
#define DEF_WIDTH 750
|
||||
#define DEF_HEIGHT 550
|
||||
#ifdef HAVE_LIBPCAP
|
||||
#define DEF_READY_MESSAGE " Ready to load or capture"
|
||||
#define EXTERNAL_FILTER "/usr/local/bin/ethereal_tcp_filter -f"
|
||||
#else
|
||||
#define DEF_READY_MESSAGE " Ready to load file"
|
||||
#endif
|
||||
|
||||
#define MIN_PACKET_SIZE 68 /* minimum amount of packet data we can read */
|
||||
#define MAX_PACKET_SIZE 65535 /* maximum amount of packet data we can read */
|
||||
|
|
20
file.c
20
file.c
|
@ -1,7 +1,7 @@
|
|||
/* file.c
|
||||
* File I/O routines
|
||||
*
|
||||
* $Id: file.c,v 1.36 1999/07/11 08:40:52 guy Exp $
|
||||
* $Id: file.c,v 1.37 1999/07/13 02:52:49 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -30,7 +30,15 @@
|
|||
#include <gtk/gtk.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_IO_H
|
||||
#include <io.h>
|
||||
#endif
|
||||
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <errno.h>
|
||||
|
@ -86,7 +94,9 @@ static void wtap_dispatch_cb(u_char *, const struct wtap_pkthdr *, int,
|
|||
static void init_col_widths(capture_file *);
|
||||
static void set_col_widths(capture_file *);
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
static gint tail_timeout_cb(gpointer);
|
||||
#endif
|
||||
|
||||
int
|
||||
open_cap_file(char *fname, capture_file *cf) {
|
||||
|
@ -95,8 +105,10 @@ open_cap_file(char *fname, capture_file *cf) {
|
|||
/* First, make sure the file is valid */
|
||||
if (stat(fname, &cf_stat))
|
||||
return (errno);
|
||||
#ifndef WIN32
|
||||
if (! S_ISREG(cf_stat.st_mode) && ! S_ISFIFO(cf_stat.st_mode))
|
||||
return (OPEN_CAP_FILE_NOT_REGULAR);
|
||||
#endif
|
||||
|
||||
/* Next, try to open the file */
|
||||
cf->fh = fopen(fname, "r");
|
||||
|
@ -259,6 +271,7 @@ load_cap_file(char *fname, capture_file *cf) {
|
|||
return err;
|
||||
}
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
void
|
||||
cap_file_input_cb (gpointer data, gint source, GdkInputCondition condition) {
|
||||
|
||||
|
@ -404,6 +417,7 @@ tail_cap_file(char *fname, capture_file *cf) {
|
|||
}
|
||||
return err;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void
|
||||
compute_time_stamps(frame_data *fdata, capture_file *cf)
|
||||
|
@ -690,16 +704,20 @@ file_mv(char *from, char *to)
|
|||
|
||||
int retval;
|
||||
|
||||
#ifndef WIN32
|
||||
/* try a hard link */
|
||||
retval = link(from, to);
|
||||
|
||||
/* or try a copy */
|
||||
if (retval < 0) {
|
||||
#endif
|
||||
retval = file_cp(from, to);
|
||||
if (!retval) {
|
||||
return 0;
|
||||
}
|
||||
#ifndef WIN32
|
||||
}
|
||||
#endif
|
||||
|
||||
unlink(from);
|
||||
return 1;
|
||||
|
|
7
file.h
7
file.h
|
@ -1,7 +1,7 @@
|
|||
/* file.h
|
||||
* Definitions for file structures and routines
|
||||
*
|
||||
* $Id: file.h,v 1.19 1999/07/09 04:18:35 gram Exp $
|
||||
* $Id: file.h,v 1.20 1999/07/13 02:52:50 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -26,8 +26,13 @@
|
|||
#ifndef __FILE_H__
|
||||
#define __FILE_H__
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_TIME_H
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
|
||||
#ifndef __WTAP_H__
|
||||
#include <wtap.h>
|
||||
|
|
11
filter.c
11
filter.c
|
@ -1,7 +1,7 @@
|
|||
/* filter.c
|
||||
* Routines for managing filter sets
|
||||
*
|
||||
* $Id: filter.c,v 1.12 1998/12/27 20:44:53 gerald Exp $
|
||||
* $Id: filter.c,v 1.13 1999/07/13 02:52:50 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -32,8 +32,13 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
#include <ctype.h>
|
||||
#ifdef HAVE_DIRECT_H
|
||||
#include <direct.h>
|
||||
#endif
|
||||
|
||||
#include "ethereal.h"
|
||||
#include "filter.h"
|
||||
|
@ -425,7 +430,11 @@ filter_prefs_save(GtkWidget *w) {
|
|||
sprintf(ff_path, "%s/%s", getenv("HOME"), ff_dir);
|
||||
|
||||
if (stat(ff_path, &s_buf) != 0)
|
||||
#ifdef WIN32
|
||||
mkdir(ff_path);
|
||||
#else
|
||||
mkdir(ff_path, 0755);
|
||||
#endif
|
||||
|
||||
sprintf(ff_path, "%s/%s/%s", getenv("HOME"), ff_dir, ff_name);
|
||||
|
||||
|
|
4
follow.c
4
follow.c
|
@ -1,6 +1,6 @@
|
|||
/* follow.c
|
||||
*
|
||||
* $Id: follow.c,v 1.10 1999/07/07 22:51:39 gram Exp $
|
||||
* $Id: follow.c,v 1.11 1999/07/13 02:52:51 gram Exp $
|
||||
*
|
||||
* Copyright 1998 Mike Hall <mlh@io.com>
|
||||
*
|
||||
|
@ -33,7 +33,9 @@
|
|||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
# include <sys/types.h>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Routines for the Generic Routing Encapsulation (GRE) protocol
|
||||
* Brad Robel-Forrest <brad.robel-forrest@watchguard.com>
|
||||
*
|
||||
* $Id: packet-gre.c,v 1.2 1999/07/07 22:51:43 gram Exp $
|
||||
* $Id: packet-gre.c,v 1.3 1999/07/13 02:52:51 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -32,7 +32,9 @@
|
|||
# include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
#include <netinet/in.h>
|
||||
#endif
|
||||
#include <glib.h>
|
||||
#include "packet.h"
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
*
|
||||
* Guy Harris <guy@netapp.com>
|
||||
*
|
||||
* $Id: packet-http.c,v 1.4 1999/07/07 22:51:43 gram Exp $
|
||||
* $Id: packet-http.c,v 1.5 1999/07/13 02:52:51 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -27,7 +27,9 @@
|
|||
*
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
#include <sys/types.h>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* packet-icmpv6.c
|
||||
* Routines for ICMPv6 packet disassembly
|
||||
*
|
||||
* $Id: packet-icmpv6.c,v 1.3 1999/07/07 22:51:44 gram Exp $
|
||||
* $Id: packet-icmpv6.c,v 1.4 1999/07/13 02:52:51 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -28,7 +28,11 @@
|
|||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* packet-ipv6.c
|
||||
* Routines for IPv6 packet disassembly
|
||||
*
|
||||
* $Id: packet-ipv6.c,v 1.9 1999/07/07 22:51:45 gram Exp $
|
||||
* $Id: packet-ipv6.c,v 1.10 1999/07/13 02:52:52 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -30,7 +30,10 @@
|
|||
#ifdef HAVE_SYS_TYPES_H
|
||||
# include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_SOCKET_h
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
# include <netinet/in.h>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Routines for the Internet Security Association and Key Management Protocol (ISAKMP)
|
||||
* Brad Robel-Forrest <brad.robel-forrest@watchguard.com>
|
||||
*
|
||||
* $Id: packet-isakmp.c,v 1.5 1999/07/08 06:03:21 guy Exp $
|
||||
* $Id: packet-isakmp.c,v 1.6 1999/07/13 02:52:52 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -33,7 +33,11 @@
|
|||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
#include <netinet/in.h>
|
||||
#endif
|
||||
|
||||
#include <glib.h>
|
||||
#include "packet.h"
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Routines for NetWare Core Protocol
|
||||
* Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
*
|
||||
* $Id: packet-ncp.c,v 1.16 1999/07/07 22:51:48 gram Exp $
|
||||
* $Id: packet-ncp.c,v 1.17 1999/07/13 02:52:52 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -653,7 +653,8 @@ parse_ncp_svc_fields(const u_char *pd, proto_tree *ncp_tree, int offset,
|
|||
break;
|
||||
|
||||
default:
|
||||
/* nothing */
|
||||
; /* nothing */
|
||||
break;
|
||||
}
|
||||
field_offset += field_length;
|
||||
rec++;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* packet-null.c
|
||||
* Routines for null packet disassembly
|
||||
*
|
||||
* $Id: packet-null.c,v 1.8 1999/07/07 22:51:49 gram Exp $
|
||||
* $Id: packet-null.c,v 1.9 1999/07/13 02:52:53 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -33,7 +33,10 @@
|
|||
#endif
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#include "packet.h"
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Routines for the Point-to-Point Tunnelling Protocol (PPTP)
|
||||
* Brad Robel-Forrest <brad.robel-forrest@watchguard.com>
|
||||
*
|
||||
* $Id: packet-pptp.c,v 1.2 1999/07/07 22:51:51 gram Exp $
|
||||
* $Id: packet-pptp.c,v 1.3 1999/07/13 02:52:53 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -33,7 +33,11 @@
|
|||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
#include <netinet/in.h>
|
||||
#endif
|
||||
|
||||
#include <glib.h>
|
||||
#include "packet.h"
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* packet-radius.c
|
||||
* Routines for RADIUS packet disassembly
|
||||
*
|
||||
* $Id: packet-radius.c,v 1.1 1999/07/08 04:23:04 gram Exp $
|
||||
* $Id: packet-radius.c,v 1.2 1999/07/13 02:52:54 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Johan Feyaerts
|
||||
|
@ -510,8 +510,7 @@ void dissect_attribute_value_pairs(const u_char *pd, int offset, frame_data
|
|||
gchar *valstr;
|
||||
if (avplength==0)
|
||||
{
|
||||
proto_tree_add_text(tree,offset,0,"No Attribute Value Pairs
|
||||
Found");
|
||||
proto_tree_add_text(tree,offset,0,"No Attribute Value Pairs Found");
|
||||
return;
|
||||
}
|
||||
while (avplength > 0 )
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
*
|
||||
* (c) Copyright Ashok Narayanan <ashokn@cisco.com>
|
||||
*
|
||||
* $Id: packet-rsvp.c,v 1.2 1999/07/07 22:51:52 gram Exp $
|
||||
* $Id: packet-rsvp.c,v 1.3 1999/07/13 02:52:55 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -42,7 +42,11 @@
|
|||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* (C) Ashok Narayanan <ashokn@cisco.com>
|
||||
*
|
||||
* $Id: packet-rsvp.h,v 1.1 1999/06/11 16:44:51 gram Exp $
|
||||
* $Id: packet-rsvp.h,v 1.2 1999/07/13 02:52:55 gram Exp $
|
||||
*
|
||||
* For license details, see the COPYING file with this distribution
|
||||
*
|
||||
|
@ -195,7 +195,7 @@ typedef struct {
|
|||
unsigned short length;
|
||||
unsigned char class;
|
||||
unsigned char type;
|
||||
unsigned char data[0];
|
||||
unsigned char *data;
|
||||
} rsvp_object;
|
||||
|
||||
/*
|
||||
|
@ -209,7 +209,7 @@ typedef struct {
|
|||
unsigned char sending_ttl; /* ttl of message */
|
||||
unsigned char reserved_byte; /* reserved */
|
||||
unsigned short rsvp_length; /* length of RSVP data */
|
||||
rsvp_object rsvp_first_object[0];
|
||||
rsvp_object *rsvp_first_object;
|
||||
} rsvp_header;
|
||||
|
||||
/*
|
||||
|
@ -299,7 +299,7 @@ typedef struct {
|
|||
*/
|
||||
typedef struct {
|
||||
rsvp_object base;
|
||||
unsigned long source[0];
|
||||
unsigned long *source;
|
||||
} rsvp_scope;
|
||||
|
||||
/*
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Routines for smb packet dissection
|
||||
* Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
|
||||
*
|
||||
* $Id: packet-smb.c,v 1.18 1999/07/12 14:26:13 sharpe Exp $
|
||||
* $Id: packet-smb.c,v 1.19 1999/07/13 02:52:56 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -1378,7 +1378,8 @@ dissect_tcon_andx_smb(const u_char *pd, int offset, frame_data *fd, proto_tree *
|
|||
break;
|
||||
|
||||
default:
|
||||
|
||||
; /* nothing */
|
||||
break;
|
||||
}
|
||||
|
||||
if (andxcmd != 0xFF) /* Process that next command ... ??? */
|
||||
|
|
9
packet.c
9
packet.c
|
@ -1,7 +1,7 @@
|
|||
/* packet.c
|
||||
* Routines for packet disassembly
|
||||
*
|
||||
* $Id: packet.c,v 1.29 1999/07/07 22:51:57 gram Exp $
|
||||
* $Id: packet.c,v 1.30 1999/07/13 02:52:57 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -30,7 +30,14 @@
|
|||
#ifdef HAVE_SYS_TYPES_H
|
||||
# include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINSOCK_H
|
||||
#include <winsock.h>
|
||||
#endif
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
|
|
14
prefs.c
14
prefs.c
|
@ -1,7 +1,7 @@
|
|||
/* prefs.c
|
||||
* Routines for handling preferences
|
||||
*
|
||||
* $Id: prefs.c,v 1.18 1999/06/21 19:04:35 gram Exp $
|
||||
* $Id: prefs.c,v 1.19 1999/07/13 02:52:57 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -31,12 +31,20 @@
|
|||
#include <sys/types.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_DIRECT_H
|
||||
#include <direct.h>
|
||||
#endif
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
#include <errno.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "ethereal.h"
|
||||
|
@ -484,7 +492,11 @@ write_prefs() {
|
|||
|
||||
sprintf(pf_path, "%s/%s", getenv("HOME"), PF_DIR);
|
||||
if (stat(pf_path, &s_buf) != 0)
|
||||
#ifdef WIN32
|
||||
mkdir(pf_path);
|
||||
#else
|
||||
mkdir(pf_path, 0755);
|
||||
#endif
|
||||
|
||||
sprintf(pf_path, "%s/%s/%s", getenv("HOME"), PF_DIR, PF_NAME);
|
||||
if ((pf = fopen(pf_path, "w")) == NULL) {
|
||||
|
|
9
proto.h
9
proto.h
|
@ -1,7 +1,7 @@
|
|||
/* proto.h
|
||||
* Definitions for protocol display
|
||||
*
|
||||
* $Id: proto.h,v 1.2 1999/07/07 23:54:12 guy Exp $
|
||||
* $Id: proto.h,v 1.3 1999/07/13 02:52:58 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -33,6 +33,10 @@
|
|||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINSOCK_H
|
||||
#include <winsock.h>
|
||||
#endif
|
||||
|
||||
/* needs glib.h */
|
||||
typedef struct GNode proto_tree;
|
||||
typedef struct GNode proto_item;
|
||||
|
@ -92,6 +96,9 @@ typedef struct hf_register_info {
|
|||
struct value_string *vals;
|
||||
} hf_register_info;
|
||||
|
||||
#ifdef WIN32
|
||||
#define boolean truth_value
|
||||
#endif
|
||||
|
||||
/* Info stored in each proto_item GNode */
|
||||
typedef struct field_info {
|
||||
|
|
22
resolv.c
22
resolv.c
|
@ -1,7 +1,7 @@
|
|||
/* resolv.c
|
||||
* Routines for network object lookup
|
||||
*
|
||||
* $Id: resolv.c,v 1.7 1999/07/07 22:51:59 gram Exp $
|
||||
* $Id: resolv.c,v 1.8 1999/07/13 02:52:58 gram Exp $
|
||||
*
|
||||
* Laurent Deniel <deniel@worldnet.fr>
|
||||
*
|
||||
|
@ -29,15 +29,21 @@
|
|||
# include "config.h"
|
||||
#endif
|
||||
|
||||
#ifndef AVOID_DNS_TIMEOUT
|
||||
#define AVOID_DNS_TIMEOUT
|
||||
#endif
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifndef WIN32
|
||||
#ifndef AVOID_DNS_TIMEOUT
|
||||
#define AVOID_DNS_TIMEOUT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
# include <sys/types.h>
|
||||
|
@ -47,9 +53,15 @@
|
|||
# include <netinet/in.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_NETDB_H
|
||||
#include <netdb.h>
|
||||
#endif
|
||||
|
||||
#include <signal.h>
|
||||
|
||||
#ifdef HAVE_SYS_SOCKET_H
|
||||
#include <sys/socket.h>
|
||||
#endif
|
||||
|
||||
#ifdef AVOID_DNS_TIMEOUT
|
||||
# include <setjmp.h>
|
||||
|
|
7
smb.h
7
smb.h
|
@ -2,7 +2,7 @@
|
|||
* Defines for smb packet dissection
|
||||
* Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
|
||||
*
|
||||
* $Id: smb.h,v 1.2 1999/05/11 07:22:31 guy Exp $
|
||||
* $Id: smb.h,v 1.3 1999/07/13 02:52:58 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@unicom.net>
|
||||
|
@ -30,8 +30,13 @@
|
|||
#ifndef _SMB_H
|
||||
#define _SMB_H
|
||||
|
||||
#ifndef min
|
||||
#define min(a,b) (a < b ? a : b)
|
||||
#endif
|
||||
|
||||
#ifndef max
|
||||
#define max(a,b) (a > b ? a : b)
|
||||
#endif
|
||||
|
||||
#define SMB_PORT 139
|
||||
#define NMB_PORT 137
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/* summary.c
|
||||
* Routines for capture file summary window
|
||||
*
|
||||
* $Id: summary.c,v 1.4 1999/07/09 04:18:36 gram Exp $
|
||||
* $Id: summary.c,v 1.5 1999/07/13 02:52:59 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -37,7 +37,10 @@
|
|||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef HAVE_UNISTD_H
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
#ifdef NEED_SNPRINTF_H
|
||||
# ifdef HAVE_STDARG_H
|
||||
|
@ -217,8 +220,7 @@ string_for_format(cf.cd_t));
|
|||
secs_usecs(cf.esec,cf.eusec));
|
||||
add_string_to_box(string_buff, data_box);
|
||||
|
||||
snprintf(string_buff, SUM_STR_MAX, "Between first and last packet: %.3f
|
||||
seconds", seconds);
|
||||
snprintf(string_buff, SUM_STR_MAX, "Between first and last packet: %.3f seconds", seconds);
|
||||
add_string_to_box(string_buff, data_box);
|
||||
|
||||
/* Packet count */
|
||||
|
|
11
timestamp.h
11
timestamp.h
|
@ -1,7 +1,7 @@
|
|||
/* timestamp.h
|
||||
* Defines for packet timestamps
|
||||
*
|
||||
* $Id: timestamp.h,v 1.1 1999/06/19 01:47:43 guy Exp $
|
||||
* $Id: timestamp.h,v 1.2 1999/07/13 02:52:59 gram Exp $
|
||||
*
|
||||
* Ethereal - Network traffic analyzer
|
||||
* By Gerald Combs <gerald@zing.org>
|
||||
|
@ -26,6 +26,15 @@
|
|||
#ifndef __TIMESTAMP_H__
|
||||
#define __TIMESTAMP_H__
|
||||
|
||||
/* MS VC has these macros */
|
||||
#ifdef RELATIVE
|
||||
#undef RELATIVE
|
||||
#endif
|
||||
|
||||
#ifdef ABSOLUTE
|
||||
#undef ABSOLUTE
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Type of time-stamp shown in the summary display.
|
||||
*/
|
||||
|
|
|
@ -59,6 +59,7 @@ NORMAL_UNINSTALL = :
|
|||
PRE_UNINSTALL = :
|
||||
POST_UNINSTALL = :
|
||||
CC = @CC@
|
||||
CPP = @CPP@
|
||||
GLIB_CFLAGS = @GLIB_CFLAGS@
|
||||
GLIB_CONFIG = @GLIB_CONFIG@
|
||||
GLIB_LIBS = @GLIB_LIBS@
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
GLIB_DIR=d:\prj\w\src\glib
|
||||
LOCAL_CFLAGS=/Ic:\tools\msdev\include
|
||||
|
||||
#################3
|
||||
CFLAGS=/DHAVE_CONFIG_H /I$(GLIB_DIR) $(LOCAL_CFLAGS)
|
||||
|
||||
OBJECTS=buffer.obj file.obj iptrace.obj lanalyzer.obj libpcap.obj \
|
||||
netmon.obj netxray.obj ngsniffer.obj snoop.obj wtap.obj
|
||||
|
||||
|
||||
libwtap.lib : config.h $(OBJECTS)
|
||||
lib /out:libwtap.lib $(OBJECTS)
|
||||
|
||||
|
||||
config.h : config.h.win32
|
||||
copy config.h.win32 $@
|
||||
|
|
@ -5,6 +5,12 @@
|
|||
|
||||
#undef HAVE_GLIB10
|
||||
|
||||
/* Define if you have the <netinet/in.h> header file. */
|
||||
#undef HAVE_NETINET_IN_H
|
||||
|
||||
/* Define if you have the <sys/time.h> header file. */
|
||||
#undef HAVE_SYS_TIME_H
|
||||
|
||||
/* Define if you have the <unistd.h> header file. */
|
||||
#undef HAVE_UNISTD_H
|
||||
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
|
||||
/* Define if you have the ANSI C header files. */
|
||||
#define STDC_HEADERS 1
|
||||
|
||||
/* Define if you have the <unistd.h> header file. */
|
||||
/* #define HAVE_UNISTD_H */
|
||||
|
||||
/* Name of package */
|
||||
#define PACKAGE "libwtap.a"
|
||||
|
||||
/* Version number of package */
|
||||
#define VERSION "0.0.0"
|
||||
|
||||
#define HAVE_WINSOCK_H
|
|
@ -1012,10 +1012,90 @@ else
|
|||
fi
|
||||
fi
|
||||
|
||||
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
|
||||
echo "configure:1017: checking how to run the C preprocessor" >&5
|
||||
# On Suns, sometimes $CPP names a directory.
|
||||
if test -n "$CPP" && test -d "$CPP"; then
|
||||
CPP=
|
||||
fi
|
||||
if test -z "$CPP"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
# This must be in double quotes, not single quotes, because CPP may get
|
||||
# substituted into the Makefile and "${CC-cc}" will confuse make.
|
||||
CPP="${CC-cc} -E"
|
||||
# On the NeXT, cc -E runs the code through the compiler's parser,
|
||||
# not just through cpp.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1032 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1038: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -E -traditional-cpp"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1049 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1055: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -nologo -E"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1066 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP=/lib/cpp
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
CPP="$ac_cv_prog_CPP"
|
||||
else
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
echo "$ac_t""$CPP" 1>&6
|
||||
|
||||
# Extract the first word of "ranlib", so it can be a program name with args.
|
||||
set dummy ranlib; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1019: checking for $ac_word" >&5
|
||||
echo "configure:1099: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1045,7 +1125,7 @@ fi
|
|||
|
||||
# If we're running gcc, add '-Wall' to CFLAGS.
|
||||
echo $ac_n "checking to see if we can add '-Wall' to CFLAGS""... $ac_c" 1>&6
|
||||
echo "configure:1049: checking to see if we can add '-Wall' to CFLAGS" >&5
|
||||
echo "configure:1129: checking to see if we can add '-Wall' to CFLAGS" >&5
|
||||
if test x$GCC != x ; then
|
||||
CFLAGS="-Wall $CFLAGS"
|
||||
echo "$ac_t""yes" 1>&6
|
||||
|
@ -1107,7 +1187,7 @@ fi
|
|||
# Extract the first word of "glib-config", so it can be a program name with args.
|
||||
set dummy glib-config; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1111: checking for $ac_word" >&5
|
||||
echo "configure:1191: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_path_GLIB_CONFIG'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1142,7 +1222,7 @@ fi
|
|||
|
||||
min_glib_version=1.1.0
|
||||
echo $ac_n "checking for GLIB - version >= $min_glib_version""... $ac_c" 1>&6
|
||||
echo "configure:1146: checking for GLIB - version >= $min_glib_version" >&5
|
||||
echo "configure:1226: checking for GLIB - version >= $min_glib_version" >&5
|
||||
no_glib=""
|
||||
if test "$GLIB_CONFIG" = "no" ; then
|
||||
no_glib=yes
|
||||
|
@ -1165,7 +1245,7 @@ echo "configure:1146: checking for GLIB - version >= $min_glib_version" >&5
|
|||
echo $ac_n "cross compiling; assumed OK... $ac_c"
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1169 "configure"
|
||||
#line 1249 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <glib.h>
|
||||
|
@ -1241,7 +1321,7 @@ main ()
|
|||
}
|
||||
|
||||
EOF
|
||||
if { (eval echo configure:1245: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:1325: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
:
|
||||
else
|
||||
|
@ -1275,7 +1355,7 @@ fi
|
|||
CFLAGS="$CFLAGS $GLIB_CFLAGS"
|
||||
LIBS="$LIBS $GLIB_LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1279 "configure"
|
||||
#line 1359 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <glib.h>
|
||||
|
@ -1285,7 +1365,7 @@ int main() {
|
|||
return ((glib_major_version) || (glib_minor_version) || (glib_micro_version));
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1369: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
echo "*** The test program compiled, but did not run. This usually means"
|
||||
echo "*** that the run-time linker is not finding GLIB or finding the wrong"
|
||||
|
@ -1375,7 +1455,7 @@ fi
|
|||
# Extract the first word of "gtk-config", so it can be a program name with args.
|
||||
set dummy gtk-config; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1379: checking for $ac_word" >&5
|
||||
echo "configure:1459: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
@ -1410,7 +1490,7 @@ fi
|
|||
|
||||
min_gtk_version=1.0.0
|
||||
echo $ac_n "checking for GTK - version >= $min_gtk_version""... $ac_c" 1>&6
|
||||
echo "configure:1414: checking for GTK - version >= $min_gtk_version" >&5
|
||||
echo "configure:1494: checking for GTK - version >= $min_gtk_version" >&5
|
||||
no_gtk=""
|
||||
if test "$GTK_CONFIG" = "no" ; then
|
||||
no_gtk=yes
|
||||
|
@ -1433,7 +1513,7 @@ echo "configure:1414: checking for GTK - version >= $min_gtk_version" >&5
|
|||
echo $ac_n "cross compiling; assumed OK... $ac_c"
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1437 "configure"
|
||||
#line 1517 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
|
@ -1511,7 +1591,7 @@ main ()
|
|||
}
|
||||
|
||||
EOF
|
||||
if { (eval echo configure:1515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:1595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
:
|
||||
else
|
||||
|
@ -1545,7 +1625,7 @@ fi
|
|||
CFLAGS="$CFLAGS $GTK_CFLAGS"
|
||||
LIBS="$LIBS $GTK_LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1549 "configure"
|
||||
#line 1629 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
|
@ -1555,7 +1635,7 @@ int main() {
|
|||
return ((gtk_major_version) || (gtk_minor_version) || (gtk_micro_version));
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1559: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
echo "*** The test program compiled, but did not run. This usually means"
|
||||
echo "*** that the run-time linker is not finding GTK or finding the wrong"
|
||||
|
@ -1599,86 +1679,6 @@ EOF
|
|||
|
||||
fi
|
||||
|
||||
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
|
||||
echo "configure:1604: checking how to run the C preprocessor" >&5
|
||||
# On Suns, sometimes $CPP names a directory.
|
||||
if test -n "$CPP" && test -d "$CPP"; then
|
||||
CPP=
|
||||
fi
|
||||
if test -z "$CPP"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
# This must be in double quotes, not single quotes, because CPP may get
|
||||
# substituted into the Makefile and "${CC-cc}" will confuse make.
|
||||
CPP="${CC-cc} -E"
|
||||
# On the NeXT, cc -E runs the code through the compiler's parser,
|
||||
# not just through cpp.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1619 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1625: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -E -traditional-cpp"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1636 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1642: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP="${CC-cc} -nologo -E"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1653 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1659: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
CPP=/lib/cpp
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
fi
|
||||
rm -f conftest*
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
CPP="$ac_cv_prog_CPP"
|
||||
else
|
||||
ac_cv_prog_CPP="$CPP"
|
||||
fi
|
||||
echo "$ac_t""$CPP" 1>&6
|
||||
|
||||
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
|
||||
echo "configure:1684: checking for ANSI C header files" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
|
||||
|
@ -1783,7 +1783,7 @@ EOF
|
|||
|
||||
fi
|
||||
|
||||
for ac_hdr in unistd.h
|
||||
for ac_hdr in unistd.h sys/time.h netinet/in.h
|
||||
do
|
||||
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
|
||||
|
@ -1969,6 +1969,7 @@ s%@AUTOHEADER@%$AUTOHEADER%g
|
|||
s%@MAKEINFO@%$MAKEINFO%g
|
||||
s%@SET_MAKE@%$SET_MAKE%g
|
||||
s%@CC@%$CC%g
|
||||
s%@CPP@%$CPP%g
|
||||
s%@RANLIB@%$RANLIB%g
|
||||
s%@GLIB_CONFIG@%$GLIB_CONFIG%g
|
||||
s%@GLIB_CFLAGS@%$GLIB_CFLAGS%g
|
||||
|
@ -1976,7 +1977,6 @@ s%@GLIB_LIBS@%$GLIB_LIBS%g
|
|||
s%@GTK_CONFIG@%$GTK_CONFIG%g
|
||||
s%@GTK_CFLAGS@%$GTK_CFLAGS%g
|
||||
s%@GTK_LIBS@%$GTK_LIBS%g
|
||||
s%@CPP@%$CPP%g
|
||||
|
||||
CEOF
|
||||
EOF
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# $Id: configure.in,v 1.11 1999/07/08 04:23:28 gram Exp $
|
||||
# $Id: configure.in,v 1.12 1999/07/13 02:53:23 gram Exp $
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
AC_INIT(wtap.c)
|
||||
AM_INIT_AUTOMAKE(libwtap.a, 0.0.0)
|
||||
|
@ -6,6 +6,7 @@ AM_CONFIG_HEADER(config.h)
|
|||
|
||||
dnl Checks for programs.
|
||||
AC_PROG_CC
|
||||
AC_PROG_CPP
|
||||
AC_PROG_RANLIB
|
||||
|
||||
# If we're running gcc, add '-Wall' to CFLAGS.
|
||||
|
@ -28,6 +29,6 @@ fi
|
|||
|
||||
dnl Checks for header files
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS(unistd.h)
|
||||
AC_CHECK_HEADERS(unistd.h sys/time.h netinet/in.h)
|
||||
|
||||
AC_OUTPUT(Makefile)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* file.c
|
||||
*
|
||||
* $Id: file.c,v 1.10 1999/07/07 22:52:54 gram Exp $
|
||||
* $Id: file.c,v 1.11 1999/07/13 02:53:23 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,7 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* iptrace.c
|
||||
*
|
||||
* $Id: iptrace.c,v 1.3 1999/03/01 18:57:04 gram Exp $
|
||||
* $Id: iptrace.c,v 1.4 1999/07/13 02:53:23 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,6 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include <stdlib.h>
|
||||
#include <time.h>
|
||||
#include <string.h>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* lanalyzer.c
|
||||
*
|
||||
* $Id: lanalyzer.c,v 1.9 1999/03/01 18:57:05 gram Exp $
|
||||
* $Id: lanalyzer.c,v 1.10 1999/07/13 02:53:24 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,6 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include <stdlib.h>
|
||||
#include <time.h>
|
||||
#include "wtap.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* libpcap.c
|
||||
*
|
||||
* $Id: libpcap.c,v 1.4 1999/03/01 18:57:05 gram Exp $
|
||||
* $Id: libpcap.c,v 1.5 1999/07/13 02:53:24 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,6 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include "wtap.h"
|
||||
#include "buffer.h"
|
||||
#include "libpcap.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* netmon.c
|
||||
*
|
||||
* $Id: netmon.c,v 1.7 1999/05/12 21:40:06 guy Exp $
|
||||
* $Id: netmon.c,v 1.8 1999/07/13 02:53:24 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,6 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include <time.h>
|
||||
#include "wtap.h"
|
||||
#include "buffer.h"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* netxray.c
|
||||
*
|
||||
* $Id: netxray.c,v 1.7 1999/05/12 21:40:06 guy Exp $
|
||||
* $Id: netxray.c,v 1.8 1999/07/13 02:53:25 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,6 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <time.h>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* ngsniffer.c
|
||||
*
|
||||
* $Id: ngsniffer.c,v 1.12 1999/03/01 18:57:06 gram Exp $
|
||||
* $Id: ngsniffer.c,v 1.13 1999/07/13 02:53:25 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -55,6 +55,9 @@
|
|||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <time.h>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* snoop.c
|
||||
*
|
||||
* $Id: snoop.c,v 1.4 1999/03/01 18:57:07 gram Exp $
|
||||
* $Id: snoop.c,v 1.5 1999/07/13 02:53:26 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,10 +20,15 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include "wtap.h"
|
||||
#include "buffer.h"
|
||||
#include "snoop.h"
|
||||
#ifdef HAVE_NETINET_IN_H
|
||||
#include <netinet/in.h>
|
||||
#endif
|
||||
|
||||
/* See RFC 1761 for a description of the "snoop" file format. */
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* wtap.c
|
||||
*
|
||||
* $Id: wtap.c,v 1.9 1999/07/07 22:58:37 gram Exp $
|
||||
* $Id: wtap.c,v 1.10 1999/07/13 02:53:26 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -20,7 +20,9 @@
|
|||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#include "wtap.h"
|
||||
#include "buffer.h"
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
/* wtap.h
|
||||
*
|
||||
* $Id: wtap.h,v 1.19 1999/07/07 22:52:57 gram Exp $
|
||||
* $Id: wtap.h,v 1.20 1999/07/13 02:53:26 gram Exp $
|
||||
*
|
||||
* Wiretap Library
|
||||
* Copyright (c) 1998 by Gilbert Ramirez <gram@verdict.uthscsa.edu>
|
||||
|
@ -59,7 +59,15 @@
|
|||
#define WTAP_FILTER_BPF 2
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#ifdef HAVE_SYS_TIME_H
|
||||
#include <sys/time.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WINSOCK_H
|
||||
#include <winsock.h>
|
||||
#endif
|
||||
|
||||
#include <glib.h>
|
||||
#include <stdio.h>
|
||||
|
||||
|
|
Loading…
Reference in New Issue