From cac5baecbc34ac2f6357c2fb6a632b0f312f96ba Mon Sep 17 00:00:00 2001 From: tdijck Date: Wed, 25 Mar 2015 10:28:00 -0700 Subject: [PATCH] Add C++11, C++14 flags for GCC & Clang --- src/_premake_init.lua | 2 ++ src/tools/gcc.lua | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/_premake_init.lua b/src/_premake_init.lua index efd54758..9d5f8273 100644 --- a/src/_premake_init.lua +++ b/src/_premake_init.lua @@ -413,6 +413,8 @@ "Unsafe", -- DEPRECATED "WinMain", "WPF", + "C++11", + "C++14", }, aliases = { FatalWarnings = { "FatalWarnings", "FatalCompileWarnings", "FatalLinkWarnings" }, diff --git a/src/tools/gcc.lua b/src/tools/gcc.lua index 694e5412..92909724 100644 --- a/src/tools/gcc.lua +++ b/src/tools/gcc.lua @@ -108,7 +108,9 @@ flags = { NoExceptions = "-fno-exceptions", NoRTTI = "-fno-rtti", - NoBufferSecurityCheck = "-fno-stack-protector" + NoBufferSecurityCheck = "-fno-stack-protector", + ["C++11"] = "-std=c++11", + ["C++14"] = "-std=c++14", } }