diff --git a/configure b/configure
index 5bfd8e670a96af5d783a7f6d8ed36cafac7f97fb..539c5815bb7e88fdb6acd13d76967fcf8dd25f0c 100755
--- a/configure
+++ b/configure
@@ -3779,8 +3779,7 @@ EOF
 done
 
 check_cc <<EOF && enable pragma_deprecated
-_Pragma("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
-_Pragma("GCC diagnostic warning \"-Wdeprecated-declarations\"")
+void foo(void) { _Pragma("GCC diagnostic ignored \"-Wdeprecated-declarations\"") }
 EOF
 
 check_cc <<EOF && enable attribute_packed