diff options
author | 卜部昌平 <shyouhei@ruby-lang.org> | 2020-12-15 16:57:28 +0900 |
---|---|---|
committer | 卜部昌平 <shyouhei@ruby-lang.org> | 2020-12-16 08:47:49 +0900 |
commit | ccc828f49956424b2548e32cb3bc3a78e16e207b (patch) | |
tree | 8a67ca567ac5b9db40ee6613df2bc281ba2ca05b /configure.ac | |
parent | 8558d5e4801b74b058dc2a534be2be85037cadb5 (diff) |
configure.ac: avoid squashing CXX=g++
We are discussing this issue at [Bug #17337] but in the meantime, leave
this questionable autoconf glitch as-is to save sassc and eventmachine.
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3907
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index dbcf7c0cee..dbd08321bd 100644 --- a/configure.ac +++ b/configure.ac @@ -194,8 +194,7 @@ AS_IF([test "${CXX}" = "g++" -a -z "${GXX}"], [ # AC_PROG_CXX sets $CXX to "g++" when it purposefully finds that there is # _no_ g++. This brain-damaged design must be worked around. Thankfully, # similar thing doesn't happen for AC_PROG_CC. - AC_MSG_NOTICE([C++ features disabled due to lack of a C++ compiler.]) - AS_UNSET(CXX) + rb_there_is_in_fact_no_gplusplus_but_autoconf_is_cheating_us=true ]) test x"$target_alias" = x && @@ -1134,7 +1133,10 @@ main() [ LIBS="-lm $LIBS"]) : ${ORIG_LIBS=$LIBS} -AS_IF([test -n "${CXX}"], [ +AS_IF([test -n "${rb_there_is_in_fact_no_gplusplus_but_autoconf_is_cheating_us}"], [ + AC_MSG_NOTICE([Test skipped due to lack of a C++ compiler.]) +], +[test -n "${CXX}"], [ RUBY_WERROR_FLAG([ AC_MSG_CHECKING([whether CXXFLAGS is valid]) AC_LANG_PUSH(C++) |