diff options
author | Mike Waychison <mikew@google.com> | 2010-05-26 16:40:01 -0700 |
---|---|---|
committer | maximilian attems <max@stro.at> | 2010-07-07 14:06:26 +0200 |
commit | 23d04ca085b97f8075b0e2296e5488525c5f2da5 (patch) | |
tree | 4426eb11661dfaab0abe91c68675c433e6ceed6b | |
parent | 021a3d610276e41e7f95a7469bdc0ea6205162de (diff) | |
download | klibc-23d04ca085b97f8075b0e2296e5488525c5f2da5.tar.gz |
[klibc] CFLAGS: enable -fwrapv
Enable -fwrapv in klibc's build as there may be places that assume that signed
integers can overflow.
Signed-off-by: Mike Waychison <mikew@google.com>
[ I noticed no new warning on klibc build with gcc 4.4. ]
Signed-off-by: maximilian attems <max@stro.at>
-rw-r--r-- | scripts/Kbuild.klibc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/Kbuild.klibc b/scripts/Kbuild.klibc index 21e521f9e2487..79d196f2429ae 100644 --- a/scripts/Kbuild.klibc +++ b/scripts/Kbuild.klibc @@ -66,7 +66,8 @@ include $(srctree)/scripts/Kbuild.include # Defines used when compiling early userspace (klibc programs) # --------------------------------------------------------------------------- -KLIBCREQFLAGS := $(call cc-option, -fno-stack-protector, ) +KLIBCREQFLAGS := $(call cc-option, -fno-stack-protector, ) \ + $(call cc-option, -fwrapv, ) KLIBCARCHREQFLAGS := KLIBCOPTFLAGS := KLIBCWARNFLAGS := -W -Wall -Wno-sign-compare -Wno-unused-parameter |