Commit ac41a6206fe9e1506010cd0aa9cf56ed3b37ae19
1 parent
7ccfb2eb
Enable gcc flag -Wwrite-strings
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5207 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
2 changed files
with
4 additions
and
2 deletions
Makefile.target
| ... | ... | @@ -73,7 +73,8 @@ endif |
| 73 | 73 | PROGS=$(QEMU_PROG) |
| 74 | 74 | |
| 75 | 75 | # We require -O2 to avoid the stack setup prologue in EXIT_TB |
| 76 | -OP_CFLAGS := -Wall -Wundef -Wendif-labels -O2 -g -fno-strict-aliasing | |
| 76 | +OP_CFLAGS := -O2 -g -fno-strict-aliasing | |
| 77 | +OP_CFLAGS += -Wall -Wundef -Wendif-labels -Wwrite-strings | |
| 77 | 78 | |
| 78 | 79 | # cc-option |
| 79 | 80 | # Usage: OP_CFLAGS+=$(call cc-option, -falign-functions=0, -malign-functions=0) | ... | ... |
configure
| ... | ... | @@ -346,7 +346,8 @@ for opt do |
| 346 | 346 | done |
| 347 | 347 | |
| 348 | 348 | # default flags for all hosts |
| 349 | -CFLAGS="$CFLAGS -Wall -Wundef -Wendif-labels -O2 -g -fno-strict-aliasing" | |
| 349 | +CFLAGS="$CFLAGS -O2 -g -fno-strict-aliasing" | |
| 350 | +CFLAGS="$CFLAGS -Wall -Wundef -Wendif-labels -Wwrite-strings" | |
| 350 | 351 | LDFLAGS="$LDFLAGS -g" |
| 351 | 352 | if test "$werror" = "yes" ; then |
| 352 | 353 | CFLAGS="$CFLAGS -Werror" | ... | ... |