8000 change compiler options to use C++14 by jsteemann · Pull Request #6339 · arangodb/arangodb · GitHub
[go: up one dir, main page]

Skip to content
Dismiss alert

change compiler options to use C++14 #6339

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Sep 6, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions 3rdParty/V8/v5.7.492.77/gypfiles/standalone.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,7 @@
'-Wnon-virtual-dtor',
'-fno-exceptions',
'-fno-rtti',
'-std=gnu++11',
'-std=gnu++14',
],
'ldflags': [ '-pthread', ],
'conditions': [
Expand Down Expand Up @@ -832,7 +832,7 @@
'-Wnon-virtual-dtor',
'-fno-exceptions',
'-fno-rtti',
'-std=gnu++11',
'-std=gnu++14',
],
'conditions': [
[ 'visibility=="hidden"', {
Expand Down Expand Up @@ -1096,7 +1096,7 @@
['clang==1', {
'xcode_settings': {
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
'CLANG_CXX_LANGUAGE_STANDARD': 'c++11', # -std=c++11
'CLANG_CXX_LANGUAGE_STANDARD': 'c++14', # -std=c++14
},
'conditions': [
['clang_xcode==0', {
Expand Down Expand Up @@ -1134,7 +1134,7 @@
}, # configurations
'cflags': [ '-Wno-abi', '-Wall', '-W', '-Wno-unused-parameter'],
'cflags_cc': [ '-Wnon-virtual-dtor', '-fno-rtti', '-fno-exceptions',
'-std=gnu++11' ],
'-std=gnu++14' ],
'target_conditions': [
['_toolset=="target"', {
'cflags!': [
Expand Down Expand Up @@ -1330,7 +1330,7 @@
['clang==0 and host_clang==1 and target_arch!="ia32" and target_arch!="x64"', {
'target_conditions': [
['_toolset=="host"', {
'cflags_cc': [ '-std=gnu++11', ],
'cflags_cc': [ '-std=gnu++14', ],
}],
],
'target_defaults': {
Expand Down
6 changes: 3 additions & 3 deletions 3rdParty/linenoise-ng/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ set(LINENOISE_FRIENDLY_STRING "Linenoise NG - Linenoise Next Generation")
# compiler options
if(CMAKE_COMPILER_IS_GNUCXX)
message(STATUS "Compiler type GNU: ${CMAKE_CXX_COMPILER}")
set(BASE_COMPILER_OPTIONS "-std=c++11 -Wall -Wextra")
set(BASE_COMPILER_OPTIONS "-std=c++14 -Wall -Wextra")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BASE_COMPILER_OPTIONS}")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${BASE_COMPILER_OPTIONS} -O0 -g")
set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} ${BASE_COMPILER_OPTIONS} -Os")
Expand All @@ -32,7 +32,7 @@ if(CMAKE_COMPILER_IS_GNUCXX)
elseif(CMAKE_COMPILER_IS_CLANGCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
# using regular Clang or AppleClang
message(STATUS "Compiler type CLANG: ${CMAKE_CXX_COMPILER}")
set(BASE_COMPILER_OPTIONS "-std=c++11 -Wall -Wextra")
set(BASE_COMPILER_OPTIONS "-std=c++14 -Wall -Wextra")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BASE_COMPILER_OPTIONS}")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${BASE_COMPILER_OPTIONS} -O0 -g")
set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} ${BASE_COMPILER_OPTIONS} -Os")
Expand Down Expand Up @@ -63,7 +63,7 @@ elseif(MSVC)
else()
# unknown compiler
message(STATUS "Compiler type UNKNOWN: ${CMAKE_CXX_COMPILER}")
set(BASE_COMPILER_OPTIONS "-std=c++11 -Wall -Wextra")
set(BASE_COMPILER_OPTIONS "-std=c++14 -Wall -Wextra")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${BASE_COMPILER_OPTIONS}")
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${BASE_COMPILER_OPTIONS} -O0 -g")
set(CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL} ${BASE_COMPILER_OPTIONS} -Os")
Expand Down
2 changes: 1 addition & 1 deletion 3rdParty/rocksdb/v5.16.X/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ else()
if(MINGW)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-format")
endif()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14")
if(NOT CMAKE_BUILD_TYPE STREQUAL "Debug")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-omit-frame-pointer")
include(CheckCXXCompilerFlag)
Expand Down
2 changes: 1 addition & 1 deletion 3rdParty/rocksdb/v5.16.X/build_tools/build_detect_platform
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ if test -z "$OUTPUT"; then
fi

# we depend on C++11
PLATFORM_CXXFLAGS="-std=c++11"
PLATFORM_CXXFLAGS="-std=c++14"
# we currently depend on POSIX platform
COMMON_FLAGS="-DROCKSDB_PLATFORM_POSIX -DROCKSDB_LIB_IO_POSIX"

Expand Down
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ if (CMAKE_COMPILER_IS_GNUCC)
endif ()

if (CMAKE_COMPILER_IS_GNUCC OR APPLE)
set(BASE_CXX_FLAGS "${BASE_CXX_FLAGS} -std=c++11")
set(BASE_CXX_FLAGS "${BASE_CXX_FLAGS} -std=c++14")
endif ()

if (CMAKE_COMPILER_IS_CLANG)
Expand All @@ -573,9 +573,9 @@ if (CMAKE_COMPILER_IS_CLANG)
endif ()
endif ()

# need c++11
# need c++14
# XXX this should really be set on a per target level using cmake compile_features capabilties
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD 14)

# need threads
find_package(Threads REQUIRED)
Expand Down
0