Don't match -Wnon-virtual-dtor in the "flags are needed to suppress
warnings in headers". It should fall through to the "don't impose our
warnings on others" case. Do this by matching on "-Wno-*" instead of
"-Wno*".

Fixes #1737

PiperOrigin-RevId: 659548798
Change-Id: I49d7ba7ddcd7be30f946fca90ba9be467181e854
diff --git a/CMake/AbseilHelpers.cmake b/CMake/AbseilHelpers.cmake
index b177e59..3c4c92f 100644
--- a/CMake/AbseilHelpers.cmake
+++ b/CMake/AbseilHelpers.cmake
@@ -195,7 +195,7 @@
         # specified platform. Filter both of them out before the successor
         # reaches the "^-m" filter.
         set(skip_next_cflag ON)
-      elseif(${cflag} MATCHES "^(-Wno|/wd)")
+      elseif(${cflag} MATCHES "^(-Wno-|/wd)")
         # These flags are needed to suppress warnings that might fire in our headers.
         set(PC_CFLAGS "${PC_CFLAGS} ${cflag}")
       elseif(${cflag} MATCHES "^(-W|/w[1234eo])")