[telepathy-gabble/master] Link against GModule when plugins are enabled.
Will Thompson
will.thompson at collabora.co.uk
Fri Nov 27 08:31:34 PST 2009
---
configure.ac | 23 ++++++++++++++---------
src/Makefile.am | 4 ++--
2 files changed, 16 insertions(+), 11 deletions(-)
diff --git a/configure.ac b/configure.ac
index 8aeaf11..d55a598 100644
--- a/configure.ac
+++ b/configure.ac
@@ -111,6 +111,15 @@ AC_SUBST(HANDLE_LEAK_DEBUG_CFLAGS)
AC_SUBST([ENABLE_CODING_STYLE_CHECKS])
+dnl Check for Glib
+PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.16, gobject-2.0 >= 2.16, gthread-2.0 >= 2.16])
+
+AC_SUBST(GLIB_CFLAGS)
+AC_SUBST(GLIB_LIBS)
+
+GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
+AC_SUBST(GLIB_GENMARSHAL)
+
AC_ARG_ENABLE(plugins,
AC_HELP_STRING([--enable-plugins],
[enable experimental plugin support]),
@@ -118,20 +127,16 @@ AC_ARG_ENABLE(plugins,
if test x$enable_plugins = xyes; then
AC_DEFINE(ENABLE_PLUGINS, [], [Enable plugins])
+ dnl If we want plugins, we need gmodule
+ PKG_CHECK_MODULES(GMODULE, [gmodule-2.0])
fi
+AC_SUBST(GMODULE_CFLAGS)
+AC_SUBST(GMODULE_LIBS)
+
AM_CONDITIONAL(ENABLE_PLUGINS, test x$enable_plugins = xyes)
AC_SUBST(ENABLE_PLUGINS)
-dnl Check for Glib
-PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.16, gobject-2.0 >= 2.16, gthread-2.0 >= 2.16])
-
-AC_SUBST(GLIB_CFLAGS)
-AC_SUBST(GLIB_LIBS)
-
-GLIB_GENMARSHAL=`$PKG_CONFIG --variable=glib_genmarshal glib-2.0`
-AC_SUBST(GLIB_GENMARSHAL)
-
dnl Check for D-Bus
# dbus-glib 0.78 fixed the bug #17329. It is needed for the contact
# capabilities interface.
diff --git a/src/Makefile.am b/src/Makefile.am
index d2b06e3..b886994 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -168,12 +168,12 @@ noinst_LTLIBRARIES = libgabble-convenience.la
AM_CFLAGS = $(ERROR_CFLAGS) -I$(top_srcdir) -I$(top_builddir) \
@DBUS_CFLAGS@ @GLIB_CFLAGS@ @WOCKY_CFLAGS@ \
@HANDLE_LEAK_DEBUG_CFLAGS@ @TP_GLIB_CFLAGS@ \
- @SOUP_CFLAGS@ @UUID_CFLAGS@ \
+ @SOUP_CFLAGS@ @UUID_CFLAGS@ @GMODULE_CFLAGS@ \
-I $(top_srcdir)/lib -I $(top_builddir)/lib \
-DG_LOG_DOMAIN=\"gabble\"
ALL_LIBS = @DBUS_LIBS@ @GLIB_LIBS@ @WOCKY_LIBS@ @TP_GLIB_LIBS@ \
- @SOUP_LIBS@ @UUID_LIBS@
+ @SOUP_LIBS@ @UUID_LIBS@ @GMODULE_LIBS@
# build gibber first
all: gibber
--
1.5.6.5
More information about the telepathy-commits
mailing list