1 dnl Macros that test for specific features.
2 dnl This file is part of the Autoconf packaging for Wireshark.
3 dnl Copyright (C) 1998-2000 by Gerald Combs.
7 dnl This program is free software; you can redistribute it and/or modify
8 dnl it under the terms of the GNU General Public License as published by
9 dnl the Free Software Foundation; either version 2, or (at your option)
10 dnl any later version.
12 dnl This program is distributed in the hope that it will be useful,
13 dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
14 dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 dnl GNU General Public License for more details.
17 dnl You should have received a copy of the GNU General Public License
18 dnl along with this program; if not, write to the Free Software
19 dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
22 dnl As a special exception, the Free Software Foundation gives unlimited
23 dnl permission to copy, distribute and modify the configure scripts that
24 dnl are the output of Autoconf. You need not follow the terms of the GNU
25 dnl General Public License when using or distributing such scripts, even
26 dnl though portions of the text of Autoconf appear in them. The GNU
27 dnl General Public License (GPL) does govern all other use of the material
28 dnl that constitutes the Autoconf program.
30 dnl Certain portions of the Autoconf source text are designed to be copied
31 dnl (in certain cases, depending on the input) into the output of
32 dnl Autoconf. We call these the "data" portions. The rest of the Autoconf
33 dnl source text consists of comments plus executable code that decides which
34 dnl of the data portions to output in any given case. We call these
35 dnl comments and executable code the "non-data" portions. Autoconf never
36 dnl copies any of the non-data portions into its output.
38 dnl This special exception to the GPL applies to versions of Autoconf
39 dnl released by the Free Software Foundation. When you make and
40 dnl distribute a modified version of Autoconf, you may extend this special
41 dnl exception to the GPL to apply to your modified version as well, *unless*
42 dnl your modified version has the potential to copy into its output some
43 dnl of the text that was the non-data portion of the version that you started
44 dnl with. (In other words, unless your change moves or copies text from
45 dnl the non-data portions to the data portions.) If your modification has
46 dnl such potential, you must delete any notice of this special exception
47 dnl to the GPL from your modified version.
49 dnl Written by David MacKenzie, with help from
50 dnl Franc,ois Pinard, Karl Berry, Richard Pixley, Ian Lance Taylor,
51 dnl Roland McGrath, Noah Friedman, david d zuhn, and many others.
54 # AC_WIRESHARK_ADD_DASH_L
56 # Add to the variable specified as the first argument a "-L" flag for the
57 # directory specified as the second argument, and, on Solaris, add a
58 # "-R" flag for it as well.
60 # XXX - IRIX, and other OSes, may require some flag equivalent to
63 AC_DEFUN([AC_WIRESHARK_ADD_DASH_L],
74 # AC_WIRESHARK_STRUCT_SA_LEN
76 dnl AC_STRUCT_ST_BLKSIZE extracted from the file in question,
77 dnl "acspecific.m4" in GNU Autoconf 2.12, and turned into
78 dnl AC_WIRESHARK_STRUCT_SA_LEN, which checks if "struct sockaddr"
79 dnl has the 4.4BSD "sa_len" member, and defines HAVE_SA_LEN; that's
80 dnl what's in this file.
81 dnl Done by Guy Harris <guy@alum.mit.edu> on 1998-11-14.
83 dnl ### Checks for structure members
85 AC_DEFUN([AC_WIRESHARK_STRUCT_SA_LEN],
86 [AC_CACHE_CHECK([for sa_len in struct sockaddr], ac_cv_wireshark_struct_sa_len,
87 [AC_TRY_COMPILE([#include <sys/types.h>
88 #include <sys/socket.h>], [struct sockaddr s; s.sa_len;],
89 ac_cv_wireshark_struct_sa_len=yes, ac_cv_wireshark_struct_sa_len=no)])
90 if test $ac_cv_wireshark_struct_sa_len = yes; then
91 AC_DEFINE(HAVE_SA_LEN, 1, [Define if sa_len field exists in struct sockaddr])
97 # AC_WIRESHARK_IPV6_STACK
99 # By Jun-ichiro "itojun" Hagino, <itojun@iijlab.net>
101 AC_DEFUN([AC_WIRESHARK_IPV6_STACK],
106 AC_MSG_CHECKING([ipv6 stack type])
107 for i in v6d toshiba kame inria zeta linux linux-glibc solaris8; do
111 #include </usr/local/v6/include/sys/types.h>
115 [v6type=$i; v6lib=v6;
116 v6libdir=/usr/local/v6/lib;
117 CFLAGS="-I/usr/local/v6/include $CFLAGS"])
121 #include <sys/param.h>
122 #ifdef _TOSHIBA_INET6
125 [v6type=$i; v6lib=inet6;
126 v6libdir=/usr/local/v6/lib;
127 CFLAGS="-DINET6 $CFLAGS"])
131 #include <netinet/in.h>
135 [v6type=$i; v6lib=inet6;
136 v6libdir=/usr/local/v6/lib;
137 CFLAGS="-DINET6 $CFLAGS"])
141 #include <netinet/in.h>
142 #ifdef IPV6_INRIA_VERSION
145 [v6type=$i; CFLAGS="-DINET6 $CFLAGS"])
149 #include <sys/param.h>
150 #ifdef _ZETA_MINAMI_INET6
153 [v6type=$i; v6lib=inet6;
154 v6libdir=/usr/local/v6/lib;
155 CFLAGS="-DINET6 $CFLAGS"])
158 if test -d /usr/inet6; then
162 CFLAGS="-DINET6 $CFLAGS"
167 #include <features.h>
168 #if defined(__GLIBC__) && defined(__GLIBC_MINOR__)
169 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || __GLIBC__ > 2
173 [v6type=$i; v6lib=inet6; CFLAGS="-DINET6 $CFLAGS"])
176 if test "`uname -s`" = "SunOS" && test "`uname -r`" = "5.8"; then
179 [CFLAGS="-DINET6 -DSOLARIS8_INET6 $CFLAGS"]
183 if test "$v6type" != "unknown"; then
188 if test "$v6lib" != "none"; then
189 for dir in $v6libdir /usr/local/v6/lib /usr/local/lib; do
190 if test -d $dir -a -f $dir/lib$v6lib.a; then
191 LIBS="-L$dir $LIBS -l$v6lib"
199 AC_MSG_RESULT(["$v6type, $v6lib"])
203 # AC_WIRESHARK_GETHOSTBY_LIB_CHECK
205 # Checks whether we need "-lnsl" to get "gethostby*()", which we use
208 # Adapted from stuff in the AC_PATH_XTRA macro in "acspecific.m4" in
209 # GNU Autoconf 2.13; the comment came from there.
210 # Done by Guy Harris <guy@alum.mit.edu> on 2000-01-14.
212 AC_DEFUN([AC_WIRESHARK_GETHOSTBY_LIB_CHECK],
214 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
215 # to get the SysV transport functions.
216 # chad@anasazi.com says the Pyramid MIS-ES running DC/OSx (SVR4)
218 # The nsl library prevents programs from opening the X display
219 # on Irix 5.2, according to dickey@clark.net.
220 AC_CHECK_FUNC(gethostbyname, ,
221 AC_CHECK_LIB(nsl, gethostbyname, NSL_LIBS="-lnsl"))
226 # AC_WIRESHARK_SOCKET_LIB_CHECK
228 # Checks whether we need "-lsocket" to get "socket()", which is used
229 # by libpcap on some platforms - and, in effect, "gethostby*()" on
230 # most if not all platforms (so that it can use NIS or DNS or...
231 # to look up host names).
233 # Adapted from stuff in the AC_PATH_XTRA macro in "acspecific.m4" in
234 # GNU Autoconf 2.13; the comment came from there.
235 # Done by Guy Harris <guy@alum.mit.edu> on 2000-01-14.
237 # We use "connect" because that's what AC_PATH_XTRA did.
239 AC_DEFUN([AC_WIRESHARK_SOCKET_LIB_CHECK],
241 # lieder@skyler.mavd.honeywell.com says without -lsocket,
242 # socket/setsockopt and other routines are undefined under SCO ODT
243 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
244 # on later versions), says simon@lia.di.epfl.ch: it contains
245 # gethostby* variants that don't use the nameserver (or something).
246 # -lsocket must be given before -lnsl if both are needed.
247 # We assume that if connect needs -lnsl, so does gethostbyname.
248 AC_CHECK_FUNC(connect, ,
249 AC_CHECK_LIB(socket, connect, SOCKET_LIBS="-lsocket",
250 AC_MSG_ERROR(Function 'socket' not found.), $NSL_LIBS))
251 AC_SUBST(SOCKET_LIBS)
255 # AC_WIRESHARK_BREAKLOOP_TRY_LINK
257 AC_DEFUN([AC_WIRESHARK_PCAP_BREAKLOOP_TRY_LINK],
273 ws_breakloop_compiled=yes
276 ws_breakloop_compiled=no
283 # AC_WIRESHARK_PCAP_CHECK
285 AC_DEFUN([AC_WIRESHARK_PCAP_CHECK],
287 if test -z "$pcap_dir"
290 # XXX need to set a var AC_CHECK_HEADER(pcap.h,,)
293 # The user didn't specify a directory in which libpcap resides;
294 # we assume that the current library search path will work,
295 # but we may have to look for the header in a "pcap"
296 # subdirectory of "/usr/include" or "/usr/local/include",
297 # as some systems apparently put "pcap.h" in a "pcap"
298 # subdirectory, and we also check "$prefix/include" - and
299 # "$prefix/include/pcap", in case $prefix is set to
300 # "/usr/include" or "/usr/local/include".
302 # XXX - should we just add "$prefix/include" to the include
303 # search path and "$prefix/lib" to the library search path?
305 AC_MSG_CHECKING(for extraneous pcap header directories)
307 pcap_dir_list="/usr/include/pcap $prefix/include/pcap $prefix/include"
308 if test "x$ac_cv_enable_usr_local" = "xyes" ; then
309 pcap_dir_list="$pcap_dir_list /usr/local/include/pcap"
311 for pcap_dir in $pcap_dir_list
313 if test -d $pcap_dir ; then
314 if test x$pcap_dir != x/usr/include -a x$pcap_dir != x/usr/local/include ; then
315 CFLAGS="$CFLAGS -I$pcap_dir"
316 CPPFLAGS="$CPPFLAGS -I$pcap_dir"
318 found_pcap_dir=" $found_pcap_dir -I$pcap_dir"
323 if test "$found_pcap_dir" != "" ; then
324 AC_MSG_RESULT(found --$found_pcap_dir added to CFLAGS)
326 AC_MSG_RESULT(not found)
330 # The user specified a directory in which libpcap resides,
331 # so add the "include" subdirectory of that directory to
332 # the include file search path and the "lib" subdirectory
333 # of that directory to the library search path.
335 # XXX - if there's also a libpcap in a directory that's
336 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
337 # make us find the version in the specified directory,
338 # as the compiler and/or linker will search that other
339 # directory before it searches the specified directory.
341 CFLAGS="$CFLAGS -I$pcap_dir/include"
342 CPPFLAGS="$CPPFLAGS -I$pcap_dir/include"
343 AC_WIRESHARK_ADD_DASH_L(LDFLAGS, $pcap_dir/lib)
347 AC_CHECK_HEADER(pcap.h,,
348 AC_MSG_ERROR([[Header file pcap.h not found; if you installed libpcap
349 from source, did you also do \"make install-incl\", and if you installed a
350 binary package of libpcap, is there also a developer's package of libpcap,
351 and did you also install that package?]]))
354 # Check to see if we find "pcap_open_live" in "-lpcap".
355 # Also check for various additional libraries that libpcap might
358 AC_CHECK_LIB(pcap, pcap_open_live,
361 AC_DEFINE(HAVE_LIBPCAP, 1, [Define to use libpcap library])
363 ac_wireshark_extras_found=no
365 for extras in "-lcfg -lodm" "-lpfring"
367 AC_MSG_CHECKING([for pcap_open_live in -lpcap with $extras])
368 LIBS="-lpcap $extras"
370 # XXX - can't we use AC_CHECK_LIB here?
377 pcap_open_live(NULL, 0, 0, 0, NULL);
380 ac_wireshark_extras_found=yes
382 PCAP_LIBS="-lpcap $extras"
383 AC_DEFINE(HAVE_LIBPCAP, 1, [Define to use libpcap library])
388 if test x$ac_wireshark_extras_found = xyes
393 if test x$ac_wireshark_extras_found = xno
395 AC_MSG_ERROR([Can't link with library libpcap.])
398 ], $SOCKET_LIBS $NSL_LIBS)
402 # Check whether various variables and functions are defined by
406 AC_MSG_CHECKING(whether pcap_version is defined by libpcap)
407 LIBS="$PCAP_LIBS $SOCKET_LIBS $NSL_LIBS $LIBS"
411 extern char *pcap_version;
414 printf ("%s\n", pcap_version);
416 ac_cv_pcap_version_defined=yes,
417 ac_cv_pcap_version_defined=no,
418 [echo $ac_n "cross compiling; assumed OK... $ac_c"])
419 if test "$ac_cv_pcap_version_defined" = yes ; then
421 AC_DEFINE(HAVE_PCAP_VERSION, 1, [Define if libpcap version is known])
425 AC_CHECK_FUNCS(pcap_open_dead pcap_freecode)
427 # pcap_breakloop may be present in the library but not declared
428 # in the pcap.h header file. If it's not declared in the header
429 # file, attempts to use it will get warnings, and, if we're
430 # building with warnings treated as errors, that warning will
431 # cause compilation to fail.
433 # We are therefore first testing whether the function is present
434 # and then, if we're compiling with warnings as errors, testing
435 # whether it is usable. It is usable if it compiles without
436 # a -Wimplicit warning (the "compile with warnings as errors"
437 # option requires GCC). If it is not usable, we fail and tell
438 # the user that the pcap.h header needs to be updated.
440 # Ceteris paribus, this should only happen with Mac OS X 10.3[.x] which
441 # can have an up-to-date pcap library without the corresponding pcap
444 # However, it might also happen on some others OSes with some erroneous
445 # system manipulations where multiple versions of libcap might co-exist
446 # e.g. hand made symbolic link from libpcap.so -> libpcap.so.0.8 but
447 # having the pcap header version 0.7.
449 AC_MSG_CHECKING([whether pcap_breakloop is present])
450 ac_CFLAGS_saved="$CFLAGS"
451 AC_WIRESHARK_PCAP_BREAKLOOP_TRY_LINK
452 if test "x$ws_breakloop_compiled" = "xyes"; then
454 AC_DEFINE(HAVE_PCAP_BREAKLOOP, 1, [Define if pcap_breakloop is known])
455 if test "x$with_warnings_as_errors" = "xyes"; then
456 AC_MSG_CHECKING([whether pcap_breakloop is usable])
457 CFLAGS="$CFLAGS -Werror -Wimplicit"
458 AC_WIRESHARK_PCAP_BREAKLOOP_TRY_LINK
459 if test "x$ws_breakloop_compiled" = "xyes"; then
464 [Your pcap library is more recent than your pcap header.
465 As you are building with compiler warnings treated as errors, Wireshark
466 won't be able to use functions not declared in that header.
467 If you wish to build with compiler warnings treated as errors, You should
468 install a newer version of the header file.])
470 CFLAGS="$ac_CFLAGS_saved"
477 # Later versions of Mac OS X 10.3[.x] ship a pcap.h that
478 # doesn't define pcap_if_t but ship an 0.8[.x] libpcap,
479 # so the library has "pcap_findalldevs()", but pcap.h
480 # doesn't define "pcap_if_t" so you can't actually *use*
481 # "pcap_findalldevs()".
483 # That even appears to be true of systems shipped with
484 # 10.3.4, so it doesn't appear only to be a case of
485 # Software Update not updating header files.
487 # (You can work around this by installing the 0.8 header
490 AC_CACHE_CHECK([whether pcap_findalldevs is present and usable],
491 [ac_cv_func_pcap_findalldevs],
500 pcap_if_t *devpointer;
503 pcap_findalldevs(&devpointer, errbuf);
508 ac_cv_func_pcap_findalldevs=yes
511 ac_cv_func_pcap_findalldevs=no
515 # Don't check for other new routines that showed up after
516 # "pcap_findalldevs()" if we don't have a usable
517 # "pcap_findalldevs()", so we don't end up using them if the
518 # "pcap.h" is crufty and old and doesn't declare them.
520 if test $ac_cv_func_pcap_findalldevs = "yes" ; then
521 AC_DEFINE(HAVE_PCAP_FINDALLDEVS, 1,
522 [Define to 1 if you have the `pcap_findalldevs' function and a pcap.h that declares pcap_if_t.])
523 AC_CHECK_FUNCS(pcap_datalink_val_to_name pcap_datalink_name_to_val)
524 AC_CHECK_FUNCS(pcap_list_datalinks pcap_set_datalink pcap_lib_version)
525 AC_CHECK_FUNCS(pcap_get_selectable_fd pcap_free_datalinks)
530 AC_DEFUN([AC_WIRESHARK_PCAP_REMOTE_CHECK],
533 LIBS="$PCAP_LIBS $SOCKET_LIBS $NSL_LIBS $LIBS"
534 AC_DEFINE(HAVE_REMOTE, 1, [Define to 1 to enable remote
535 capturing feature in WinPcap library])
536 AC_CHECK_FUNCS(pcap_open pcap_findalldevs_ex pcap_createsrcstr)
537 if test $ac_cv_func_pcap_open = "yes" -a \
538 $ac_cv_func_pcap_findalldevs_ex = "yes" -a \
539 $ac_cv_func_pcap_createsrcstr = "yes" ; then
540 AC_DEFINE(HAVE_PCAP_REMOTE, 1,
541 [Define to 1 if you have WinPcap remote capturing support and prefer to use these new API features.])
543 AC_CHECK_FUNCS(pcap_setsampling)
548 # AC_WIRESHARK_ZLIB_CHECK
550 AC_DEFUN([AC_WIRESHARK_ZLIB_CHECK],
552 if test "x$zlib_dir" != "x"
555 # The user specified a directory in which zlib resides,
556 # so add the "include" subdirectory of that directory to
557 # the include file search path and the "lib" subdirectory
558 # of that directory to the library search path.
560 # XXX - if there's also a zlib in a directory that's
561 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
562 # make us find the version in the specified directory,
563 # as the compiler and/or linker will search that other
564 # directory before it searches the specified directory.
566 wireshark_save_CFLAGS="$CFLAGS"
567 CFLAGS="$CFLAGS -I$zlib_dir/include"
568 wireshark_save_CPPFLAGS="$CPPFLAGS"
569 CPPFLAGS="$CPPFLAGS -I$zlib_dir/include"
570 wireshark_save_LIBS="$LIBS"
571 AC_WIRESHARK_ADD_DASH_L(LIBS, $zlib_dir/lib)
575 # Make sure we have "zlib.h". If we don't, it means we probably
576 # don't have zlib, so don't use it.
578 AC_CHECK_HEADER(zlib.h,,
580 if test "x$zlib_dir" != "x"
583 # The user used "--with-zlib=" to specify a directory
584 # containing zlib, but we didn't find the header file
585 # there; that either means they didn't specify the
586 # right directory or are confused about whether zlib
587 # is, in fact, installed. Report the error and give up.
589 AC_MSG_ERROR([zlib header not found in directory specified in --with-zlib])
591 if test "x$want_zlib" = "xyes"
594 # The user tried to force us to use the library, but we
595 # couldn't find the header file; report an error.
597 AC_MSG_ERROR(Header file zlib.h not found.)
600 # We couldn't find the header file; don't use the
601 # library, as it's probably not present.
608 if test "x$want_zlib" != "xno"
611 # Well, we at least have the zlib header file.
613 # Check for "gzgets()" in zlib, because we need it, but
614 # some older versions of zlib don't have it. It appears
615 # from the zlib ChangeLog that any released version of zlib
616 # with "gzgets()" should have the other routines we
617 # depend on, such as "gzseek()", "gztell()", and "zError()".
619 # Another reason why we require "gzgets()" is that
620 # some versions of zlib that didn't have it, such
621 # as 1.0.8, had a bug in "gzseek()" that meant that it
622 # doesn't work correctly on uncompressed files; this
623 # means we cannot use version 1.0.8. (Unfortunately,
624 # that's the version that comes with recent X11 source,
625 # and many people who install XFree86 on their Slackware
626 # boxes don't realize that they should configure it to
627 # use the native zlib rather than building and installing
628 # the crappy old version that comes with XFree86.)
630 # I.e., we can't just avoid using "gzgets()", as
631 # versions of zlib without "gzgets()" are likely to have
632 # a broken "gzseek()".
634 AC_CHECK_LIB(z, gzgets,
636 if test "x$zlib_dir" != "x"
639 # Put the "-I" and "-L" flags for zlib at
640 # the beginning of CFLAGS, CPPFLAGS, and
644 AC_WIRESHARK_ADD_DASH_L(LIBS, $zlib_dir/lib)
645 LIBS="$LIBS -lz $wireshark_save_LIBS"
649 AC_DEFINE(HAVE_LIBZ, 1, [Define to use libz library])
651 if test "x$zlib_dir" != "x"
654 # Restore the versions of CFLAGS, CPPFLAGS,
655 # and LIBS before we added the "-with-zlib="
656 # directory, as we didn't actually find
657 # zlib there, or didn't find a zlib that
658 # contains gzgets there.
660 CFLAGS="$wireshark_save_CFLAGS"
661 CPPFLAGS="$wireshark_save_CPPFLAGS"
662 LIBS="$wireshark_save_LIBS"
668 if test "x$want_zlib" != "xno"
671 # Well, we at least have the zlib header file and a zlib
674 # Now check for "gzgets()" in zlib when linking with the
675 # linker flags for GTK+ applications; people often grab
676 # XFree86 source and build and install it on their systems,
677 # and they appear sometimes to misconfigure XFree86 so that,
678 # even on systems with zlib, it assumes there is no zlib,
679 # so the XFree86 build process builds and installs its
680 # own zlib in the X11 library directory.
682 # The XFree86 zlib is an older version that lacks
683 # "gzgets()", and that's the zlib with which Wireshark
684 # gets linked, so the build of Wireshark fails.
686 ac_save_CFLAGS="$CFLAGS"
688 CFLAGS="$CFLAGS $GTK_CFLAGS"
689 LIBS="$GTK_LIBS -lz $LIBS"
690 AC_MSG_CHECKING([for gzgets missing when linking with X11])
691 AC_TRY_LINK_FUNC(gzgets, AC_MSG_RESULT(no),
694 AC_MSG_ERROR(old zlib found when linking with X11 - get rid of old zlib.)
696 CFLAGS="$ac_save_CFLAGS"
702 # AC_WIRESHARK_LIBPCRE_CHECK
704 AC_DEFUN([AC_WIRESHARK_LIBPCRE_CHECK],
706 if test "x$pcre_dir" != "x"
709 # The user specified a directory in which libpcre resides,
710 # so add the "include" subdirectory of that directory to
711 # the include file search path and the "lib" subdirectory
712 # of that directory to the library search path.
714 # XXX - if there's also a libpcre in a directory that's
715 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
716 # make us find the version in the specified directory,
717 # as the compiler and/or linker will search that other
718 # directory before it searches the specified directory.
720 wireshark_save_CFLAGS="$CFLAGS"
721 CFLAGS="$CFLAGS -I$pcre_dir/include"
722 wireshark_save_CPPFLAGS="$CPPFLAGS"
723 CPPFLAGS="$CPPFLAGS -I$pcre_dir/include"
724 wireshark_save_LIBS="$LIBS"
726 wireshark_save_LDFLAGS="$LDFLAGS"
727 LDFLAGS="$LDFLAGS -L$pcre_dir/lib"
731 # Make sure we have "pcre.h". If we don't, it means we probably
732 # don't have libpcre, so don't use it.
734 AC_CHECK_HEADER(pcre.h,,
736 if test "x$pcre_dir" != "x"
739 # The user used "--with-pcre=" to specify a directory
740 # containing libpcre, but we didn't find the header file
741 # there; that either means they didn't specify the
742 # right directory or are confused about whether libpcre
743 # is, in fact, installed. Report the error and give up.
745 AC_MSG_ERROR([libpcre header not found in directory specified in --with-pcre])
747 if test "x$want_pcre" = "xyes"
750 # The user tried to force us to use the library, but we
751 # couldn't find the header file; report an error.
753 AC_MSG_ERROR(Header file pcre.h not found.)
756 # We couldn't find the header file; don't use the
757 # library, as it's probably not present.
764 if test "x$want_pcre" != "xno"
767 # Well, we at least have the pcre header file.
769 # We're only using standard functions from libpcre,
770 # so we don't need to perform extra checks.
772 AC_CHECK_LIB(pcre, pcre_compile,
774 if test "x$pcre_dir" != "x"
777 # Put the "-I" and "-L" flags for pcre at
778 # the beginning of CFLAGS, CPPFLAGS,
781 PCRE_LIBS="-L$pcre_dir/lib -lpcre $wireshark_save_LIBS"
785 AC_DEFINE(HAVE_LIBPCRE, 1, [Define to use libpcre library])
787 if test "x$pcre_dir" != "x"
790 # Restore the versions of CFLAGS, CPPFLAGS,
791 # LDFLAGS, and LIBS before we added the
792 # "--with-pcre=" directory, as we didn't
793 # actually find pcre there.
795 CFLAGS="$wireshark_save_CFLAGS"
796 CPPFLAGS="$wireshark_save_CPPFLAGS"
797 LDFLAGS="$wireshark_save_LDFLAGS"
798 LIBS="$wireshark_save_LIBS"
808 # AC_WIRESHARK_LIBLUA_CHECK
810 AC_DEFUN([AC_WIRESHARK_LIBLUA_CHECK],[
812 if test "x$lua_dir" != "x"
815 # The user specified a directory in which liblua resides,
816 # so add the "include" subdirectory of that directory to
817 # the include file search path and the "lib" subdirectory
818 # of that directory to the library search path.
820 # XXX - if there's also a liblua in a directory that's
821 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
822 # make us find the version in the specified directory,
823 # as the compiler and/or linker will search that other
824 # directory before it searches the specified directory.
826 wireshark_save_CFLAGS="$CFLAGS"
827 CFLAGS="$CFLAGS -I$lua_dir/include"
828 wireshark_save_CPPFLAGS="$CPPFLAGS"
829 CPPFLAGS="$CPPFLAGS -I$lua_dir/include"
830 wireshark_save_LIBS="$LIBS"
831 LIBS="$LIBS -L$lua_dir/lib -llua -lm"
832 wireshark_save_LDFLAGS="$LDFLAGS"
833 LDFLAGS="$LDFLAGS -L$lua_dir/lib"
836 # The user specified no directory in which liblua resides,
837 # so just add "-llua -lliblua" to the used libs.
839 wireshark_save_CFLAGS="$CFLAGS"
840 wireshark_save_CPPFLAGS="$CPPFLAGS"
841 wireshark_save_LDFLAGS="$LDFLAGS"
842 wireshark_save_LIBS="$LIBS"
843 LIBS="$LIBS -llua -lm"
847 # Make sure we have "lua.h", "lualib.h" and "lauxlib.h". If we don't, it means we probably
848 # don't have liblua, so don't use it.
850 AC_CHECK_HEADERS(lua.h lualib.h lauxlib.h,,
852 AC_CHECK_HEADERS(lua5.1/lua.h lua5.1/lualib.h lua5.1/lauxlib.h,
854 if test "x$lua_dir" != "x"
856 LUA_INCLUDES="-I$lua_dir/include/lua5.1"
858 # we found lua5.1/lua.h, but we don't know which include dir contains it
859 AC_MSG_ERROR(Header file lua.h was found as lua5.1/lua.h but we can't use it. Please set the PATH for the --with-lua configure parameter. \n probably it is /usr.)
864 if test "x$lua_dir" != "x"
867 # The user used "--with-lua=" to specify a directory
868 # containing liblua, but we didn't find the header file
869 # there; that either means they didn't specify the
870 # right directory or are confused about whether liblua
871 # is, in fact, installed. Report the error and give up.
873 AC_MSG_ERROR([liblua header not found in directory specified in --with-lua])
875 if test "x$want_lua" = "xyes"
878 # The user tried to force us to use the library, but we
879 # couldn't find the header file; report an error.
881 AC_MSG_ERROR(Header file lua.h not found.)
884 # We couldn't find the header file; don't use the
885 # library, as it's probably not present.
893 if test "x$want_lua" != "xno"
896 # Well, we at least have the lua header file.
898 # let's check if the libs are there
901 # At least on Suse 9.3 systems, liblualib needs linking
903 LIBS="$LIBS $LUA_LIBS -lm"
905 AC_CHECK_LIB(lua, lua_call,
907 if test "x$lua_dir" != "x"
910 # Put the "-I" and "-L" flags for lua at
911 # the beginning of CFLAGS, CPPFLAGS,
914 LUA_LIBS="-L$lua_dir/lib -llua -lm"
915 LUA_INCLUDES="-I$lua_dir/include"
922 # we got lua, now look for lualib
924 AC_CHECK_LIB(lualib, luaL_openlib,
929 LUA_LIBS="$LUA_LIBS -llualib"
932 # no lualib, in 5.1 there's only liblua
936 LIBS="$wireshark_save_LIBS $LUA_LIBS"
938 AC_CHECK_LIB(lua, luaL_register,
943 AC_DEFINE(HAVE_LUA_5_1, 1, [Define to use Lua 5.1])
948 if test "x$lua_dir" != "x"
951 # Restore the versions of CFLAGS, CPPFLAGS,
952 # LDFLAGS, and LIBS before we added the
953 # "--with-lua=" directory, as we didn't
954 # actually find lua there.
956 CFLAGS="$wireshark_save_CFLAGS"
957 CPPFLAGS="$wireshark_save_CPPFLAGS"
958 LDFLAGS="$wireshark_save_LDFLAGS"
959 LIBS="$wireshark_save_LIBS"
962 # User requested --with-lua but it isn't available
963 if test "x$want_lua" = "xyes"
965 AC_MSG_ERROR(Linking with liblualib failed.)
972 # We could not find the libs, maybe we have version number in the lib name
975 LIBS="$wireshark_save_LIBS -llua5.1 -lm"
977 AC_CHECK_LIB(lua5.1, luaL_register,
982 AC_DEFINE(HAVE_LUA_5_1, 1, [Define to use Lua 5.1])
983 LUA_LIBS=" -llua5.1 -lm"
986 # Restore the versions of CFLAGS, CPPFLAGS,
987 # LDFLAGS, and LIBS before we added the
988 # "--with-lua=" directory, as we didn't
989 # actually find lua there.
991 CFLAGS="$wireshark_save_CFLAGS"
992 CPPFLAGS="$wireshark_save_CPPFLAGS"
993 LDFLAGS="$wireshark_save_LDFLAGS"
994 LIBS="$wireshark_save_LIBS"
996 # User requested --with-lua but it isn't available
997 if test "x$want_lua" = "xyes"
999 AC_MSG_ERROR(Linking with liblua failed.)
1005 CFLAGS="$wireshark_save_CFLAGS"
1006 CPPFLAGS="$wireshark_save_CPPFLAGS"
1007 LDFLAGS="$wireshark_save_LDFLAGS"
1008 LIBS="$wireshark_save_LIBS"
1010 AC_SUBST(LUA_INCLUDES)
1016 # AC_WIRESHARK_LIBPORTAUDIO_CHECK
1018 AC_DEFUN([AC_WIRESHARK_LIBPORTAUDIO_CHECK],[
1020 if test "x$portaudio_dir" != "x"
1023 # The user specified a directory in which libportaudio
1024 # resides, so add the "include" subdirectory of that directory to
1025 # the include file search path and the "lib" subdirectory
1026 # of that directory to the library search path.
1028 # XXX - if there's also a libportaudio in a directory that's
1029 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
1030 # make us find the version in the specified directory,
1031 # as the compiler and/or linker will search that other
1032 # directory before it searches the specified directory.
1034 wireshark_save_CFLAGS="$CFLAGS"
1035 CFLAGS="$CFLAGS -I$portaudio_dir/include"
1036 wireshark_save_CPPFLAGS="$CPPFLAGS"
1037 CPPFLAGS="$CPPFLAGS -I$portaudio_dir/include"
1038 wireshark_save_LIBS="$LIBS"
1039 LIBS="$LIBS -L$portaudio_dir/lib -lportaudio"
1040 wireshark_save_LDFLAGS="$LDFLAGS"
1041 LDFLAGS="$LDFLAGS -L$portaudio_dir/lib"
1044 # The user specified no directory in which libportaudio resides,
1045 # so just add "-lportaudio" to the used libs.
1047 wireshark_save_CFLAGS="$CFLAGS"
1048 wireshark_save_CPPFLAGS="$CPPFLAGS"
1049 wireshark_save_LDFLAGS="$LDFLAGS"
1050 wireshark_save_LIBS="$LIBS"
1051 LIBS="$LIBS -lportaudio"
1055 # Make sure we have "portaudio.h". If we don't, it means we probably
1056 # don't have libportaudio, so don't use it.
1058 AC_CHECK_HEADERS(portaudio.h,,
1060 if test "x$portaudio_dir" != "x"
1063 # The user used "--with-portaudio=" to specify a directory
1064 # containing libportaudio, but we didn't find the header file
1065 # there; that either means they didn't specify the
1066 # right directory or are confused about whether libportaudio
1067 # is, in fact, installed. Report the error and give up.
1069 AC_MSG_ERROR([libportaudio header not found in directory specified in --with-portaudio])
1071 CFLAGS="$wireshark_save_CFLAGS"
1072 CPPFLAGS="$wireshark_save_CPPFLAGS"
1073 LDFLAGS="$wireshark_save_LDFLAGS"
1074 LIBS="$wireshark_save_LIBS"
1076 if test "x$want_portaudio" = "xyes"
1079 # The user tried to force us to use the library, but we
1080 # couldn't find the header file; report an error.
1082 AC_MSG_ERROR(Header file portaudio.h not found.)
1085 # We couldn't find the header file; don't use the
1086 # library, as it's probably not present.
1094 # Check whether we have the right version of portaudio
1096 if test "x$want_portaudio" != "xno"
1098 AC_CHECK_TYPE(PortAudioStream,
1099 AC_DEFINE(PORTAUDIO_API_1, 1, [Define if we are using version of of the Portaudio library API]),
1101 [#include <portaudio.h>])
1104 if test "x$want_portaudio" != "xno"
1107 # Well, we at least have the portaudio header file.
1109 # let's check if the libs are there
1112 AC_CHECK_LIB(portaudio, Pa_Initialize,
1114 if test "x$portaudio_dir" != "x"
1117 # Put the "-I" and "-L" flags for portaudio at
1118 # the beginning of CFLAGS, CPPFLAGS,
1119 # LDFLAGS, and LIBS.
1121 PORTAUDIO_LIBS="-L$portaudio_dir/lib -lportaudio"
1122 PORTAUDIO_INCLUDES="-I$portaudio_dir/include"
1124 PORTAUDIO_LIBS="-lportaudio"
1125 PORTAUDIO_INCLUDES=""
1127 AC_DEFINE(HAVE_LIBPORTAUDIO, 1, [Define to use libportaudio library])
1131 # Restore the versions of CFLAGS, CPPFLAGS,
1132 # LDFLAGS, and LIBS before we added the
1133 # "--with-portaudio=" directory, as we didn't
1134 # actually find portaudio there.
1136 CFLAGS="$wireshark_save_CFLAGS"
1137 CPPFLAGS="$wireshark_save_CPPFLAGS"
1138 LDFLAGS="$wireshark_save_LDFLAGS"
1139 LIBS="$wireshark_save_LIBS"
1141 # User requested --with-portaudio but it isn't available
1142 if test "x$want_portaudio" = "xyes"
1144 AC_MSG_ERROR(Linking with libportaudio failed.)
1149 CFLAGS="$wireshark_save_CFLAGS"
1150 CPPFLAGS="$wireshark_save_CPPFLAGS"
1151 LDFLAGS="$wireshark_save_LDFLAGS"
1152 LIBS="$wireshark_save_LIBS"
1153 AC_SUBST(PORTAUDIO_LIBS)
1154 AC_SUBST(PORTAUDIO_INCLUDES)
1160 # AC_WIRESHARK_RPM_CHECK
1161 # Looks for the rpm program, and checks to see if we can redefine "_topdir".
1163 AC_DEFUN([AC_WIRESHARK_RPM_CHECK],
1165 AC_CHECK_PROG(ac_cv_wireshark_have_rpm, rpm, "yes", "no")
1166 if test "x$ac_cv_wireshark_have_rpm" = "xyes"; then
1167 rpm --define '_topdir /tmp' > /dev/null 2>&1
1168 AC_MSG_CHECKING(to see if we can redefine _topdir)
1169 if test $? -eq 0 ; then
1173 AC_MSG_RESULT(no. You'll have to build packages manually.)
1180 # AC_WIRESHARK_GNU_SED_CHECK
1181 # Checks if GNU sed is the first sed in PATH.
1183 AC_DEFUN([AC_WIRESHARK_GNU_SED_CHECK],
1185 AC_MSG_CHECKING(for GNU sed as first sed in PATH)
1186 if ( sh -c "sed --version" </dev/null 2> /dev/null | grep "GNU sed" 2>&1 > /dev/null ) ; then
1196 # AC_WIRESHARK_C_ARES_CHECK
1198 AC_DEFUN([AC_WIRESHARK_C_ARES_CHECK],
1200 want_c_ares=defaultyes
1202 if test "x$want_c_ares" = "xdefaultyes"; then
1204 if test "x$ac_cv_enable_usr_local" = "xyes" ; then
1206 if test -d "$withval"; then
1207 AC_WIRESHARK_ADD_DASH_L(LDFLAGS, ${withval}/lib)
1212 if test "x$want_c_ares" = "xyes"; then
1213 AC_CHECK_LIB(cares, ares_init,
1216 AC_DEFINE(HAVE_C_ARES, 1, [Define to use c-ares library])
1217 have_good_c_ares=yes
1218 ],, $SOCKET_LIBS $NSL_LIBS
1221 AC_MSG_RESULT(not required)
1227 # AC_WIRESHARK_ADNS_CHECK
1229 AC_DEFUN([AC_WIRESHARK_ADNS_CHECK],
1231 want_adns=defaultyes
1233 if test "x$want_adns" = "xdefaultyes"; then
1235 if test "x$ac_cv_enable_usr_local" = "xyes" ; then
1237 if test -d "$withval"; then
1238 AC_WIRESHARK_ADD_DASH_L(LDFLAGS, ${withval}/lib)
1243 if test "x$want_adns" = "xyes"; then
1244 AC_CHECK_LIB(adns, adns_init,
1247 AC_DEFINE(HAVE_GNU_ADNS, 1, [Define to use GNU ADNS library])
1249 ],, $SOCKET_LIBS $NSL_LIBS
1252 AC_MSG_RESULT(not required)
1258 # AC_WIRESHARK_LIBCAP_CHECK
1260 AC_DEFUN([AC_WIRESHARK_LIBCAP_CHECK],
1262 want_libcap=defaultyes
1264 if test "x$want_libcap" = "xdefaultyes"; then
1266 if test "x$ac_cv_enable_usr_local" = "xyes" ; then
1268 if test -d "$withval"; then
1269 AC_WIRESHARK_ADD_DASH_L(LDFLAGS, ${withval}/lib)
1274 if test "x$want_libcap" = "xyes"; then
1275 AC_CHECK_LIB(cap, cap_set_flag,
1278 AC_DEFINE(HAVE_LIBCAP, 1, [Define to use the libcap library])
1279 have_good_libcap=yes
1283 AC_MSG_RESULT(not required)
1289 # AC_WIRESHARK_KRB5_CHECK
1291 AC_DEFUN([AC_WIRESHARK_KRB5_CHECK],
1293 wireshark_save_CFLAGS="$CFLAGS"
1294 wireshark_save_CPPFLAGS="$CPPFLAGS"
1295 if test "x$krb5_dir" != "x"
1298 # The user specified a directory in which kerberos resides,
1299 # so add the "include" subdirectory of that directory to
1300 # the include file search path and the "lib" subdirectory
1301 # of that directory to the library search path.
1303 # XXX - if there's also a kerberos in a directory that's
1304 # already in CFLAGS, CPPFLAGS, or LDFLAGS, this won't
1305 # make us find the version in the specified directory,
1306 # as the compiler and/or linker will search that other
1307 # directory before it searches the specified directory.
1309 CFLAGS="$CFLAGS -I$krb5_dir/include"
1310 CPPFLAGS="$CPPFLAGS -I$krb5_dir/include"
1311 ac_heimdal_version=`grep heimdal $krb5_dir/include/krb5.h | head -n 1 | sed 's/^.*heimdal.*$/HEIMDAL/'`
1312 ac_mit_version=`grep 'Massachusetts Institute of Technology' $krb5_dir/include/krb5.h | head -n 1 | sed 's/^.*Massachusetts Institute of Technology.*$/MIT/'`
1313 ac_krb5_version="$ac_heimdal_version$ac_mit_version"
1314 if test "x$ac_krb5_version" = "xHEIMDAL"
1315 KRB5_LIBS="-L$krb5_dir/lib -lkrb5 -lasn1 $SSL_LIBS -lroken -lcrypt"
1317 KRB5_LIBS="-L$krb5_dir/lib -lkrb5 -lk5crypto -lcom_err"
1319 if test "x$ac_krb5_version" = "xMIT"
1321 AC_DEFINE(HAVE_MIT_KERBEROS, 1, [Define to use MIT kerberos])
1324 AC_PATH_PROG(KRB5_CONFIG, krb5-config)
1325 if test -x "$KRB5_CONFIG"
1327 KRB5_FLAGS=`"$KRB5_CONFIG" --cflags`
1328 KRB5_LIBS=`"$KRB5_CONFIG" --libs`
1329 CFLAGS="$CFLAGS $KRB5_FLAGS"
1330 CPPFLAGS="$CPPFLAGS $KRB5_FLAGS"
1332 # If -lcrypto is in KRB5_FLAGS, we require it to build
1333 # with Heimdal/MIT. We don't want to built with it by
1334 # default, due to annoying license incompatibilities
1335 # between the OpenSSL license and the GPL, so:
1337 # if SSL_LIBS is set to a non-empty string, we
1338 # remove -lcrypto from KRB5_LIBS and replace
1341 # if SSL_LIBS is not set to a non-empty string
1342 # we fail with an appropriate error message.
1344 case "$KRB5_LIBS" in
1346 if test ! -z "$SSL_LIBS"
1348 KRB5_LIBS=`echo $KRB5_LIBS | sed 's/-lcrypto//'`
1349 KRB5_LIBS="$KRB5_LIBS $SSL_LIBS"
1351 AC_MSG_ERROR([Kerberos library requires -lcrypto but --with-ssl not specified])
1355 ac_krb5_version=`"$KRB5_CONFIG" --version | head -n 1 | sed -e 's/^.*heimdal.*$/HEIMDAL/' -e 's/^Kerberos .*$/MIT/'`
1360 # Make sure we have "krb5.h". If we don't, it means we probably
1361 # don't have kerberos, so don't use it.
1363 AC_CHECK_HEADER(krb5.h,,
1365 if test "x$krb5_dir" != "x"
1368 # The user used "--with-krb5=" to specify a directory
1369 # containing kerberos, but we didn't find the header file
1370 # there; that either means they didn't specify the
1371 # right directory or are confused about whether kerberos
1372 # is, in fact, installed. Report the error and give up.
1374 AC_MSG_ERROR([kerberos header not found in directory specified in --with-krb5])
1376 if test "x$want_krb5" = "xyes"
1379 # The user tried to force us to use the library, but we
1380 # couldn't find the header file; report an error.
1382 AC_MSG_ERROR(Header file krb5.h not found.)
1385 # We couldn't find the header file; don't use the
1386 # library, as it's probably not present.
1389 AC_MSG_RESULT(No Heimdal or MIT header found - disabling dissection for some kerberos data in packet decoding)
1394 if test "x$want_krb5" != "xno"
1397 # Well, we at least have the krb5 header file.
1398 # Check whether this is Heimdal or MIT.
1400 AC_MSG_CHECKING(whether the Kerberos library is Heimdal or MIT)
1401 if test "x$ac_krb5_version" = "xHEIMDAL" -o "x$ac_krb5_version" = "xMIT"
1405 # Check whether we have krb5_kt_resolve - and whether
1406 # we need to link with -lresolv when linking with
1407 # the Kerberos library.
1409 AC_MSG_RESULT($ac_krb5_version)
1410 wireshark_save_LIBS="$LIBS"
1411 found_krb5_kt_resolve=no
1412 for extras in "" "-lresolv"
1414 LIBS="$KRB5_LIBS $extras"
1415 if test -z "$extras"
1417 AC_MSG_CHECKING([whether $ac_krb5_version includes krb5_kt_resolve])
1419 AC_MSG_CHECKING([whether $ac_krb5_version includes krb5_kt_resolve (linking with $extras)])
1429 # We found "krb5_kt_resolve()", and required
1430 # the libraries in extras as well.
1434 AC_DEFINE(HAVE_KERBEROS, 1, [Define to use kerberos])
1435 if test "x$ac_krb5_version" = "xHEIMDAL"
1437 AC_DEFINE(HAVE_HEIMDAL_KERBEROS, 1, [Define to use heimdal kerberos])
1438 elif test "x$ac_krb5_version" = "xMIT"
1440 AC_DEFINE(HAVE_MIT_KERBEROS, 1, [Define to use MIT kerberos])
1442 found_krb5_kt_resolve=yes
1449 if test "$found_krb5_kt_resolve" = no
1452 # We didn't find "krb5_kt_resolve()" in the
1453 # Kerberos library, even when we tried linking
1454 # with -lresolv; we can't link with kerberos.
1456 if test "x$want_krb5" = "xyes"
1459 # The user tried to force us to use the library,
1460 # but we can't do so; report an error.
1462 AC_MSG_ERROR(Usable $ac_krb5_version not found)
1465 # Restore the versions of CFLAGS and CPPFLAGS
1466 # from before we added the flags for Kerberos.
1468 AC_MSG_RESULT(Usable $ac_krb5_version not found - disabling dissection for some kerberos data in packet decoding)
1469 CFLAGS="$wireshark_save_CFLAGS"
1470 CPPFLAGS="$wireshark_save_CPPFLAGS"
1476 # We can link with Kerberos; see whether krb5.h
1477 # defines KEYTYPE_ARCFOUR_56 (where "defines" means
1478 # "as a #define or as an enum member).
1480 AC_MSG_CHECKING([whether krb5.h defines KEYTYPE_ARCFOUR_56])
1490 printf("%u\n", KEYTYPE_ARCFOUR_56);
1496 AC_DEFINE(HAVE_KEYTYPE_ARCFOUR_56, 1, [Define if krb5.h defines KEYTYPE_ARCFOUR_56])
1502 LIBS="$wireshark_save_LIBS"
1505 # It's not Heimdal or MIT.
1508 if test "x$want_krb5" = "xyes"
1511 # The user tried to force us to use the library,
1512 # but we can't do so; report an error.
1514 AC_MSG_ERROR(Kerberos not found)
1517 # Restore the versions of CFLAGS and CPPFLAGS
1518 # from before we added the flags for Kerberos.
1520 AC_MSG_RESULT(Kerberos not found - disabling dissection for some kerberos data in packet decoding)
1521 CFLAGS="$wireshark_save_CFLAGS"
1522 CPPFLAGS="$wireshark_save_CPPFLAGS"
1529 # The user asked us not to use Kerberos, or they didn't
1530 # say whether they wanted us to use it but we found
1533 # Restore the versions of CFLAGS and CPPFLAGS
1534 # from before we added the flags for Kerberos.
1536 CFLAGS="$wireshark_save_CFLAGS"
1537 CPPFLAGS="$wireshark_save_CPPFLAGS"
1545 # AC_WIRESHARK_GCC_CFLAGS_CHECK
1547 # $1 : cflags to test
1549 # The macro first determines if the compiler is GCC. Then compile with the
1550 # defined cflags. The defined flags are added to CFLAGS only if the compilation
1553 AC_DEFUN([AC_WIRESHARK_GCC_CFLAGS_CHECK],
1555 AC_MSG_CHECKING(whether we can add $GCC_OPTION to CFLAGS)
1556 if test "x$GCC" != "x"; then
1557 CFLAGS_saved="$CFLAGS"
1558 CFLAGS="$CFLAGS $GCC_OPTION"
1568 CFLAGS="$CFLAGS_saved"
1576 # AC_WIRESHARK_IGE_MAC_INTEGRATION_CHECK
1578 # Checks for the presence of OS X integration functions in GTK+
1579 # http://developer.imendio.com/projects/gtk-macosx/integration
1581 AC_DEFUN([AC_WIRESHARK_IGE_MAC_INTEGRATION_CHECK],
1583 ac_save_CFLAGS="$CFLAGS"
1584 ac_save_LIBS="$LIBS"
1585 CFLAGS="$CFLAGS $GTK_CFLAGS"
1586 LIBS="$GTK_LIBS $LIBS"
1587 AC_CHECK_LIB(Gtk, ige_mac_menu_set_menu_bar,
1589 AC_DEFINE(HAVE_IGE_MAC_INTEGRATION, 1,
1590 [Define to 1 if the GTK+ library inclues the Imendio IGE Mac OS X Integration library.])
1591 AC_CHECK_FUNCS(ige_mac_menu_install_key_handler)