summaryrefslogtreecommitdiff
path: root/xmake/core/tool/compiler.lua
diff options
context:
space:
mode:
authorruki <[email protected]>2019-03-09 22:04:08 +0800
committerruki <[email protected]>2019-03-09 22:04:08 +0800
commit24de4d027e54752ef54803df5c283f480ed04f60 (patch)
treef3e9621b24ec05f4727f7978ab0c97430810efc5 /xmake/core/tool/compiler.lua
parent7a68e6ad25e28c1b1c375147bb0f543ef3a47862 (diff)
inherit value from target deps
Diffstat (limited to 'xmake/core/tool/compiler.lua')
-rw-r--r--xmake/core/tool/compiler.lua16
1 files changed, 8 insertions, 8 deletions
diff --git a/xmake/core/tool/compiler.lua b/xmake/core/tool/compiler.lua
index 3030946ad..781e95e7d 100644
--- a/xmake/core/tool/compiler.lua
+++ b/xmake/core/tool/compiler.lua
@@ -45,7 +45,7 @@ function compiler:_language()
end
-- add flags from the platform
-function compiler:_addflags_from_platform(flags, targetkind)
+function compiler:_add_flags_from_platform(flags, targetkind)
-- add flags
local toolname = self:name()
@@ -60,7 +60,7 @@ function compiler:_addflags_from_platform(flags, targetkind)
end
-- add flags from the compiler
-function compiler:_addflags_from_compiler(flags, targetkind)
+function compiler:_add_flags_from_compiler(flags, targetkind)
for _, flagkind in ipairs(self:_flagkinds()) do
-- add compiler, e.g. cxflags
@@ -286,31 +286,31 @@ function compiler:compflags(opt)
-- add flags from the configure
local flags = {}
- self:_addflags_from_config(flags)
+ self:_add_flags_from_config(flags)
-- add flags for the target
- self:_addflags_from_target(flags, target)
+ self:_add_flags_from_target(flags, target)
-- add flags for the source file
if opt.sourcefile and target and target.fileconfig then
local fileconfig = target:fileconfig(opt.sourcefile)
if fileconfig then
- self:_addflags_from_argument(flags, target, fileconfig)
+ self:_add_flags_from_argument(flags, target, fileconfig)
end
end
-- add flags for the argument
if opt.config then
- self:_addflags_from_argument(flags, target, opt.config)
+ self:_add_flags_from_argument(flags, target, opt.config)
end
-- add flags from the platform
if target then
- self:_addflags_from_platform(flags, targetkind)
+ self:_add_flags_from_platform(flags, targetkind)
end
-- add flags from the compiler
- self:_addflags_from_compiler(flags, targetkind)
+ self:_add_flags_from_compiler(flags, targetkind)
-- preprocess flags
return self:_preprocess_flags(flags)