octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Requiring C++11 in configure.ac


From: Mike Miller
Subject: Re: Requiring C++11 in configure.ac
Date: Tue, 20 Jun 2017 17:25:19 -0700
User-agent: NeoMutt/20170306 (1.8.0)

On Tue, Jun 20, 2017 at 16:18:48 -0700, Mike Miller wrote:
> The Autoconf manual explicitly documents the variables
> ac_cv_prog_cxx_stdcxx and ac_cv_prog_cxx_cxx11, so I think it's safe to
> depend on them.

I'm testing the following change with gcc 6.3, 4.8, and 4.6. It should
fail with 4.6 or older.


diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -398,6 +398,12 @@ AC_PROG_CC
 AC_PROG_CPP
 AC_PROG_GCC_TRADITIONAL
 
+## Ensure that the C++ compiler fully supports C++11.
+
+if test x"$ac_cv_prog_cxx_cxx11" = xno; then
+  AC_MSG_ERROR([a compiler that fully supports C++11 is required to build 
Octave])
+fi
+
 ## Save and restore CFLAGS and CXXFLAGS globally.  These variables
 ## are for users, so we shouldn't be touching them.  Instead, we should
 ## set the corresponding AM_ flags (currently by way of the XTRA_ variables).


-- 
mike



reply via email to

[Prev in Thread] Current Thread [Next in Thread]