forked from osmocom/wireshark
To check for GLib 2.14.0 or later, just check with pkg-config, don't use
AM_PATH_GLIB_2_0. We don't need all the mechanism of AM_PATH_GLIB_2_0 to check for pkg-config sanity etc., as we've already used AM_PATH_GLIB_2_0 and have thus already done that, and not doing it again 1) means we don't get a bunch of configure-script whining if we have GLib >= 2.4 and GLib < 2.14; 2) means we can get rid of stuff to compensate for AM_PATH_GLIB_2_0 failing with GLib < 2.14. svn path=/trunk/; revision=31912
This commit is contained in:
parent
ba7d64b1a6
commit
f919a5c1b4
48
configure.in
48
configure.in
|
@ -680,19 +680,6 @@ if test "$GTK_OK" = "no" ; then
|
||||||
wireshark_man=""
|
wireshark_man=""
|
||||||
# Use GLIB_CFLAGS
|
# Use GLIB_CFLAGS
|
||||||
AM_PATH_GLIB_2_0(2.4.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib 2.4 or later distribution not found.), gmodule)
|
AM_PATH_GLIB_2_0(2.4.0, CFLAGS="$CFLAGS $GLIB_CFLAGS", AC_MSG_ERROR(GLib 2.4 or later distribution not found.), gmodule)
|
||||||
#
|
|
||||||
# Check for GLib 2.14.0; if we have it, assume it comes with
|
|
||||||
# GRegex, otherwise assume we don't have GRegex.
|
|
||||||
# It's possible to compile GLib without GRegex but it doesn't look
|
|
||||||
# as if anyone does.
|
|
||||||
#
|
|
||||||
# If we *don't* have GLib 2.14.0, this will clear GLIB_LIBS,
|
|
||||||
# and if we do, it shouldn't change it; save the version we
|
|
||||||
# have before running this, and restore it afterwards.
|
|
||||||
#
|
|
||||||
save_GLIB_LIBS="$GLIB_LIBS"
|
|
||||||
AM_PATH_GLIB_2_0(2.14.0, have_gregex=yes, have_gregex=no, gmodule)
|
|
||||||
GLIB_LIBS="$save_GLIB_LIBS"
|
|
||||||
else
|
else
|
||||||
#
|
#
|
||||||
# We have GTK+, and thus will be building Wireshark unless the
|
# We have GTK+, and thus will be building Wireshark unless the
|
||||||
|
@ -703,19 +690,28 @@ else
|
||||||
wireshark_SUBDIRS="codecs gtk"
|
wireshark_SUBDIRS="codecs gtk"
|
||||||
# Don't use GLIB_CFLAGS
|
# Don't use GLIB_CFLAGS
|
||||||
AM_PATH_GLIB_2_0(2.4.0, , AC_MSG_ERROR(GLib 2.4 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
|
||||||
# Check for GLib 2.14.0; if we have it, assume it comes with
|
|
||||||
# GRegex, otherwise assume we don't have GRegex.
|
#
|
||||||
# It's possible to compile GLib without GRegex but it doesn't look
|
# Check whether GLib includes GRegex support.
|
||||||
# as if anyone does.
|
# We just assume that everybody builds GLib 2.14.0 and later
|
||||||
#
|
# with GRegex support; it's possible to compile GLib without
|
||||||
# If we *don't* have GLib 2.14.0, this will clear GLIB_LIBS,
|
# GRegex but it doesn't look as if anyone does.
|
||||||
# and if we do, it shouldn't change it; save the version we
|
#
|
||||||
# have before running this, and restore it afterwards.
|
AC_MSG_CHECKING(for GLIB - version >= 2.14.0)
|
||||||
#
|
if test x$PKG_CONFIG != xno ; then
|
||||||
save_GLIB_LIBS="$GLIB_LIBS"
|
## don't try to run the test against uninstalled libtool libs
|
||||||
AM_PATH_GLIB_2_0(2.14.0, have_gregex=yes, have_gregex=no, gmodule)
|
if $PKG_CONFIG --uninstalled $pkg_config_args; then
|
||||||
GLIB_LIBS="$save_GLIB_LIBS"
|
echo "Will use uninstalled version of GLib found in PKG_CONFIG_PATH"
|
||||||
|
enable_glibtest=no
|
||||||
|
fi
|
||||||
|
|
||||||
|
if $PKG_CONFIG --atleast-version 2.14.0 glib-2.0; then
|
||||||
|
have_gregex=yes
|
||||||
|
else
|
||||||
|
have_gregex=no
|
||||||
|
fi
|
||||||
|
AC_MSG_RESULT($have_gregex)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
|
|
Loading…
Reference in New Issue