Remove iconv/libiconv checks from *NIX builds: GLIB-2 provides iconv replacements.
[obnox/wireshark/wip.git] / configure.in
index 74dd3be545b5ec623a816abe7dba1425ea860a0a..245e1560b2ea9c06aadcb64957b2332136aa61c9 100644 (file)
@@ -1,7 +1,5 @@
 # $Id$
 #
-AC_INIT(cfile.h)
-
 AC_PREREQ(2.52)
 
 dnl Check for CPU / vendor / OS
@@ -12,9 +10,10 @@ dnl macros.
 
 dnl AC_CANONICAL_HOST
 dnl AC_CANONICAL_BUILD
-AC_CANONICAL_TARGET
+dnl AC_CANONICAL_TARGET
 
-AM_INIT_AUTOMAKE(wireshark, 0.99.8)
+AC_INIT(wireshark, 1.0.99)
+AM_INIT_AUTOMAKE([1.9 tar-ustar])
 
 AM_DISABLE_STATIC
 
@@ -25,9 +24,19 @@ dnl Work around libtool bug (fixed in the version 1.5a?)
 AC_DEFUN([AC_PROVIDE_AC_LIBTOOL_DLOPEN], )
 AC_LIBTOOL_DLOPEN
 AC_PROG_LIBTOOL
+AC_PATH_PROG(PERL, perl)
 AC_PROG_YACC
+AC_PATH_PROG(YACCDUMMY, $YACC)
+if test "x$YACCDUMMY" = x
+then
+       AC_MSG_ERROR(I couldn't find yacc (or bison or ...); make sure it's installed and in your path)
+fi
 AM_PROG_LEX
-AC_PATH_PROG(PERL, perl)
+AC_PATH_PROG(LEXDUMMY, $LEX)
+if test "x$LEXDUMMY" = x
+then
+       AC_MSG_ERROR(I couldn't find (f)lex; make sure it's installed and in your path)
+fi
 AC_PATH_PROG(POD2MAN, pod2man)
 if test "x$POD2MAN" = x
 then
@@ -44,9 +53,29 @@ then
        #
        AC_MSG_ERROR(I couldn't find pod2html; make sure it's installed and in your path)
 fi
+
+#
+# XXX - this looks for various HTML viewers on the host, not the target;
+# we really want to know what's available on the target, for cross-builds.
+# That would probably require us to, at run time, look for xdg-open and,
+# if we don't find it, look for mozilla, htmlview, etc.
+#
 AC_PATH_PROG(HTML_VIEWER, xdg-open)
-if test "x$HTML_VIEWER" = x
+if test "x$HTML_VIEWER" != x
 then
+       #
+       # XXX - the HTML_VIEWER shell variable is the full path of xdg-open.
+       # Define some variable to be that, so we just run that?
+       #
+       AC_DEFINE(HAVE_XDG_OPEN, 1, [Define if we have xdg-open])
+
+       #
+       # XXX - we have to define HTML_VIEWER for the prefs.c code that
+       # sets the default value of the Web browser preference, even
+       # though that preference won't be offered.
+       #
+       AC_DEFINE_UNQUOTED(HTML_VIEWER, "xdg-open", [HTML viewer, e.g. mozilla])
+else
        AC_PATH_PROG(HTML_VIEWER, htmlview)
        if test "x$HTML_VIEWER" = x
        then
@@ -54,8 +83,6 @@ then
        else
                AC_DEFINE_UNQUOTED(HTML_VIEWER, "htmlview", [HTML viewer, e.g. mozilla])
        fi
-else
-       AC_DEFINE_UNQUOTED(HTML_VIEWER, "xdg-open", [HTML viewer, e.g. mozilla])
 fi
 
 AC_PATH_PROG(LEX, flex)
@@ -88,7 +115,7 @@ AC_ARG_WITH([gnutls],
                  [use gnutls library @<:@default=yes@:>@]),
   with_gnutls="$withval", with_gnutls="yes")
 if test "x$with_gnutls" = "xyes"; then
-  AM_PATH_LIBGNUTLS(1.0.0,
+  AM_PATH_LIBGNUTLS(1.2.0,
         [
                 echo "gnuTLS found, enabling ssl decryption"
                 AC_DEFINE(HAVE_LIBGNUTLS, 1, [Define to use gnutls library])
@@ -112,7 +139,7 @@ AC_ARG_WITH([gcrypt],
                  [use gcrypt library @<:@default=yes@:>@]),
   with_gcrypt="$withval", with_gcrypt="yes")
 if test "x$with_gcrypt" = "xyes"; then
-  AM_PATH_LIBGCRYPT(1.1.42,
+  AM_PATH_LIBGCRYPT(1.1.92,
         [
                 echo "libgcrypt found, enabling ipsec decryption"
                 AC_DEFINE(HAVE_LIBGCRYPT, 1, [Define to use libgcrypt])
@@ -131,15 +158,7 @@ fi
 
 # libsmi
 # FIXME: currently the path argument to with-libsmi is being ignored
-libsmi="no"
-AC_ARG_WITH([libsmi],
-  AC_HELP_STRING( [--with-libsmi=@<:@yes/no@:>@],
-                 [use smi library @<:@default=yes@:>@]),
-  with_libsmi="$withval", with_libsmi="yes")
-if test "x$with_libsmi" = "xyes"; then
-  AM_PATH_LIBSMI
-  AM_CONDITIONAL(HAVE_SMI, test "x$with_libsmi" = "xyes")
-fi
+AX_LIBSMI
 
 # Check for xsltproc
 AC_PATH_PROG(XSLTPROC, xsltproc)
@@ -164,6 +183,8 @@ AM_CONDITIONAL(HAVE_HHC, test x$HAVE_HHC = xyes)
 # Check for packaging utilities
 # For now, we check to see if the various packaging utilites are in our
 # path.  I'm too lazy to write code to go hunt for them.  -  Gerald
+
+# SVR4/Solaris
 AC_CHECK_PROG(HAVE_PKGPROTO, pkgproto, "yes", "no")
 AC_CHECK_PROG(HAVE_PKGMK, pkgmk, "yes", "no")
 AC_CHECK_PROG(HAVE_PKGTRANS, pkgtrans, "yes", "no")
@@ -176,9 +197,26 @@ else
 fi
 AC_SUBST(HAVE_SVR4_PACKAGING)
 
+# RPM
 AC_WIRESHARK_RPM_CHECK
 AC_SUBST(HAVE_RPM)
 
+# Debian
+AC_CHECK_PROG(HAVE_DPKG_BUILDPACKAGE, dpkg-buildpackage, "yes", "no")
+
+# Mac OS X
+AC_CHECK_PROG(HAVE_XCODEBUILD, xcodebuild, "yes", "no")
+AC_CHECK_PROG(HAVE_HDIUTIL, hdiutil, "yes", "no")
+AC_CHECK_PROG(HAVE_BLESS, bless, "yes", "no")
+
+if test x$HAVE_XCODEBUILD = xyes -a x$HAVE_HDIUTIL = xyes \
+     -a x$HAVE_BLESS = xyes ; then
+  HAVE_OSX_PACKAGING=yes
+else
+  HAVE_OSX_PACKAGING=no
+fi
+AC_SUBST(HAVE_OSX_PACKAGING)
+
 #
 # Try to add some additional gcc checks to CFLAGS
 #
@@ -190,9 +228,17 @@ AC_ARG_ENABLE(extra-gcc-checks,
        if test $enableval != no
        then
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-pedantic)
+               AC_WIRESHARK_GCC_CFLAGS_CHECK(-Woverflow)
+               AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wno-overlength-strings)
+#              AC_WIRESHARK_GCC_CFLAGS_CHECK(-fstrict-overflow -Wstrict-overflow=4)
+#              AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wunreachable-code)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wno-long-long)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wbad-function-cast)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wcast-qual)
+               #
+               # epan/dissectors/packet-ncp2222.inc blocks this one
+               # for now.
+               #
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wwrite-strings)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wshorten-64-to-32)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wstrict-prototypes)
@@ -200,14 +246,19 @@ AC_ARG_ENABLE(extra-gcc-checks,
                #Temporarily put cast-align here waiting eradication of 'cast
                #increases required alignment of target type' on the Solaris
                #slave.
-               AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wcast-align)
+               #
+               # epan/dissectors/packet-afs.c blocks this one for now.
+               #
+               AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wshadow)
        fi
 ],)
-AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wall -W)
+AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wall -W) # -W is now known as -Wextra
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wdeclaration-after-statement)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wendif-labels)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wpointer-arith)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wno-pointer-sign)
+AC_WIRESHARK_GCC_CFLAGS_CHECK(-Warray-bounds)
+AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wcast-align)
 
 #
 # If we're running gcc add '-D_U_="__attribute__((unused))"' to CFLAGS as well,
@@ -226,7 +277,7 @@ fi
 # This barrier is set for a very large part of the code. However, it is
 # typically not set for "generated" code  (lex, ans2wrs, idl2wrs, ...)
 #
-$warnings_as_errors_default="yes"
+warnings_as_errors_default="yes"
 AC_MSG_CHECKING(whether we should treat compiler warnings as errors)
 AC_ARG_ENABLE(warnings-as-errors,
   AC_HELP_STRING( [--enable-warnings-as-errors],
@@ -411,7 +462,7 @@ if test "x$ac_cv_enable_usr_local" = "xyes" ; then
        #
        # Arrange that we search for header files in the source directory
        # and in its "wiretap" subdirectory, as well as in "/usr/local/include",
-       # as various packages we use ("libpcap", "zlib", an SNMP library)
+       # as various packages we use ("libpcap", "zlib", "adns", "pcre")
        # may have been installed under "/usr/local/include".
        #
        CFLAGS="$CFLAGS -I/usr/local/include"
@@ -483,12 +534,6 @@ AC_ARG_ENABLE(wireshark,
                   [build GTK+-based wireshark.  @<:@default=yes, if GTK+ available@:>@]),
     enable_wireshark=$enableval,enable_wireshark=yes)
 
-AC_ARG_ENABLE(gtk2,
-  AC_HELP_STRING( [--disable-gtk2],
-                  [build Glib1/Gtk1+-based wireshark/tshark.  @<:@default=no@:>@]),
-    enable_gtk2=$enableval,enable_gtk2=yes)
-AM_CONDITIONAL(USE_GTK2, test x$enable_gtk2 = xyes)
-
 AC_ARG_ENABLE(threads,
   AC_HELP_STRING( [--enable-threads],
                   [use threads in wireshark.  @<:@default=no@:>@]),
@@ -525,16 +570,12 @@ datafiledir=`(
 )`
 AC_DEFINE_UNQUOTED(DATAFILE_DIR,"$datafiledir", [Directory for data])
 
-# GTK checks
+# GTK checks; we require GTK+ 2.4 or later.
 # We don't add $GLIB_LIBS to LIBS, because we don't want to force all
 # programs to be built with GTK+.
 #
-if test "x$enable_gtk2" = "xyes" -a "x$enable_wireshark" = "xyes"; then
-       GTK_OK=two
-       AM_PATH_GTK_2_0(2.0.0, CFLAGS="$CFLAGS $GTK_CFLAGS", GTK_OK=no, gthread)
-elif test "x$enable_gtk2" != "xyes" -a "x$enable_wireshark" = "xyes"; then
-       GTK_OK=one
-       AM_PATH_GTK(1.2.0, CFLAGS="$CFLAGS $GTK_CFLAGS", GTK_OK=no )
+if test "x$enable_wireshark" = "xyes"; then
+       AM_PATH_GTK_2_0(2.4.0, CFLAGS="$CFLAGS $GTK_CFLAGS", GTK_OK=no, gthread)
 else
        GTK_OK=no
 fi
@@ -558,26 +599,19 @@ if test "$GTK_OK" = "no" ; then
        # Wireshark unless they fix the GTK+ problem).
        #
        if test "x$enable_wireshark" = "xyes"; then
-               AC_MSG_ERROR([GTK+ isn't available, so Wireshark can't be compiled])
+               AC_MSG_ERROR([GTK+ 2.4 or later isn't available, so Wireshark can't be compiled])
        fi
        wireshark_bin=""
        wireshark_man=""
        # Honor GLIB_CFLAGS
-       if test "x$enable_gtk2" = "xyes" ; then
-               AM_PATH_GLIB_2_0(2.0.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib2 distribution not found.), gmodule)
-       else
-               AM_PATH_GLIB(1.2.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib distribution not found.), gmodule)
-       fi
+       AM_PATH_GLIB_2_0(2.4.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib 2.0 or later distribution not found.), gmodule)
+
 else
        wireshark_bin="wireshark\$(EXEEXT)"
        wireshark_man="wireshark.1"
         wireshark_SUBDIRS="codecs gtk"
        # Honor GLIB_CFLAGS
-       if test "$GTK_OK" = "two" ; then
-               AM_PATH_GLIB_2_0(2.0.0, , AC_MSG_ERROR(GLib distribution not found.), gmodule)
-       else
-               AM_PATH_GLIB(1.2.0, , AC_MSG_ERROR(GLib distribution not found.), gmodule)
-       fi
+       AM_PATH_GLIB_2_0(2.4.0, , AC_MSG_ERROR(GLib 2.4 or later distribution not found.), gmodule)
 fi
 
 #
@@ -616,66 +650,6 @@ else
   have_plugins=no
 fi
 
-#
-# We can't just check for <inttypes.h> - some systems have one that
-# doesn't define all the PRI[doxu]64 macros.
-#
-AC_CHECK_HEADERS(inttypes.h,
-  [
-    #
-    # OK, we have inttypes.h, but does it define those macros?
-    #
-    AC_MSG_CHECKING([[whether inttypes.h defines the PRI[doxu]64 macros]])
-    AC_COMPILE_IFELSE(
-      [
-       AC_LANG_SOURCE(
-         [[
-           #include <inttypes.h>
-           #include <glib.h>
-           #include <stdio.h>
-           #include <sys/types.h>
-
-           main()
-           {
-             printf("%" PRId64 "\n", (gint64)1);
-             printf("%" PRIo64 "\n", (guint64)1);
-             printf("%" PRIx64 "\n", (guint64)1);
-             printf("%" PRIX64 "\n", (guint64)1);
-             printf("%" PRIu64 "\n", (guint64)1);
-           }
-         ]])
-      ],
-      [
-       AC_MSG_RESULT(yes)
-       ac_wireshark_inttypes_h_defines_formats=yes
-      ],
-      [
-       AC_MSG_RESULT(no)
-       ac_wireshark_inttypes_h_defines_formats=no
-      ])
-  ],
-  [
-    #
-    # We don't have inttypes.h, so it obviously can't define those
-    # macros.
-    #
-    ac_wireshark_inttypes_h_defines_formats=no
-  ])
-if test "$ac_wireshark_inttypes_h_defines_formats" = yes; then
-  AC_DEFINE(INTTYPES_H_DEFINES_FORMATS,,[Define if <inttypes.h> defines PRI[doxu]64 macros])
-else
-  AC_WIRESHARK_CHECK_64BIT_FORMAT(ll,
-    [
-      AC_WIRESHARK_CHECK_64BIT_FORMAT(L,
-       [
-         AC_WIRESHARK_CHECK_64BIT_FORMAT(q,
-           [
-             AC_MSG_ERROR([neither %llx nor %Lx nor %qx worked on a 64-bit integer])
-           ])
-       ])
-    ])
-fi
-
 AC_SUBST(wireshark_bin)
 AC_SUBST(wireshark_man)
 
@@ -825,6 +799,7 @@ fi
 AC_SUBST(randpkt_bin)
 
 
+
 dnl Checks for "gethostbyname()" - and "-lnsl", if we need it to get
 dnl "gethostbyname()".
 AC_WIRESHARK_GETHOSTBY_LIB_CHECK
@@ -892,6 +867,60 @@ fi
 AC_SUBST(dumpcap_bin)
 AC_SUBST(dumpcap_man)
 
+# Enable/disable rawshark
+
+dnl rawshark check
+AC_MSG_CHECKING(whether to build rawshark)
+
+AC_ARG_ENABLE(rawshark,
+  AC_HELP_STRING( [--enable-rawshark],
+                  [build rawshark.  @<:@default=yes@:>@]),
+    rawshark=$enableval,enable_rawshark=yes)
+
+if test "x$enable_rawshark" = "xyes" ; then
+       if test "x$want_pcap" = "xno" ; then
+               enable_rawshark=no
+               AC_MSG_RESULT(pcap not available - disabling rawshark)
+       else
+               AC_MSG_RESULT(yes)
+       fi
+else
+       AC_MSG_RESULT(no)
+fi
+
+if test "x$enable_rawshark" = "xyes" ; then
+       rawshark_bin="rawshark\$(EXEEXT)"
+       rawshark_man="rawshark.1"
+else
+       rawshark_bin=""
+       rawshark_man=""
+fi
+AC_SUBST(rawshark_bin)
+AC_SUBST(rawshark_man)
+
+
+dnl pcap remote check
+AC_MSG_CHECKING(whether to use libpcap remote capturing feature)
+
+AC_ARG_WITH(pcap-remote,
+[  --with-pcap-remote        use libpcap remote capturing (requires libpcap)],
+[
+    if test $withval = no
+    then
+        want_pcap_remote=no
+    else
+        want_pcap_remote=yes
+    fi
+],[
+    want_pcap_remote=no
+])
+if test "x$want_pcap_remote" = "xno" -o "x$want_pcap" = "xno" ; then
+    AC_MSG_RESULT(no)
+else
+    AC_MSG_RESULT(yes)
+    AC_WIRESHARK_PCAP_REMOTE_CHECK
+fi
+
 dnl zlib check
 AC_MSG_CHECKING(whether to use zlib for reading compressed capture files)
 
@@ -1049,24 +1078,25 @@ else
 fi
 
 
-dnl Check if wireshark should be installed setuid
+dnl Check if dumpcap should be installed setuid
 AC_ARG_ENABLE(setuid-install,
   AC_HELP_STRING( [--enable-setuid-install],
-                  [install tshark and dumpcap as setuid @<:@default=no@:>@]),
+                  [install dumpcap as setuid @<:@default=no@:>@]),
     enable_setuid_install=$enableval,enable_setuid_install=no)
 
-AC_MSG_CHECKING(whether to install tshark and dumpcap setuid)
+AC_MSG_CHECKING(whether to install dumpcap setuid)
 if test "x$enable_setuid_install" = "xno" ; then
        AC_MSG_RESULT(no)
 else
        if test "x$enable_dumpcap" = "xno" ; then
-               AC_MSG_ERROR(Setuid install works only with --enable-dumpcap, but dumpcap disabled)
+               AC_MSG_ERROR(Setuid install works only with dumpcap but dumpcap is disabled)
        else
                AC_MSG_RESULT(yes)
        fi
 fi
 
 AM_CONDITIONAL(SETUID_INSTALL, test x$enable_setuid_install = xyes)
+AC_CHECK_FUNCS(setresuid setresgid)
 
 dnl libcap (not libpcap) check
 LIBCAP_LIBS=''
@@ -1094,15 +1124,11 @@ fi
 AC_SUBST(LIBCAP_LIBS)
 
 dnl Checks for header files.
-AC_HEADER_STDC
-AC_CHECK_HEADERS(direct.h dirent.h fcntl.h grp.h netdb.h pwd.h stdarg.h stddef.h unistd.h)
+AC_CHECK_HEADERS(direct.h dirent.h fcntl.h grp.h inttypes.h netdb.h pwd.h stdarg.h stddef.h unistd.h)
 AC_CHECK_HEADERS(sys/ioctl.h sys/param.h sys/socket.h sys/sockio.h sys/stat.h sys/time.h sys/types.h sys/utsname.h sys/wait.h)
 AC_CHECK_HEADERS(netinet/in.h)
 AC_CHECK_HEADERS(arpa/inet.h arpa/nameser.h)
 
-dnl iconv check
-AM_ICONV
-
 dnl SSL Check
 SSL_LIBS=''
 AC_MSG_CHECKING(whether to use SSL library)
@@ -1220,47 +1246,6 @@ AC_C_BIGENDIAN
 # XXX - do we need this?
 AC_PROG_GCC_TRADITIONAL
 
-#
-# Does GLib define G_GINT64_MODIFIER?
-#
-AC_MSG_CHECKING([[whether glib.h defines the G_GINT64_MODIFIER macro]])
-AC_COMPILE_IFELSE(
-  [
-    AC_LANG_SOURCE(
-      [[
-       #include <glib.h>
-       #if GTK_MAJOR_VERSION >= 2
-       #include <glib/gprintf.h>
-       #endif
-       #include <stdio.h>
-
-       main()
-       {
-         char strbuf[16+1];
-         g_snprintf(strbuf, sizeof strbuf, "%" G_GINT64_MODIFIER "x\n", (gint64)1);
-       }
-      ]])
-  ],
-  [
-    AC_MSG_RESULT(yes)
-  ],
-  [
-    AC_MSG_RESULT(no)
-    AC_WIRESHARK_CHECK_64BIT_FORMAT(l,
-      [
-      AC_WIRESHARK_CHECK_64BIT_FORMAT(ll,
-       [
-         AC_WIRESHARK_CHECK_64BIT_FORMAT(L,
-           [
-             AC_WIRESHARK_CHECK_64BIT_FORMAT(q,
-               [
-                 AC_MSG_ERROR([neither %lx nor %llx nor %Lx nor %qx worked on a 64-bit integer])
-               ])
-           ])
-       ])
-    ])
-  ])
-
 GETOPT_C=""
 GETOPT_O=""
 AC_CHECK_FUNC(getopt, GETOPT_O="",
@@ -1312,28 +1297,6 @@ fi
 AC_SUBST(MKSTEMP_C)
 AC_SUBST(MKSTEMP_O)
 
-ac_save_LIBS="$LIBS"
-LIBS="$GLIB_LIBS $LIBS"
-G_ASCII_STRTOULL_C=""
-G_ASCII_STRTOULL_O=""
-G_ASCII_STRTOULL_LO=""
-AC_CHECK_FUNC(g_ascii_strtoull,
-  [G_ASCII_STRTOULL_O=""
-   G_ASCII_STRTOULL_LO=""],
-  [G_ASCII_STRTOULL_O="g_ascii_strtoull.o"
-   G_ASCII_STRTOULL_LO="g_ascii_strtoull.lo"
-   AC_DEFINE(NEED_G_ASCII_STRTOULL_H, 1, [Define if g_ascii_strtoull.h needs to be included])
-])
-LIBS="$ac_save_LIBS"
-if test "$ac_cv_func_g_ascii_strtoull" = no ; then
-  G_ASCII_STRTOULL_C="g_ascii_strtoull.c"
-  G_ASCII_STRTOULL_O="g_ascii_strtoull.o"
-  G_ASCII_STRTOULL_LO="g_ascii_strtoull.lo"
-fi
-AC_SUBST(G_ASCII_STRTOULL_C)
-AC_SUBST(G_ASCII_STRTOULL_O)
-AC_SUBST(G_ASCII_STRTOULL_LO)
-
 AC_CHECK_FUNC(inet_aton,
   [INET_ATON_O=""
    INET_ATON_LO=""],
@@ -1450,9 +1413,8 @@ AC_ARG_WITH(plugins,
     have_plugins=no
   elif test "x$have_plugins" = "xno"; then
       AC_MSG_ERROR([GLib on this platform doesn't support loadable modules, so you can't enable plugins.])
-      if test "x$withval" != "xyes"; then
-       plugindir="$withval"
-      fi
+  elif test "x$withval" != "xyes"; then
+      plugindir="$withval"
   fi
 ])
 AM_CONDITIONAL(HAVE_PLUGINS, test "x$have_plugins" = "xyes")
@@ -1466,7 +1428,7 @@ CPPFLAGS="$CPPFLAGS '-DPLUGIN_DIR=\"\$(plugindir)\"'"
 #
 # The plugin dissectors reside in ./plugins/PROTO/
 #
-PLUGIN_LIBS="-L../../epan -lwireshark $GLIB_LIBS"
+PLUGIN_LIBS=""
 AC_SUBST(PLUGIN_LIBS)
 
 dnl libtool defs
@@ -1492,7 +1454,6 @@ dnl Save the cacheable configure results to config.cache before recursing
 AC_CACHE_SAVE
 
 AM_CONFIG_HEADER(config.h)
-AC_CONFIG_SUBDIRS(wiretap)
 AC_OUTPUT(
   Makefile
   doxygen.cfg
@@ -1534,6 +1495,7 @@ AC_OUTPUT(
   asn1/ns-cert-exts/Makefile
   asn1/ocsp/Makefile
   asn1/p7/Makefile
+  asn1/pcap/Makefile
   asn1/pkcs1/Makefile
   asn1/pkcs12/Makefile
   asn1/pkinit/Makefile
@@ -1554,6 +1516,7 @@ AC_OUTPUT(
   asn1/rrc/Makefile
   asn1/rrlp/Makefile
   asn1/rtse/Makefile
+  asn1/s1ap/Makefile
   asn1/s4406/Makefile
   asn1/sabp/Makefile
   asn1/smrse/Makefile
@@ -1564,6 +1527,7 @@ AC_OUTPUT(
   asn1/tcap/Makefile
   asn1/ulp/Makefile
   asn1/wlancertextn/Makefile
+  asn1/x2ap/Makefile
   asn1/x411/Makefile
   asn1/x420/Makefile
   asn1/x509af/Makefile
@@ -1584,6 +1548,8 @@ AC_OUTPUT(
   gtk/doxygen.cfg
   help/Makefile
   packaging/Makefile
+  packaging/macosx/Info.plist
+  packaging/macosx/Makefile
   packaging/nsis/Makefile
   packaging/rpm/Makefile
   packaging/rpm/SPECS/Makefile
@@ -1601,6 +1567,7 @@ AC_OUTPUT(
   plugins/ethercat/Makefile
   plugins/giop/Makefile
   plugins/gryphon/Makefile
+  plugins/infiniband/Makefile
   plugins/irda/Makefile
   plugins/lwres/Makefile
   plugins/m2m/Makefile
@@ -1613,6 +1580,7 @@ AC_OUTPUT(
   plugins/rtnet/Makefile
   plugins/rudp/Makefile
   plugins/sbus/Makefile
+  plugins/sercosiii/Makefile
   plugins/stats_tree/Makefile
   plugins/unistim/Makefile
   plugins/v5ua/Makefile
@@ -1621,6 +1589,8 @@ AC_OUTPUT(
   tools/Makefile
   tools/idl2wrs.sh
   tools/lemon/Makefile
+  wiretap/Makefile
+  wsutil/Makefile
   ,)
 dnl AC_CONFIG_FILES([tools/setuid-root.pl], [chmod +x tools/setuid-root.pl])
 
@@ -1693,24 +1663,22 @@ echo "                    Build text2pcap : $enable_text2pcap"
 echo "                      Build idl2wrs : $enable_idl2wrs"
 echo "                      Build randpkt : $enable_randpkt"
 echo "                       Build dftest : $enable_dftest"
+echo "                     Build rawshark : $enable_rawshark"
 echo ""
-echo "                     Install setuid : $setuid_message"
+echo "             Install dumpcap setuid : $setuid_message"
 echo "                        Use plugins : $have_plugins"
 echo "                   Build lua plugin : $lua_message"
 echo "                   Build rtp_player : $portaudio_message"
-echo "                Use GTK+ v2 library : $enable_gtk2"
-if test "x$enable_gtk2" = "xyes" ; then
 echo "                        Use threads : $enable_threads"
 echo "             Build profile binaries : $enable_profile_build"
-fi
 echo "                   Use pcap library : $want_pcap"
 echo "                   Use zlib library : $zlib_message"
 echo "                   Use pcre library : $pcre_message"
 echo "               Use kerberos library : $krb5_message"
 echo "               Use GNU ADNS library : $adns_message"
-echo "               Use SMI SNMP library : $libsmi"
+echo "                Use SMI MIB library : $libsmi_message"
 echo "             Use GNU crypto library : $gcrypt_message"
 echo "             Use SSL crypto library : $ssl_message"
 echo "           Use IPv6 name resolution : $enable_ipv6"
 echo "                 Use gnutls library : $tls_message"
-echo "                 Use libcap library : $libcap_message"
+echo "     Use POSIX capabilities library : $libcap_message"