summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorruki <[email protected]>2016-01-05 16:31:39 +0800
committerruki <[email protected]>2016-01-05 16:31:39 +0800
commit699bb9f43d540ec41be830279c96fb63bbdaad47 (patch)
tree4d9003e890fea454cc5fe747127d73ec5c0b8820
parent9488982a8547f414b972f8d802914730bac964c9 (diff)
add c11 and gnu11 languages
-rwxr-xr-xcore/src/xmake/xmake.c7
-rw-r--r--xmake/scripts/base/compiler.lua2
2 files changed, 9 insertions, 0 deletions
diff --git a/core/src/xmake/xmake.c b/core/src/xmake/xmake.c
index 759c286a8..ddbb59769 100755
--- a/core/src/xmake/xmake.c
+++ b/core/src/xmake/xmake.c
@@ -27,6 +27,13 @@
#include "xmake.h"
/* //////////////////////////////////////////////////////////////////////////////////////
+ * macros
+ */
+#ifndef TB_CONFIG_MODULE_HAVE_REGEX
+# error please enable regex module for tbox
+#endif
+
+/* //////////////////////////////////////////////////////////////////////////////////////
* globals
*/
diff --git a/xmake/scripts/base/compiler.lua b/xmake/scripts/base/compiler.lua
index ab6ee1960..a64f8bae0 100644
--- a/xmake/scripts/base/compiler.lua
+++ b/xmake/scripts/base/compiler.lua
@@ -229,6 +229,8 @@ function compiler._addflags_from_target(module, flags, flagnames, target)
, gnu89 = "-std=gnu89"
, c99 = "-std=c99"
, gnu99 = "-std=gnu99"
+ , c11 = "-std=c11"
+ , gnu11 = "-std=gnu11"
})
elseif flagname == "cxxflags" or flagname == "mxxflags" then
table.join2(languages, { cxx98 = "-std=c++98"