From 84e10969f435f2a3d93709f3a97308091ef5551e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tim-Philipp=20M=C3=BCller?= Date: Fri, 4 Nov 2011 00:03:05 +0000 Subject: [PATCH] configure: suppress unused variable warnings if gst debugging is disabled https://bugzilla.gnome.org/show_bug.cgi?id=662952 --- configure.ac | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 3470234b80..76900def91 100644 --- a/configure.ac +++ b/configure.ac @@ -637,8 +637,14 @@ dnl FIXME: add LIBXML_PKG here if we use it GST_PKG_DEPS="glib-2.0, gobject-2.0, gmodule-no-export-2.0, gthread-2.0" AC_SUBST(GST_PKG_DEPS) +dnl make sure it doesn't complain about unused variables if debugging is disabled +NO_WARNINGS="" +if test "x${GST_DISABLE_GST_DEBUG}" = "xyes"; then + NO_WARNINGS="-Wno-unused" +fi + dnl define an ERROR_CFLAGS Makefile variable -AG_GST_SET_ERROR_CFLAGS($GST_GIT, [-Wmissing-declarations -Wmissing-prototypes -Wredundant-decls -Wundef -Wwrite-strings -Wformat-nonliteral -Wformat-security -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Waggregate-return -Wno-multichar -Wnested-externs]) +AG_GST_SET_ERROR_CFLAGS($GST_GIT, [-Wmissing-declarations -Wmissing-prototypes -Wredundant-decls -Wundef -Wwrite-strings -Wformat-nonliteral -Wformat-security -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Waggregate-return -Wno-multichar -Wnested-externs $NO_WARNINGS]) dnl define correct level for debugging messages AG_GST_SET_LEVEL_DEFAULT($GST_GIT)