diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | configure.in | 6 |
2 files changed, 11 insertions, 0 deletions
@@ -1,3 +1,8 @@ +Sun Nov 27 21:25:33 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com> + + * configure.in: added -fno-strict-overflow. it suppress annoying + -Wstrict-overflow warning. + Sun Nov 27 20:58:02 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com> * io.c (rb_write_error2): get rid of warning on linux. fwrite diff --git a/configure.in b/configure.in index a57cec93a1..b17c280735 100644 --- a/configure.in +++ b/configure.in @@ -496,7 +496,10 @@ if test "$GCC:${warnflags+set}:no" = yes::no; then warnflags= fi if test "$GCC" = yes; then + # -D_FORTIFY_SOURCE RUBY_TRY_CFLAGS(-D_FORTIFY_SOURCE=2, [RUBY_APPEND_OPTION(XCFLAGS, -D_FORTIFY_SOURCE=2)]) + + # -fstack-protector AS_CASE(["$target_os"], [mingw*], [ stack_protector=no @@ -508,6 +511,9 @@ if test "$GCC" = yes; then RUBY_APPEND_OPTION(XCFLAGS, -fstack-protector) RUBY_APPEND_OPTION(XLDFLAGS, -fstack-protector) fi + + # suppress annoying -Wstrict-overflow warnings + RUBY_TRY_CFLAGS(-fno-strict-overflow, [RUBY_APPEND_OPTION(XCFLAGS, -fno-strict-overflow)]) fi if test "$GCC" = ""; then |