Commit 58fd7791 authored by Guillaume Roguez's avatar Guillaume Roguez Committed by Adrien Béraud

require C++14

Move build requirements from C++11 to C++14, for contrib and core.

[GR: ci msg + contrib support + m4 update]

Change-Id: I22793ba1ca06ea7c45d237c882a92d20a008f76f
Reviewed-by: Guillaume Roguez's avatarGuillaume Roguez <guillaume.roguez@savoirfairelinux.com>
Signed-off-by: Guillaume Roguez's avatarGuillaume Roguez <guillaume.roguez@savoirfairelinux.com>
parent 44c61afc
......@@ -139,8 +139,8 @@ DOLT
lt_cv_deplibs_check_method=pass_all
dnl Check for C++11 support
AX_CXX_COMPILE_STDCXX_11([ext],[mandatory])
dnl Check for C++14 support
AX_CXX_COMPILE_STDCXX(14,[ext],[mandatory])
dnl Check for header files
AC_FUNC_ALLOCA
......
......@@ -40,7 +40,7 @@ index 0000000..cca155e
+echo "cd-ing to $here"
+cd "$here" || exit 1
+
+CPPSTD=c++11 #c++89, c++99, c++14
+CPPSTD=c++14 #c++89, c++99, c++14
+STDLIB=libc++ # libstdc++
+COMPILER=clang++
+PARALLEL_MAKE=16 # how many threads to make boost with
......
......@@ -26,7 +26,7 @@ BOOST_B2_OPTS += target-os=windows \
binary-format=pe \
architecture=x86 \
--user-config=user-config.jam \
cxxflags="-std=c++11 -fPIC -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4"
cxxflags="-std=c++14 -fPIC -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4"
endif
ifdef HAVE_ANDROID
BOOST_B2_OPTS += --user-config=user-config.jam
......
......@@ -133,7 +133,7 @@ LD=xcrun ld
STRIP=xcrun strip
RANLIB=xcrun ranlib
EXTRA_COMMON := -isysroot $(MACOSX_SDK) -mmacosx-version-min=$(MIN_OSX_VERSION) -DMACOSX_DEPLOYMENT_TARGET=$(MIN_OSX_VERSION)
EXTRA_CXXFLAGS += -std=c++11 -stdlib=libc++
EXTRA_CXXFLAGS += -stdlib=libc++
EXTRA_LDFLAGS += -Wl,-syslibroot,$(MACOSX_SDK)
ifeq ($(ARCH),x86_64)
EXTRA_COMMON += -m64
......@@ -174,7 +174,7 @@ else
EXTRA_CFLAGS += -mios-simulator-version-min=$(MIN_IOS_VERSION)
endif
EXTRA_CXXFLAGS=$(EXTRA_CFLAGS) -std=c++11 -stdlib=libc++
EXTRA_CXXFLAGS=$(EXTRA_CFLAGS) -stdlib=libc++
EXTRA_LDFLAGS=$(EXTRA_CFLAGS)
endif
......@@ -183,7 +183,6 @@ ifdef HAVE_WIN32
ifneq ($(shell $(CC) $(CFLAGS) -E -dM -include _mingw.h - < /dev/null | grep -E __MINGW64_VERSION_MAJOR),)
HAVE_MINGW_W64 := 1
endif
EXTRA_CXXFLAGS += -std=c++11
endif
ifdef HAVE_SOLARIS
......@@ -194,6 +193,8 @@ EXTRA_COMMON += -m32
endif
endif
EXTRA_CXXFLAGS += -std=c++14
cppcheck = $(shell $(CC) $(CFLAGS) -E -dM - < /dev/null | grep -E $(1))
EXTRA_CPPFLAGS += -I$(PREFIX)/include
......
This diff is collapsed.
# ============================================================================
# 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 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 15
include([ax_cxx_compile_stdcxx.m4])
AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [AX_CXX_COMPILE_STDCXX([11], [$1], [$2])])
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment