From b411090c861fdb3f6155207e27d79b696e42fb0a Mon Sep 17 00:00:00 2001 From: usa Date: Sun, 26 Mar 2017 16:42:03 +0000 Subject: merge revision(s) 53566: * configure.in: improve ICC (Intel C Compiler) support. * configure.in (CXX): The name of icc's c++ compiler is `icpc`. * configure.in (warnings): Add `-diag-disable=2259` to suppress noisy warnings: "non-pointer conversion from "..." to "..." may lose significant bits". * configure.in (optflags): Add `-fp-model precise` like -fno-fast-math. * lib/mkmf.rb: icc supports -Werror=division-by-zero and -Werror=deprecated-declarations, but doesn't support -Wdivision-by-zero and -Wdeprecated-declarations. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_2@58143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 16 ++++++++++++++++ configure.in | 4 +++- lib/mkmf.rb | 3 +++ version.h | 6 +++--- 4 files changed, 25 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3c5af4ba75..37160ed748 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,19 @@ +Mon Mar 27 01:41:37 2017 NARUSE, Yui + + * configure.in: improve ICC (Intel C Compiler) support. + + * configure.in (CXX): The name of icc's c++ compiler is `icpc`. + + * configure.in (warnings): Add `-diag-disable=2259` to suppress + noisy warnings: "non-pointer conversion from "..." to "..." may + lose significant bits". + + * configure.in (optflags): Add `-fp-model precise` like -fno-fast-math. + + * lib/mkmf.rb: icc supports -Werror=division-by-zero + and -Werror=deprecated-declarations, but doesn't support + -Wdivision-by-zero and -Wdeprecated-declarations. + Sun Mar 26 17:24:02 2017 NAKAMURA Usaku * thread.c (rb_thread_fd_close): unintentionally removed at r58094. diff --git a/configure.in b/configure.in index e4b9396d0d..fc30522906 100644 --- a/configure.in +++ b/configure.in @@ -255,6 +255,7 @@ AS_CASE(["$build_os"], [xgcc-4.2|x/usr/bin/gcc-4.2], [: ${CXX=g++-4.2}], [xgcc|x/usr/bin/gcc], [: ${CXX=g++}], [xcc|x/usr/bin/cc], [: ${CXX=c++}], + [xicc], [: ${CXX=icpc}], [xclang|x/usr/bin/clang], [: ${CXX=clang++}]) ]) test -z "$CC" || ac_cv_prog_CC="$CC" @@ -794,6 +795,7 @@ if test "$GCC:${warnflags+set}:no" = yes::no; then extra_warning= fi for wflag in -Wno-unused-parameter -Wno-parentheses -Wno-long-long \ + -diag-disable=2259 \ -Wno-missing-field-initializers \ -Wunused-variable \ -Werror=pointer-arith \ @@ -948,7 +950,7 @@ if test "$GCC" = yes; then ]) # disable fast-math - for oflag in -fno-fast-math; do + for oflag in -fno-fast-math -fp-model\ precise; do RUBY_TRY_CFLAGS($oflag, [RUBY_APPEND_OPTION(optflags, $oflag)]) done fi diff --git a/lib/mkmf.rb b/lib/mkmf.rb index b38bd2e4f4..d30471ee8e 100644 --- a/lib/mkmf.rb +++ b/lib/mkmf.rb @@ -2438,6 +2438,9 @@ site-install-rb: install-rb if $warnflags = CONFIG['warnflags'] and CONFIG['GCC'] == 'yes' # turn warnings into errors only for bundled extensions. config['warnflags'] = $warnflags.gsub(/(\A|\s)-Werror[-=]/, '\1-W') + if /icc\z/ =~ config['CC'] + config['warnflags'].gsub!(/(\A|\s)-W(?:division-by-zero|deprecated-declarations)/, '\1') + end RbConfig.expand(rbconfig['warnflags'] = config['warnflags'].dup) config.each do |key, val| RbConfig.expand(rbconfig[key] = val.dup) if /warnflags/ =~ val diff --git a/version.h b/version.h index 1b0cfd8f1f..23ddc0d364 100644 --- a/version.h +++ b/version.h @@ -1,10 +1,10 @@ #define RUBY_VERSION "2.2.7" -#define RUBY_RELEASE_DATE "2017-03-26" -#define RUBY_PATCHLEVEL 468 +#define RUBY_RELEASE_DATE "2017-03-27" +#define RUBY_PATCHLEVEL 469 #define RUBY_RELEASE_YEAR 2017 #define RUBY_RELEASE_MONTH 3 -#define RUBY_RELEASE_DAY 26 +#define RUBY_RELEASE_DAY 27 #include "ruby/version.h" -- cgit v1.2.3