b0acfdcfd35d7b963d81daf615253a5099f7fc38
[obnox/wireshark/wip.git] / wiretap / configure.in
1 # $Id: configure.in,v 1.6 1999/01/13 04:14:29 gerald Exp $
2 dnl Process this file with autoconf to produce a configure script.
3 AC_INIT(wtap.c)
4 AM_INIT_AUTOMAKE(libwtap.a, 0.0.0)
5 AM_CONFIG_HEADER(config.h)
6
7 dnl Checks for programs.
8 AC_PROG_CC
9 AC_PROG_RANLIB
10
11 # If we're running gcc, add '-Wall' to CFLAGS.
12 AC_MSG_CHECKING(to see if we can add '-Wall' to CFLAGS)
13 if test x$GCC != x ; then
14   CFLAGS="-Wall $CFLAGS"
15   AC_MSG_RESULT(yes)
16 else
17   AC_MSG_RESULT(no)
18 fi
19
20 # GTK checks (copied from ethereal)
21 AM_PATH_GTK(1.0.0, CFLAGS="$CFLAGS $GTK_CFLAGS" LIBS="$LIBS $GTK_LIBS",
22                    AC_MSG_ERROR(GTK+ distribution not found.))
23
24 # Wiretap check (copied and modified from ethereal)
25 AC_MSG_CHECKING(whether to include wiretap library)
26 AC_ARG_WITH(wiretap,
27 [  --with-wiretap          Include wiretap library.
28   --without-wiretap       Don't include wiretap library (default)],
29         [ case "$withval" in
30                 yes)
31                         AC_MSG_RESULT(yes)
32                         LIBWIRETAP_A="libwiretap.a"
33                         ;;
34                 *)
35                         AC_MSG_RESULT(no)
36                         LIBWIRETAP_A=""
37                         ;;
38         esac ],
39         AC_MSG_RESULT(no)
40 )
41 AC_SUBST(LIBWIRETAP_A)
42
43 dnl Checks for header files
44 AC_HEADER_STDC
45 AC_CHECK_HEADERS(unistd.h)
46
47 AC_OUTPUT(Makefile)