summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2013-04-11 14:36:33 -0400
committerColin Walters <walters@verbum.org>2013-04-12 18:22:59 -0400
commit00dd36e41f95a37f61a99be74cc172c05a288e86 (patch)
tree28c62a0f41e1d4bea331a8c3b1f03dfdb6dd6717
parent46b99351ed8e3c8690a3f346a1999d8f34c25111 (diff)
downloadpolkit-00dd36e41f95a37f61a99be74cc172c05a288e86.tar.gz
configure: Specify GLib min/max version
Mainly to avoid deprecation warnings about g_type_init(). https://bugs.freedesktop.org/show_bug.cgi?id=63440
-rw-r--r--configure.ac4
-rw-r--r--src/examples/cancel.c1
-rw-r--r--test/polkitbackend/test-polkitbackendjsauthority.c1
3 files changed, 6 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index a9c24c4..73a978e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -124,6 +124,10 @@ fi
PKG_CHECK_MODULES(GLIB, [gmodule-2.0 gio-2.0 >= 2.30.0])
AC_SUBST(GLIB_CFLAGS)
AC_SUBST(GLIB_LIBS)
+AC_DEFINE([GLIB_VERSION_MIN_REQUIRED], [GLIB_VERSION_2_30],
+ [Avoid warning spew about g_type_init() being deprecated])
+AC_DEFINE([GLIB_VERSION_MAX_ALLOWED], [G_ENCODE_VERSION(2,34)],
+ [Notify us when we'll need to transition away from g_type_init()])
PKG_CHECK_MODULES(LIBJS, [mozjs185])
AC_SUBST(LIBJS_CFLAGS)
diff --git a/src/examples/cancel.c b/src/examples/cancel.c
index 8de5cd3..7978ebe 100644
--- a/src/examples/cancel.c
+++ b/src/examples/cancel.c
@@ -32,6 +32,7 @@
* authentication dialog is removed.
*/
+#include "config.h"
#include <polkit/polkit.h>
static gboolean
diff --git a/test/polkitbackend/test-polkitbackendjsauthority.c b/test/polkitbackend/test-polkitbackendjsauthority.c
index c7160f3..cc7b15f 100644
--- a/test/polkitbackend/test-polkitbackendjsauthority.c
+++ b/test/polkitbackend/test-polkitbackendjsauthority.c
@@ -21,6 +21,7 @@
* David Zeuthen <davidz@redhat.com>
*/
+#include "config.h"
#include "glib.h"
#include <locale.h>