From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:44928) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TsrmZ-0006ie-NR for qemu-devel@nongnu.org; Wed, 09 Jan 2013 04:17:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TsrmY-0003R4-J9 for qemu-devel@nongnu.org; Wed, 09 Jan 2013 04:17:11 -0500 Received: from mx1.redhat.com ([209.132.183.28]:27800) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TsrmY-0003Qw-91 for qemu-devel@nongnu.org; Wed, 09 Jan 2013 04:17:10 -0500 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r099H9MP028616 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 9 Jan 2013 04:17:09 -0500 From: Gerd Hoffmann Date: Wed, 9 Jan 2013 10:17:07 +0100 Message-Id: <1357723028-12929-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH 1/2] gcc: rename CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET to CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann Signed-off-by: Gerd Hoffmann --- configure | 6 +++--- coroutine-ucontext.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/configure b/configure index 4f050ea..9357035 100755 --- a/configure +++ b/configure @@ -3078,7 +3078,7 @@ int main(void) { } EOF if compile_prog "-Werror" "" ; then - pragma_disable_unused_but_set=yes + pragma_diagnostic_available=yes fi ######################################## @@ -3650,8 +3650,8 @@ if test "$linux_magic_h" = "yes" ; then echo "CONFIG_LINUX_MAGIC_H=y" >> $config_host_mak fi -if test "$pragma_disable_unused_but_set" = "yes" ; then - echo "CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET=y" >> $config_host_mak +if test "$pragma_diagnostic_available" = "yes" ; then + echo "CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE=y" >> $config_host_mak fi if test "$valgrind_h" = "yes" ; then diff --git a/coroutine-ucontext.c b/coroutine-ucontext.c index 2ed703a..a9c30e9 100644 --- a/coroutine-ucontext.c +++ b/coroutine-ucontext.c @@ -200,7 +200,7 @@ Coroutine *qemu_coroutine_new(void) } #ifdef CONFIG_VALGRIND_H -#ifdef CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET +#ifdef CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE /* Work around an unused variable in the valgrind.h macro... */ #pragma GCC diagnostic ignored "-Wunused-but-set-variable" #endif @@ -208,7 +208,7 @@ static inline void valgrind_stack_deregister(CoroutineUContext *co) { VALGRIND_STACK_DEREGISTER(co->valgrind_stack_id); } -#ifdef CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET +#ifdef CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE #pragma GCC diagnostic error "-Wunused-but-set-variable" #endif #endif -- 1.7.1