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

ruby-changes:62678

From: =E5=8D=9C=E9=83=A8=E6=98=8C=E5=B9=B3 <ko1@a...>
Date: Sat, 22 Aug 2020 00:45:57 +0900 (JST)
Subject: [ruby-changes:62678] 914b2208ab (master): configure.ac: rule out old Sun C++

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

From 914b2208ab3eddec478cdc3e079e6c30d0f0892c 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: Fri, 21 Aug 2020 23:53:05 +0900
Subject: configure.ac: rule out old Sun C++

CI failures observed for old Sun C++.  We don't want to hustle, as newer
versions are okay.  Just check the sanity and rule out insane compilers.

diff --git a/configure.ac b/configure.ac
index df14655..ee4b214 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1115,6 +1115,20 @@ main() https://github.com/ruby/ruby/blob/trunk/configure.ac#L1115
 [	LIBS="-lm $LIBS"])
 : ${ORIG_LIBS=$LIBS}
 
+AS_IF([test -n "${CXX}"], [
+    RUBY_WERROR_FLAG([
+        AC_MSG_CHECKING([whether CXXFLAGS is valid])
+        AC_LANG_PUSH(C++)
+        AC_TRY_COMPILE([@%:@include <cstdio>], [], [AC_MSG_RESULT(yes)], [
+            AC_MSG_RESULT(no)
+            # The message mentions CXXFLAGS, but CPPFLAGS might also affects.
+            AC_MSG_WARN([something wrong with CXXFLAGS="$CXXFLAGS"])
+            CXX=false
+        ])
+        AC_LANG_POP(C++)
+    ])
+])
+
 AC_CHECK_LIB(crypt, crypt)      # glibc (GNU/Linux, GNU/Hurd, GNU/kFreeBSD)
 AC_CHECK_LIB(dl, dlopen)	# Dynamic linking for SunOS/Solaris and SYSV
 AC_CHECK_LIB(dld, shl_load)	# Dynamic linking for HP-UX
-- 
cgit v0.10.2


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

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