[前][次][番号順一覧][スレッド一覧]

ruby-changes:64192

From: =E5=8D=9C=E9=83=A8=E6=98=8C=E5=B9=B3 <ko1@a...>
Date: Wed, 16 Dec 2020 08:48:09 +0900 (JST)
Subject: [ruby-changes:64192] ccc828f499 (master): configure.ac: avoid squashing CXX=g++

https://git.ruby-lang.org/ruby.git/commit/?id=ccc828f499

From ccc828f49956424b2548e32cb3bc3a78e16e207b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=8D=9C=E9=83=A8=E6=98=8C=E5=B9=B3?=
 <shyouhei@r...>
Date: Tue, 15 Dec 2020 16:57:28 +0900
Subject: 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.

diff --git a/configure.ac b/configure.ac
index dbcf7c0..dbd0832 100644
--- a/configure.ac
+++ b/configure.ac
@@ -194,8 +194,7 @@ AS_IF([test "${CXX}" = "g++" -a -z "${GXX}"], [ https://github.com/ruby/ruby/blob/trunk/configure.ac#L194
     # 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() https://github.com/ruby/ruby/blob/trunk/configure.ac#L1133
 [	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++)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]