aboutsummaryrefslogtreecommitdiff
path: root/m4/ax_cxx_compile_stdcxx_11.m4
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2018-05-29 22:46:07 +0200
committerEven Rouault <even.rouault@spatialys.com>2018-05-30 11:48:28 +0200
commit29051766975d471c4eff9f7b3137752234cf1a4c (patch)
tree1eeee2a54ffeff13d0e8ed78951cd2a12a830a6e /m4/ax_cxx_compile_stdcxx_11.m4
parentf773897a3025438326c1131e1586d9ddae080c4f (diff)
downloadPROJ-29051766975d471c4eff9f7b3137752234cf1a4c.tar.gz
PROJ-29051766975d471c4eff9f7b3137752234cf1a4c.zip
Enable c++ compilation with autotools and cmake, hardened compilation flags and add catch2 framework
Hardened compilation flags come from GDAL' configure.ac and are 'combat proven' Dummy test added just to demonstrate catch2 based tests work.
Diffstat (limited to 'm4/ax_cxx_compile_stdcxx_11.m4')
-rw-r--r--m4/ax_cxx_compile_stdcxx_11.m439
1 files changed, 39 insertions, 0 deletions
diff --git a/m4/ax_cxx_compile_stdcxx_11.m4 b/m4/ax_cxx_compile_stdcxx_11.m4
new file mode 100644
index 00000000..0aadeafe
--- /dev/null
+++ b/m4/ax_cxx_compile_stdcxx_11.m4
@@ -0,0 +1,39 @@
+# ============================================================================
+# http://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_11.html
+# ============================================================================
+#
+# SYNOPSIS
+#
+# AX_CXX_COMPILE_STDCXX_11([ext|noext], [mandatory|optional])
+#
+# DESCRIPTION
+#
+# Check for baseline language coverage in the compiler for the C++11
+# standard; if necessary, add switches to CXX and CXXCPP to enable
+# support.
+#
+# This macro is a convenience alias for calling the AX_CXX_COMPILE_STDCXX
+# macro with the version set to C++11. The two optional arguments are
+# forwarded literally as the second and third argument respectively.
+# Please see the documentation for the AX_CXX_COMPILE_STDCXX macro for
+# more information. If you want to use this macro, you also need to
+# download the ax_cxx_compile_stdcxx.m4 file.
+#
+# LICENSE
+#
+# Copyright (c) 2008 Benjamin Kosnik <bkoz@redhat.com>
+# Copyright (c) 2012 Zack Weinberg <zackw@panix.com>
+# Copyright (c) 2013 Roy Stogner <roystgnr@ices.utexas.edu>
+# Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov <sokolov@google.com>
+# Copyright (c) 2015 Paul Norman <penorman@mac.com>
+# Copyright (c) 2015 Moritz Klammler <moritz@klammler.eu>
+#
+# Copying and distribution of this file, with or without modification, are
+# permitted in any medium without royalty provided the copyright notice
+# and this notice are preserved. This file is offered as-is, without any
+# warranty.
+
+#serial 17
+
+AX_REQUIRE_DEFINED([AX_CXX_COMPILE_STDCXX])
+AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [AX_CXX_COMPILE_STDCXX([11], [$1], [$2])])