From e67a19c220db8315914a74be7b3527535e480c87 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 1 Mar 2012 12:36:58 +0200 Subject: Rename cxx11.m4 to c++11.m4 --- m4/c++11.m4 | 38 ++++++++++++++++++++++++++++++++++++++ m4/cxx11.m4 | 38 -------------------------------------- 2 files changed, 38 insertions(+), 38 deletions(-) create mode 100644 m4/c++11.m4 delete mode 100644 m4/cxx11.m4 (limited to 'm4') diff --git a/m4/c++11.m4 b/m4/c++11.m4 new file mode 100644 index 0000000..774f20d --- /dev/null +++ b/m4/c++11.m4 @@ -0,0 +1,38 @@ +dnl file : m4/cxx11.m4 +dnl copyright : Copyright (c) 2009-2012 Code Synthesis Tools CC +dnl license : GNU GPL v2; see accompanying LICENSE file +dnl +dnl CXX11(MACRO, DESCRIPTION) +dnl +dnl Check if we are compiling in the C++11 mode. If we are, define MACRO as +dnl both a macro and conditional as well as set the cxx11 variable to 'yes'. +dnl +AC_DEFUN([CXX11], +[ +cxx11=no + +AC_MSG_CHECKING([whether we are in C++11 mode]) + +CXX_LIBTOOL_LINK_IFELSE( +AC_LANG_SOURCE([[ +#include + +int +main () +{ + std::shared_ptr p (new int (10)); + *p = 11; +} +]]), +[cxx11=yes]) + +if test x"$cxx11" = xyes; then + AC_MSG_RESULT([yes]) + AC_DEFINE([$1], [1], [$2]) +else + AC_MSG_RESULT([no]) +fi + +AM_CONDITIONAL([$1], [test x$cxx11 = xyes]) + +])dnl diff --git a/m4/cxx11.m4 b/m4/cxx11.m4 deleted file mode 100644 index 774f20d..0000000 --- a/m4/cxx11.m4 +++ /dev/null @@ -1,38 +0,0 @@ -dnl file : m4/cxx11.m4 -dnl copyright : Copyright (c) 2009-2012 Code Synthesis Tools CC -dnl license : GNU GPL v2; see accompanying LICENSE file -dnl -dnl CXX11(MACRO, DESCRIPTION) -dnl -dnl Check if we are compiling in the C++11 mode. If we are, define MACRO as -dnl both a macro and conditional as well as set the cxx11 variable to 'yes'. -dnl -AC_DEFUN([CXX11], -[ -cxx11=no - -AC_MSG_CHECKING([whether we are in C++11 mode]) - -CXX_LIBTOOL_LINK_IFELSE( -AC_LANG_SOURCE([[ -#include - -int -main () -{ - std::shared_ptr p (new int (10)); - *p = 11; -} -]]), -[cxx11=yes]) - -if test x"$cxx11" = xyes; then - AC_MSG_RESULT([yes]) - AC_DEFINE([$1], [1], [$2]) -else - AC_MSG_RESULT([no]) -fi - -AM_CONDITIONAL([$1], [test x$cxx11 = xyes]) - -])dnl -- cgit v1.1