Skip to content

Commit 90f055f

Browse files
committed
build: use higher version c++
1 parent a399881 commit 90f055f

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

common.gypi

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
'component%': 'static_library', # NB. these names match with what V8 expects
1111
'msvs_multi_core_compile': '0', # we do enable multicore compiles, but not using the V8 way
1212
'python%': 'python',
13-
13+
'gas_version%': 0,
14+
'llvm_version%': 0,
15+
1416
'node_shared%': 'false',
1517
'force_dynamic_crt%': 0,
1618
'node_use_v8_platform%': 'true',
@@ -211,6 +213,9 @@
211213
# and their sheer number drowns out other, more legitimate warnings.
212214
'DisableSpecificWarnings': ['4267'],
213215
'WarnAsError': 'false',
216+
'AdditionalOptions': [
217+
'/std:c++14'
218+
],
214219
},
215220
'VCLibrarianTool': {
216221
},
@@ -293,7 +298,7 @@
293298
}],
294299
[ 'OS in "linux freebsd openbsd solaris android aix"', {
295300
'cflags': [ '-Wall', '-Wextra', '-Wno-unused-parameter', ],
296-
'cflags_cc': [ '-fno-rtti', '-fno-exceptions', '-std=gnu++0x' ],
301+
'cflags_cc': [ '-fno-rtti', '-fno-exceptions' ],
297302
'ldflags': [ '-rdynamic' ],
298303
'target_conditions': [
299304
# The 1990s toolchain on SmartOS can't handle thin archives.
@@ -409,7 +414,6 @@
409414
['clang==1', {
410415
'xcode_settings': {
411416
'GCC_VERSION': 'com.apple.compilers.llvm.clang.1_0',
412-
'CLANG_CXX_LANGUAGE_STANDARD': 'gnu++0x', # -std=gnu++0x
413417
'CLANG_CXX_LIBRARY': 'libc++',
414418
},
415419
}],
@@ -431,7 +435,12 @@
431435
'ldflags': [
432436
'-Wl,--export-dynamic',
433437
],
434-
}]
438+
}],
439+
['llvm_version != 0', {
440+
'cflags': [ '-std=c++14' ],
441+
}, {
442+
'cflags': [ '-std=gnu++11' ],
443+
}],
435444
],
436445
}
437446
}

0 commit comments

Comments
 (0)