scripts: pre-submit: Run GCC's static analyzer

More information can be found in the gcc manual[1] or via the Red Hat
blog posts[2][3][4].

[1]: https://gcc.gnu.org/onlinedocs/gcc/Static-Analyzer-Options.html
[2]: https://developers.redhat.com/articles/2022/04/12/state-static-analysis-gcc-12-compiler
[3]: https://developers.redhat.com/articles/2023/05/31/improvements-static-analysis-gcc-13-compiler
[4]: https://developers.redhat.com/articles/2024/04/03/improvements-static-analysis-gcc-14-compiler

Change-Id: Iab174b209dd12a6b27ba43d4097850d0ad87b29a
Signed-off-by: Andrew Jeffery <andrew@codeconstruct.com.au>
diff --git a/scripts/pre-submit b/scripts/pre-submit
index 60034be..0c00ac5 100755
--- a/scripts/pre-submit
+++ b/scripts/pre-submit
@@ -10,7 +10,7 @@
 # Ensure the test suite passes in the default configuration. Note
 # that we don't specify -Dabi=... - the default is equivalent to
 # -Dabi=deprecated,stable,testing.
-meson setup -Dabi-compliance-check=disabled "$BUILD"
+CFLAGS=-fanalyzer meson setup -Dabi-compliance-check=disabled "$BUILD"
 meson compile -C "$BUILD"
 meson test -C "$BUILD"