summaryrefslogtreecommitdiffstats
path: root/config/gnu-warnings/error-general
diff options
context:
space:
mode:
authorDavid Young <dyoung@hdfgroup.org>2020-03-19 02:12:53 (GMT)
committerDavid Young <dyoung@hdfgroup.org>2020-03-19 02:12:53 (GMT)
commit2f09d8f3c8a4a44932c1b8ffb0f6ea2219059a5c (patch)
tree8692e294436d60a0e359730115bafeef8a7176c1 /config/gnu-warnings/error-general
parent0f32728f728f0670e49cb712acd8e7b34fa0bcc4 (diff)
downloadhdf5-2f09d8f3c8a4a44932c1b8ffb0f6ea2219059a5c.zip
hdf5-2f09d8f3c8a4a44932c1b8ffb0f6ea2219059a5c.tar.gz
hdf5-2f09d8f3c8a4a44932c1b8ffb0f6ea2219059a5c.tar.bz2
Move the GNU warnings configuration under config/gnu-warnings/ and trim
the filename prefixes. Update config/gnu-flags to suit. I also made changes to config/cmake/HDFCompilerFlags.cmake, but I'm not sure they're correct.
Diffstat (limited to 'config/gnu-warnings/error-general')
-rw-r--r--config/gnu-warnings/error-general24
1 files changed, 24 insertions, 0 deletions
diff --git a/config/gnu-warnings/error-general b/config/gnu-warnings/error-general
new file mode 100644
index 0000000..d0e272a
--- /dev/null
+++ b/config/gnu-warnings/error-general
@@ -0,0 +1,24 @@
+#
+# HDF5 code should not trigger the following warnings under any
+# circumstances, so ask the compiler to treat them as errors:
+#
+-Werror=bad-function-cast
+-Werror=cast-align
+-Werror=declaration-after-statement
+-Werror=format
+-Werror=implicit-function-declaration
+-Werror=missing-declarations
+-Werror=missing-prototypes
+-Werror=nested-externs
+-Werror=old-style-definition
+-Werror=packed
+-Werror=pointer-sign
+-Werror=pointer-to-int-cast
+-Werror=redundant-decls
+-Werror=strict-prototypes
+-Werror=switch
+-Werror=unused-but-set-variable
+-Werror=unused-function
+-Werror=unused-parameter
+-Werror=unused-variable
+#-Werror=discarded-qualifiers