diff options
| author | Mark Wielaard <[email protected]> | 2014-01-23 00:56:41 +0100 |
|---|---|---|
| committer | Mark Wielaard <[email protected]> | 2014-01-30 10:17:15 +0100 |
| commit | f48eb6b15fee66e54b488d71738979fc608f25ee (patch) | |
| tree | 22be2f2780909d8d61df125b29de5f3f60e52e97 /config | |
| parent | 13968d9aa9990d53999b14494ed55c2d68d4ead5 (diff) | |
Use -Wformat=2 by default for all files.
This just makes sure that all format strings are given as literals to
printf like functions so the compiler can see and check them. Remove
all no_Wformat, add -Wformat=2 unconditionally to AM_CFLAGS.
Signed-off-by: Mark Wielaard <[email protected]>
Diffstat (limited to 'config')
| -rw-r--r-- | config/ChangeLog | 4 | ||||
| -rw-r--r-- | config/eu.am | 5 |
2 files changed, 6 insertions, 3 deletions
diff --git a/config/ChangeLog b/config/ChangeLog index 53fddec6..0fca489a 100644 --- a/config/ChangeLog +++ b/config/ChangeLog @@ -1,3 +1,7 @@ +2014-01-22 Mark Wielaard <[email protected]> + + * eu.am (AM_CFLAGS): Unconditionally add -Wformat=2. + 2014-01-03 Mark Wielaard <[email protected]> * elfutils.spec.in: Update for 0.158. diff --git a/config/eu.am b/config/eu.am index 38718c7f..d2b4e795 100644 --- a/config/eu.am +++ b/config/eu.am @@ -1,6 +1,6 @@ ## Common automake fragments for elfutils subdirectory makefiles. ## -## Copyright (C) 2010 Red Hat, Inc. +## Copyright (C) 2010, 2014 Red Hat, Inc. ## ## This file is part of elfutils. ## @@ -31,10 +31,9 @@ DEFS = -D_GNU_SOURCE -DHAVE_CONFIG_H -DLOCALEDIR='"${localedir}"' AM_CPPFLAGS = -I. -I$(srcdir) -I$(top_srcdir)/lib -I.. -AM_CFLAGS = -std=gnu99 -Wall -Wshadow \ +AM_CFLAGS = -std=gnu99 -Wall -Wshadow -Wformat=2 \ $(if $($(*F)_no_Werror),,-Werror) \ $(if $($(*F)_no_Wunused),,-Wunused -Wextra) \ - $(if $($(*F)_no_Wformat),-Wno-format,-Wformat=2) \ $($(*F)_CFLAGS) if MUDFLAP |
