gcc: rename CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET to CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
This commit is contained in:
parent
3dd46c7852
commit
cc6e3ca93c
6
configure
vendored
6
configure
vendored
@ -3078,7 +3078,7 @@ int main(void) {
|
|||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
if compile_prog "-Werror" "" ; then
|
if compile_prog "-Werror" "" ; then
|
||||||
pragma_disable_unused_but_set=yes
|
pragma_diagnostic_available=yes
|
||||||
fi
|
fi
|
||||||
|
|
||||||
########################################
|
########################################
|
||||||
@ -3648,8 +3648,8 @@ if test "$linux_magic_h" = "yes" ; then
|
|||||||
echo "CONFIG_LINUX_MAGIC_H=y" >> $config_host_mak
|
echo "CONFIG_LINUX_MAGIC_H=y" >> $config_host_mak
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$pragma_disable_unused_but_set" = "yes" ; then
|
if test "$pragma_diagnostic_available" = "yes" ; then
|
||||||
echo "CONFIG_PRAGMA_DISABLE_UNUSED_BUT_SET=y" >> $config_host_mak
|
echo "CONFIG_PRAGMA_DIAGNOSTIC_AVAILABLE=y" >> $config_host_mak
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test "$valgrind_h" = "yes" ; then
|
if test "$valgrind_h" = "yes" ; then
|
||||||
|
@ -200,7 +200,7 @@ Coroutine *qemu_coroutine_new(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_VALGRIND_H
|
#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... */
|
/* Work around an unused variable in the valgrind.h macro... */
|
||||||
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
|
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
|
||||||
#endif
|
#endif
|
||||||
@ -208,7 +208,7 @@ static inline void valgrind_stack_deregister(CoroutineUContext *co)
|
|||||||
{
|
{
|
||||||
VALGRIND_STACK_DEREGISTER(co->valgrind_stack_id);
|
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"
|
#pragma GCC diagnostic error "-Wunused-but-set-variable"
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user