aboutsummaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2008-05-05 22:47:32 +0000
committerGuy Harris <guy@alum.mit.edu>2008-05-05 22:47:32 +0000
commit31cae6e4ef358e39961d5620debf04c45311ae76 (patch)
treec41aaed36ad6a43e9b359d865983e833c5e3c6c5 /configure.in
parent773e6321d8a9b05e5031a212dc5123dbd6832acb (diff)
Require GLib 2.4 or later.
That means that G_GINT64_MODIFIER will be defined, so don't check whether it's defined. We don't use the PRI[douxX]64 macros, as we use the GLib print routines and thus use G_GINT64_MODIFIER instead. Get rid of the checks for whether inttypes.h defines PRI[douxX]64; just check whether it exists at all. That means we don't set INTTYPES_H_DEFINES_FORMATS, so don't check for it. svn path=/trunk/; revision=25243
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in106
1 files changed, 3 insertions, 103 deletions
diff --git a/configure.in b/configure.in
index 167affaa42..290830980c 100644
--- a/configure.in
+++ b/configure.in
@@ -584,14 +584,14 @@ if test "$GTK_OK" = "no" ; then
wireshark_bin=""
wireshark_man=""
# Honor GLIB_CFLAGS
- AM_PATH_GLIB_2_0(2.0.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib 2.0 or later distribution not found.), gmodule)
+ 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
- AM_PATH_GLIB_2_0(2.0.0, , AC_MSG_ERROR(GLib 2.0 or later distribution not found.), gmodule)
+ AM_PATH_GLIB_2_0(2.4.0, , AC_MSG_ERROR(GLib 2.4 or later distribution not found.), gmodule)
fi
#
@@ -630,66 +630,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)
@@ -1164,8 +1104,7 @@ 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)
@@ -1290,45 +1229,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>
- #include <glib/gprintf.h>
- #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="",