summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorguy <guy>2002-06-28 10:36:23 +0000
committerguy <guy>2002-06-28 10:36:23 +0000
commit1d1a2ab9331b6b9c96e9a8ed2ccad8ac9628f170 (patch)
tree4c912c8b14a731645e6cd34bfc4560e99bbae81e
parent529c99f337854c4e0d766670b74f371042596a7a (diff)
downloadlibpcap-1d1a2ab9331b6b9c96e9a8ed2ccad8ac9628f170.tar.gz
Some versions of the HP C compiler can handle inlines, but not if they
return a structure pointer. Check whether the C compiler can handle inline functions that return a structure pointer, not whether they can handle inline functions that return an int, as at least some versions of autoconf's AC_C_INLINE do.
-rw-r--r--aclocal.m447
-rw-r--r--config.h.in6
-rwxr-xr-xconfigure241
-rw-r--r--configure.in6
4 files changed, 186 insertions, 114 deletions
diff --git a/aclocal.m4 b/aclocal.m4
index d0f79005..ddd10aba 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,4 +1,4 @@
-dnl @(#) $Header: /tcpdump/master/libpcap/aclocal.m4,v 1.75 2001-12-10 08:33:41 guy Exp $ (LBL)
+dnl @(#) $Header: /tcpdump/master/libpcap/aclocal.m4,v 1.75.2.1 2002-06-28 10:36:23 guy Exp $ (LBL)
dnl
dnl Copyright (c) 1995, 1996, 1997, 1998
dnl The Regents of the University of California. All rights reserved.
@@ -157,6 +157,51 @@ AC_DEFUN(AC_LBL_C_INIT,
fi
])
+#
+# Try compiling a sample of the type of code that appears in
+# gencode.c with "inline", "__inline__", and "__inline".
+#
+# Autoconf's AC_C_INLINE, at least in autoconf 2.13, isn't good enough,
+# as it just tests whether a function returning "int" can be inlined;
+# at least some versions of HP's C compiler can inline that, but can't
+# inline a function that returns a struct pointer.
+#
+AC_DEFUN(AC_LBL_C_INLINE,
+ [AC_MSG_CHECKING(for inline)
+ AC_CACHE_VAL(ac_cv_lbl_inline, [
+ ac_cv_lbl_inline=""
+ ac_lbl_cc_inline=no
+ for i in inline __inline__ __inline
+ do
+ AC_TRY_COMPILE(
+ [#define inline $i
+ static inline struct iltest *foo(void);],
+ [struct iltest {
+ int iltest1;
+ int iltest2;
+ };
+
+ static inline struct iltest *
+ foo()
+ {
+ struct iltest xxx;
+
+ return &xxx;
+ }],ac_lbl_cc_inline=yes,)
+ if test $ac_lbl_cc_inline = yes ; then
+ break;
+ fi
+ done
+ if test $ac_lbl_cc_inline = yes ; then
+ ac_cv_lbl_inline=$i
+ fi])
+ if test ! -z $ac_cv_lbl_inline ; then
+ AC_MSG_RESULT($ac_cv_lbl_inline)
+ else
+ AC_MSG_RESULT(not supported)
+ fi
+ AC_DEFINE_UNQUOTED(inline, $ac_cv_lbl_inline, [Define as token for inline if inlining supported])])
+
dnl
dnl Use pfopen.c if available and pfopen() not in standard libraries
dnl Require libpcap
diff --git a/config.h.in b/config.h.in
index dfa7b360..70250609 100644
--- a/config.h.in
+++ b/config.h.in
@@ -3,9 +3,6 @@
/* Define to empty if the keyword does not work. */
#undef const
-/* Define as __inline if that's what the C compiler calls it. */
-#undef inline
-
/* Long story short: aclocal.m4 depends on autoconf 2.13
* implementation details wrt "const"; newer versions
* have different implementation details so for now we
@@ -47,6 +44,9 @@
/* needed on HP-UX */
#undef _HPUX_SOURCE
+/* Define as token for inline if inlining supported */
+#undef inline
+
/* define if your compiler has __attribute__ */
#undef HAVE___ATTRIBUTE__
diff --git a/configure b/configure
index 65d63935..fa26e5a1 100755
--- a/configure
+++ b/configure
@@ -1,9 +1,20 @@
#! /bin/sh
-# From configure.in Revision: 1.94
+# From configure.in Revision: 1.94.2.1
+#
+# Try compiling a sample of the type of code that appears in
+# gencode.c with "inline", "__inline__", and "__inline".
+#
+# Autoconf's AC_C_INLINE, at least in autoconf 2.13, isn't good enough,
+# as it just tests whether a function returning "int" can be inlined;
+# at least some versions of HP's C compiler can inline that, but can't
+# inline a function that returns a struct pointer.
+#
+
+
@@ -621,7 +632,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:625: checking host system type" >&5
+echo "configure:636: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -642,7 +653,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:646: checking target system type" >&5
+echo "configure:657: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -660,7 +671,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:664: checking build system type" >&5
+echo "configure:675: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -708,7 +719,7 @@ fi
# Extract the first word of "shlicc2", so it can be a program name with args.
set dummy shlicc2; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:712: checking for $ac_word" >&5
+echo "configure:723: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_SHLICC2'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -749,7 +760,7 @@ fi
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:753: checking for $ac_word" >&5
+echo "configure:764: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -779,7 +790,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:783: checking for $ac_word" >&5
+echo "configure:794: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -830,7 +841,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:834: checking for $ac_word" >&5
+echo "configure:845: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -862,7 +873,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:866: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:877: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -873,12 +884,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 877 "configure"
+#line 888 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -904,12 +915,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:908: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:919: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:913: checking whether we are using GNU C" >&5
+echo "configure:924: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -918,7 +929,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:922: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -937,7 +948,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:941: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:952: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -974,7 +985,7 @@ fi
V_CCOPT="-O2"
else
echo $ac_n "checking gcc version""... $ac_c" 1>&6
-echo "configure:978: checking gcc version" >&5
+echo "configure:989: checking gcc version" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_gcc_vers'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -992,19 +1003,19 @@ fi
fi
else
echo $ac_n "checking that $CC handles ansi prototypes""... $ac_c" 1>&6
-echo "configure:996: checking that $CC handles ansi prototypes" >&5
+echo "configure:1007: checking that $CC handles ansi prototypes" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_cc_ansi_prototypes'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1001 "configure"
+#line 1012 "configure"
#include "confdefs.h"
#include <sys/types.h>
int main() {
int frob(int, char *)
; return 0; }
EOF
-if { (eval echo configure:1008: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1019: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_cc_ansi_prototypes=yes
else
@@ -1022,21 +1033,21 @@ fi
hpux*)
echo $ac_n "checking for HP-UX ansi compiler ($CC -Aa -D_HPUX_SOURCE)""... $ac_c" 1>&6
-echo "configure:1026: checking for HP-UX ansi compiler ($CC -Aa -D_HPUX_SOURCE)" >&5
+echo "configure:1037: checking for HP-UX ansi compiler ($CC -Aa -D_HPUX_SOURCE)" >&5
savedcflags="$CFLAGS"
CFLAGS="-Aa -D_HPUX_SOURCE $CFLAGS"
if eval "test \"`echo '$''{'ac_cv_lbl_cc_hpux_cc_aa'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1033 "configure"
+#line 1044 "configure"
#include "confdefs.h"
#include <sys/types.h>
int main() {
int frob(int, char *)
; return 0; }
EOF
-if { (eval echo configure:1040: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1051: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_cc_hpux_cc_aa=yes
else
@@ -1080,12 +1091,12 @@ EOF
ultrix*)
echo $ac_n "checking that Ultrix $CC hacks const in prototypes""... $ac_c" 1>&6
-echo "configure:1084: checking that Ultrix $CC hacks const in prototypes" >&5
+echo "configure:1095: checking that Ultrix $CC hacks const in prototypes" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_cc_const_proto'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1089 "configure"
+#line 1100 "configure"
#include "confdefs.h"
#include <sys/types.h>
int main() {
@@ -1093,7 +1104,7 @@ struct a { int b; };
void c(const struct a *)
; return 0; }
EOF
-if { (eval echo configure:1097: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1108: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_cc_const_proto=yes
else
@@ -1117,54 +1128,70 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1121: checking for inline" >&5
-if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
+echo "configure:1132: checking for inline" >&5
+ if eval "test \"`echo '$''{'ac_cv_lbl_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- ac_cv_c_inline=no
-for ac_kw in inline __inline__ __inline; do
- cat > conftest.$ac_ext <<EOF
-#line 1128 "configure"
+
+ ac_cv_lbl_inline=""
+ ac_lbl_cc_inline=no
+ for i in inline __inline__ __inline
+ do
+ cat > conftest.$ac_ext <<EOF
+#line 1142 "configure"
#include "confdefs.h"
-
+#define inline $i
+ static inline struct iltest *foo(void);
int main() {
-} $ac_kw foo() {
+struct iltest {
+ int iltest1;
+ int iltest2;
+ };
+
+ static inline struct iltest *
+ foo()
+ {
+ struct iltest xxx;
+
+ return &xxx;
+ }
; return 0; }
EOF
-if { (eval echo configure:1135: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1161: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
- ac_cv_c_inline=$ac_kw; break
+ ac_lbl_cc_inline=yes
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest*
-done
-
+ if test $ac_lbl_cc_inline = yes ; then
+ break;
+ fi
+ done
+ if test $ac_lbl_cc_inline = yes ; then
+ ac_cv_lbl_inline=$i
+ fi
fi
-echo "$ac_t""$ac_cv_c_inline" 1>&6
-case "$ac_cv_c_inline" in
- inline | yes) ;;
- no) cat >> confdefs.h <<\EOF
-#define inline
-EOF
- ;;
- *) cat >> confdefs.h <<EOF
-#define inline $ac_cv_c_inline
+ if test ! -z $ac_cv_lbl_inline ; then
+ echo "$ac_t""$ac_cv_lbl_inline" 1>&6
+ else
+ echo "$ac_t""not supported" 1>&6
+ fi
+ cat >> confdefs.h <<EOF
+#define inline $ac_cv_lbl_inline
EOF
- ;;
-esac
echo $ac_n "checking for __attribute__""... $ac_c" 1>&6
-echo "configure:1162: checking for __attribute__" >&5
+echo "configure:1189: checking for __attribute__" >&5
if eval "test \"`echo '$''{'ac_cv___attribute__'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1168 "configure"
+#line 1195 "configure"
#include "confdefs.h"
#include <stdlib.h>
@@ -1181,7 +1208,7 @@ foo(void)
; return 0; }
EOF
-if { (eval echo configure:1185: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1212: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv___attribute__=yes
else
@@ -1203,12 +1230,12 @@ echo "$ac_t""$ac_cv___attribute__" 1>&6
echo $ac_n "checking for u_int8_t using $CC""... $ac_c" 1>&6
-echo "configure:1207: checking for u_int8_t using $CC" >&5
+echo "configure:1234: checking for u_int8_t using $CC" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_have_u_int8_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1212 "configure"
+#line 1239 "configure"
#include "confdefs.h"
# include "confdefs.h"
@@ -1221,7 +1248,7 @@ int main() {
u_int8_t i
; return 0; }
EOF
-if { (eval echo configure:1225: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1252: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_have_u_int8_t=yes
else
@@ -1241,12 +1268,12 @@ EOF
fi
echo $ac_n "checking for u_int16_t using $CC""... $ac_c" 1>&6
-echo "configure:1245: checking for u_int16_t using $CC" >&5
+echo "configure:1272: checking for u_int16_t using $CC" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_have_u_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1250 "configure"
+#line 1277 "configure"
#include "confdefs.h"
# include "confdefs.h"
@@ -1259,7 +1286,7 @@ int main() {
u_int16_t i
; return 0; }
EOF
-if { (eval echo configure:1263: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1290: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_have_u_int16_t=yes
else
@@ -1279,12 +1306,12 @@ EOF
fi
echo $ac_n "checking for u_int32_t using $CC""... $ac_c" 1>&6
-echo "configure:1283: checking for u_int32_t using $CC" >&5
+echo "configure:1310: checking for u_int32_t using $CC" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_have_u_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1288 "configure"
+#line 1315 "configure"
#include "confdefs.h"
# include "confdefs.h"
@@ -1297,7 +1324,7 @@ int main() {
u_int32_t i
; return 0; }
EOF
-if { (eval echo configure:1301: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1328: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_have_u_int32_t=yes
else
@@ -1318,7 +1345,7 @@ EOF
fi
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1322: checking how to run the C preprocessor" >&5
+echo "configure:1349: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -1333,13 +1360,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 1337 "configure"
+#line 1364 "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:1343: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1370: \"$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
:
@@ -1350,13 +1377,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 1354 "configure"
+#line 1381 "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:1360: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1387: \"$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
:
@@ -1367,13 +1394,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 1371 "configure"
+#line 1398 "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:1377: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1404: \"$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
:
@@ -1401,17 +1428,17 @@ for ac_hdr in sys/ioccom.h sys/sockio.h ifaddrs.h limits.h netinet/if_ether.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1405: checking for $ac_hdr" >&5
+echo "configure:1432: 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 1410 "configure"
+#line 1437 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1415: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1442: \"$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*
@@ -1440,12 +1467,12 @@ done
if test "$GCC" = yes ; then
echo $ac_n "checking for ANSI ioctl definitions""... $ac_c" 1>&6
-echo "configure:1444: checking for ANSI ioctl definitions" >&5
+echo "configure:1471: checking for ANSI ioctl definitions" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_gcc_fixincludes'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1449 "configure"
+#line 1476 "configure"
#include "confdefs.h"
/*
* This generates a "duplicate case value" when fixincludes
@@ -1464,7 +1491,7 @@ switch (0) {
}
; return 0; }
EOF
-if { (eval echo configure:1468: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1495: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_gcc_fixincludes=yes
else
@@ -1487,12 +1514,12 @@ fi
for ac_func in ether_hostton strerror strlcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1491: checking for $ac_func" >&5
+echo "configure:1518: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1496 "configure"
+#line 1523 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -1515,7 +1542,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:1519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -1541,7 +1568,7 @@ done
echo $ac_n "checking if --disable-protochain option is specified""... $ac_c" 1>&6
-echo "configure:1545: checking if --disable-protochain option is specified" >&5
+echo "configure:1572: checking if --disable-protochain option is specified" >&5
# Check whether --enable-protochain or --disable-protochain was given.
if test "${enable_protochain+set}" = set; then
enableval="$enable_protochain"
@@ -1572,7 +1599,7 @@ if test "${with_pcap+set}" = set; then
fi
echo $ac_n "checking packet capture type""... $ac_c" 1>&6
-echo "configure:1576: checking packet capture type" >&5
+echo "configure:1603: checking packet capture type" >&5
if test ! -z "$with_pcap" ; then
V_PCAP="$withval"
elif test -r /dev/bpf0 ; then
@@ -1603,7 +1630,7 @@ fi
echo "$ac_t""$V_PCAP" 1>&6
echo $ac_n "checking if --enable-ipv6 option is specified""... $ac_c" 1>&6
-echo "configure:1607: checking if --enable-ipv6 option is specified" >&5
+echo "configure:1634: checking if --enable-ipv6 option is specified" >&5
# Check whether --enable-ipv6 or --disable-ipv6 was given.
if test "${enable_ipv6+set}" = set; then
enableval="$enable_ipv6"
@@ -1619,7 +1646,7 @@ fi
echo "$ac_t""${enable_ipv6-no}" 1>&6
echo $ac_n "checking whether to build optimizer debugging code""... $ac_c" 1>&6
-echo "configure:1623: checking whether to build optimizer debugging code" >&5
+echo "configure:1650: checking whether to build optimizer debugging code" >&5
# Check whether --enable-optimizer-dbg or --disable-optimizer-dbg was given.
if test "${enable_optimizer_dbg+set}" = set; then
enableval="$enable_optimizer_dbg"
@@ -1635,7 +1662,7 @@ fi
echo "$ac_t""${enable_optimizer_dbg-no}" 1>&6
echo $ac_n "checking whether to build parser debugging code""... $ac_c" 1>&6
-echo "configure:1639: checking whether to build parser debugging code" >&5
+echo "configure:1666: checking whether to build parser debugging code" >&5
# Check whether --enable-yydebug or --disable-yydebug was given.
if test "${enable_yydebug+set}" = set; then
enableval="$enable_yydebug"
@@ -1657,17 +1684,17 @@ dlpi)
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1661: checking for $ac_hdr" >&5
+echo "configure:1688: 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 1666 "configure"
+#line 1693 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1671: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1698: \"$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*
@@ -1694,7 +1721,7 @@ fi
done
echo $ac_n "checking for /dev/dlpi device""... $ac_c" 1>&6
-echo "configure:1698: checking for /dev/dlpi device" >&5
+echo "configure:1725: checking for /dev/dlpi device" >&5
if test -c /dev/dlpi ; then
echo "$ac_t""yes" 1>&6
cat >> confdefs.h <<\EOF
@@ -1705,7 +1732,7 @@ EOF
echo "$ac_t""no" 1>&6
dir="/dev/dlpi"
echo $ac_n "checking for $dir directory""... $ac_c" 1>&6
-echo "configure:1709: checking for $dir directory" >&5
+echo "configure:1736: checking for $dir directory" >&5
if test -d $dir ; then
echo "$ac_t""yes" 1>&6
cat >> confdefs.h <<EOF
@@ -1720,7 +1747,7 @@ EOF
linux)
echo $ac_n "checking Linux kernel version""... $ac_c" 1>&6
-echo "configure:1724: checking Linux kernel version" >&5
+echo "configure:1751: checking Linux kernel version" >&5
if test "$cross_compiling" = yes; then
if eval "test \"`echo '$''{'ac_cv_linux_vers'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1745,12 +1772,12 @@ fi
{ echo "configure: error: version 2 or higher required; see the INSTALL doc for more info" 1>&2; exit 1; }
fi
echo $ac_n "checking if if_packet.h has tpacket_stats defined""... $ac_c" 1>&6
-echo "configure:1749: checking if if_packet.h has tpacket_stats defined" >&5
+echo "configure:1776: checking if if_packet.h has tpacket_stats defined" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_tpacket_stats'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1754 "configure"
+#line 1781 "configure"
#include "confdefs.h"
# include <linux/if_packet.h>
@@ -1758,7 +1785,7 @@ int main() {
struct tpacket_stats stats
; return 0; }
EOF
-if { (eval echo configure:1762: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1789: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_tpacket_stats=yes
else
@@ -1787,7 +1814,7 @@ null)
esac
echo $ac_n "checking whether we have /proc/net/dev""... $ac_c" 1>&6
-echo "configure:1791: checking whether we have /proc/net/dev" >&5
+echo "configure:1818: checking whether we have /proc/net/dev" >&5
if test -r /proc/net/dev ; then
ac_cv_lbl_proc_net_dev=yes
else
@@ -1821,7 +1848,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:1825: checking for $ac_word" >&5
+echo "configure:1852: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_V_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1855,7 +1882,7 @@ test -n "$V_LEX" || V_LEX="lex"
if test "$V_LEX" = flex ; then
# The -V flag was added in 2.4
echo $ac_n "checking for flex 2.4 or higher""... $ac_c" 1>&6
-echo "configure:1859: checking for flex 2.4 or higher" >&5
+echo "configure:1886: checking for flex 2.4 or higher" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_flex_v24'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1881,7 +1908,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:1885: checking for $ac_word" >&5
+echo "configure:1912: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_V_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1928,7 +1955,7 @@ if test "$V_LEX" = lex ; then
# Some versions of lex can't handle the definitions section of scanner.l .
# Try lexing it and complain if it can't deal.
echo $ac_n "checking for capable lex""... $ac_c" 1>&6
-echo "configure:1932: checking for capable lex" >&5
+echo "configure:1959: checking for capable lex" >&5
if eval "test \"`echo '$''{'tcpdump_cv_capable_lex'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1979,19 +2006,19 @@ EOF
sinix*)
echo $ac_n "checking if SINIX compiler defines sinix""... $ac_c" 1>&6
-echo "configure:1983: checking if SINIX compiler defines sinix" >&5
+echo "configure:2010: checking if SINIX compiler defines sinix" >&5
if eval "test \"`echo '$''{'ac_cv_cc_sinix_defined'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1988 "configure"
+#line 2015 "configure"
#include "confdefs.h"
int main() {
int i = sinix;
; return 0; }
EOF
-if { (eval echo configure:1995: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2022: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cc_sinix_defined=yes
else
@@ -2023,7 +2050,7 @@ esac
# 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:2027: checking for $ac_word" >&5
+echo "configure:2054: 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
@@ -2091,12 +2118,12 @@ EOF
fi
echo $ac_n "checking if sockaddr struct has sa_len member""... $ac_c" 1>&6
-echo "configure:2095: checking if sockaddr struct has sa_len member" >&5
+echo "configure:2122: checking if sockaddr struct has sa_len member" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_sockaddr_has_sa_len'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2100 "configure"
+#line 2127 "configure"
#include "confdefs.h"
# include <sys/types.h>
@@ -2105,7 +2132,7 @@ int main() {
u_int i = sizeof(((struct sockaddr *)0)->sa_len)
; return 0; }
EOF
-if { (eval echo configure:2109: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2136: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_sockaddr_has_sa_len=yes
else
@@ -2126,12 +2153,12 @@ EOF
fi
echo $ac_n "checking if dl_hp_ppa_info_t struct has dl_module_id_1 member""... $ac_c" 1>&6
-echo "configure:2130: checking if dl_hp_ppa_info_t struct has dl_module_id_1 member" >&5
+echo "configure:2157: checking if dl_hp_ppa_info_t struct has dl_module_id_1 member" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2135 "configure"
+#line 2162 "configure"
#include "confdefs.h"
# include <sys/types.h>
@@ -2141,7 +2168,7 @@ int main() {
u_int i = sizeof(((dl_hp_ppa_info_t *)0)->dl_module_id_1)
; return 0; }
EOF
-if { (eval echo configure:2145: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2172: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_lbl_dl_hp_ppa_info_t_has_dl_module_id_1=yes
else
@@ -2162,7 +2189,7 @@ EOF
fi
echo $ac_n "checking if unaligned accesses fail""... $ac_c" 1>&6
-echo "configure:2166: checking if unaligned accesses fail" >&5
+echo "configure:2193: checking if unaligned accesses fail" >&5
if eval "test \"`echo '$''{'ac_cv_lbl_unaligned_fail'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2247,7 +2274,7 @@ ln -s ${srcdir}/bpf/net net
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2251: checking for a BSD compatible install" >&5
+echo "configure:2278: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
diff --git a/configure.in b/configure.in
index 9fe70920..635c25ff 100644
--- a/configure.in
+++ b/configure.in
@@ -1,4 +1,4 @@
-dnl @(#) $Header: /tcpdump/master/libpcap/configure.in,v 1.94 2001-12-10 08:33:42 guy Exp $ (LBL)
+dnl @(#) $Header: /tcpdump/master/libpcap/configure.in,v 1.94.2.1 2002-06-28 10:36:26 guy Exp $ (LBL)
dnl
dnl Copyright (c) 1994, 1995, 1996, 1997
dnl The Regents of the University of California. All rights reserved.
@@ -6,13 +6,13 @@ dnl
dnl Process this file with autoconf to produce a configure script.
dnl
-AC_REVISION($Revision: 1.94 $)
+AC_REVISION($Revision: 1.94.2.1 $)
AC_INIT(pcap.c)
AC_CANONICAL_SYSTEM
AC_LBL_C_INIT(V_CCOPT, V_INCLS)
-AC_C_INLINE
+AC_LBL_C_INLINE
AC_C___ATTRIBUTE__
AC_LBL_CHECK_TYPE(u_int8_t, u_char)