[Kouhei Sutou]
> AC_CACHE_CHECK([how to compile Ruby extensions], [svn_cv_ruby_compile],[
> - svn_cv_ruby_compile="`$RUBY -rrbconfig -e 'print Config::CONFIG.fetch(%q(CC)), %q( ), Config::CONFIG.fetch(%q(CFLAGS))'` \$(SWIG_RB_INCLUDES)"
> + svn_cv_ruby_compile="`$RUBY -rrbconfig -e 'print Config::CONFIG.fetch(%q(CC)), %q( ), Config::CONFIG.fetch(%q(CFLAGS))'`"
> + if echo $svn_cv_ruby_compile | grep -- -Wall > /dev/null 2>&1; then
> + svn_cv_ruby_compile="$svn_cv_ruby_compile -fno-strict-aliasing"
> + fi
> + svn_cv_ruby_compile="$svn_cv_ruby_compile \$(SWIG_RB_INCLUDES)"
> ])
Uh ... -fno-strict-aliasing isn't just to suppress warnings. It is a
functional change to work around bugs exposed by gcc type aliasing
optimisations. As such, it really has nothing to do with -Wall. I
mean, either you want it or you don't.
Received on Mon Jan 2 22:21:16 2006