summaryrefslogtreecommitdiff
path: root/xmake/modules/core
diff options
context:
space:
mode:
authorruki <[email protected]>2020-11-11 23:36:49 +0800
committerGitHub <[email protected]>2020-11-11 23:36:49 +0800
commit8720d7ba6d82aacd3b6953596ef2687c3368120e (patch)
tree4f5a0e7b8f5760ac664e84b656f646265ff94d5a /xmake/modules/core
parenta027a704b2799c402f983cf373f689d0d9c6efdc (diff)
parent58d160914919331ca121c2648ce72947b816d127 (diff)
Merge pull request #1025 from SirLynix/fix-warnings
Enable more warnings on "all" settings
Diffstat (limited to 'xmake/modules/core')
-rw-r--r--xmake/modules/core/tools/cl.lua1
-rw-r--r--xmake/modules/core/tools/clang.lua1
-rw-r--r--xmake/modules/core/tools/clang_cl.lua2
-rw-r--r--xmake/modules/core/tools/gcc.lua1
-rw-r--r--xmake/modules/core/tools/nvcc.lua2
-rw-r--r--xmake/modules/core/tools/tcc.lua4
6 files changed, 8 insertions, 3 deletions
diff --git a/xmake/modules/core/tools/cl.lua b/xmake/modules/core/tools/cl.lua
index d24ef5901..371fcf6aa 100644
--- a/xmake/modules/core/tools/cl.lua
+++ b/xmake/modules/core/tools/cl.lua
@@ -137,6 +137,7 @@ function nf_warning(self, level)
, less = "-W1"
, more = "-W3"
, all = "-W3" -- = "-Wall" will enable too more warnings
+ , allextra = "-W4"
, everything = "-Wall"
, error = "-WX"
}
diff --git a/xmake/modules/core/tools/clang.lua b/xmake/modules/core/tools/clang.lua
index 549bdaae1..457de3b60 100644
--- a/xmake/modules/core/tools/clang.lua
+++ b/xmake/modules/core/tools/clang.lua
@@ -118,6 +118,7 @@ function nf_warning(self, level)
, less = "-Wall"
, more = "-Wall"
, all = "-Wall"
+ , allextra = "-Wall -Wextra"
, everything = "-Weverything"
, error = "-Werror"
}
diff --git a/xmake/modules/core/tools/clang_cl.lua b/xmake/modules/core/tools/clang_cl.lua
index 8ee58f23e..4125ab2a0 100644
--- a/xmake/modules/core/tools/clang_cl.lua
+++ b/xmake/modules/core/tools/clang_cl.lua
@@ -33,7 +33,7 @@ function init(self)
["-W1"] = "-Wall"
, ["-W2"] = "-Wall"
, ["-W3"] = "-Wall"
- , ["-W4"] = "-Wextra"
+ , ["-W4"] = "-Wall -Wextra"
, ["-Weverything"] = "-Wall -Wextra -Weffc++"
-- language
diff --git a/xmake/modules/core/tools/gcc.lua b/xmake/modules/core/tools/gcc.lua
index 5ade06550..130790a56 100644
--- a/xmake/modules/core/tools/gcc.lua
+++ b/xmake/modules/core/tools/gcc.lua
@@ -112,6 +112,7 @@ function nf_warning(self, level)
, less = "-Wall"
, more = "-Wall"
, all = "-Wall"
+ , allextra = "-Wall -Wextra"
, everything = "-Wall -Wextra -Weffc++"
, error = "-Werror"
}
diff --git a/xmake/modules/core/tools/nvcc.lua b/xmake/modules/core/tools/nvcc.lua
index c16643066..958645ec7 100644
--- a/xmake/modules/core/tools/nvcc.lua
+++ b/xmake/modules/core/tools/nvcc.lua
@@ -108,6 +108,7 @@ function nf_warning(self, level)
, less = "-W1"
, more = "-W3"
, all = "-W3" -- = "-Wall" will enable too more warnings
+ , allextra = "-W4"
, everything = "-Wall"
, error = "-WX"
}
@@ -123,6 +124,7 @@ function nf_warning(self, level)
, less = "-Wall"
, more = "-Wall"
, all = "-Wall"
+ , allextra = "-Wall -Wextra"
, everything = "-Weverything -Wall -Wextra -Weffc++"
, error = "-Werror"
}
diff --git a/xmake/modules/core/tools/tcc.lua b/xmake/modules/core/tools/tcc.lua
index a9c0abfc0..98deebbb7 100644
--- a/xmake/modules/core/tools/tcc.lua
+++ b/xmake/modules/core/tools/tcc.lua
@@ -78,8 +78,8 @@ function nf_warning(self, level)
, less = "-W1"
, more = "-W3"
, all = "-Wall"
- , extra = "-Wunsupported"
- , everything = "-Wall -Wunsupported -Wwrite-strings"
+ , allextra = "-Wall -Wunsupported -Wwrite-strings -Wimplicit-function-declaration"
+ , everything = "-Wall -Wunsupported -Wwrite-strings -Wimplicit-function-declaration"
, error = "-Werror"
}
return maps[level]