summaryrefslogtreecommitdiff
path: root/xmake/rules/c++/modules/modules_support/msvc.lua
diff options
context:
space:
mode:
authorArthur LAURENT <[email protected]>2022-08-07 13:38:47 +0200
committerArthur LAURENT <[email protected]>2022-08-07 13:38:47 +0200
commita8f09abe90cf7955a0b8bb2f6747ecc6ac0c28a7 (patch)
treeccc88ff3f0a14caba8d0c27efc5def57b2582206 /xmake/rules/c++/modules/modules_support/msvc.lua
parent7c68491b43bb32683731473cbf77d1923ad14e0e (diff)
Improve code
Diffstat (limited to 'xmake/rules/c++/modules/modules_support/msvc.lua')
-rw-r--r--xmake/rules/c++/modules/modules_support/msvc.lua6
1 files changed, 4 insertions, 2 deletions
diff --git a/xmake/rules/c++/modules/modules_support/msvc.lua b/xmake/rules/c++/modules/modules_support/msvc.lua
index dbdfbf744..371cc1f50 100644
--- a/xmake/rules/c++/modules/modules_support/msvc.lua
+++ b/xmake/rules/c++/modules/modules_support/msvc.lua
@@ -199,8 +199,9 @@ function generate_stl_headerunits_for_batchcmds(target, batchcmds, headerunits,
local args = {headernameflag .. ":angle", headerunit.name, ifcoutputflag, stlcachedir, "-Fo" .. objectfile}
batchcmds:show_progress(opt.progress, "${color.build.object}generating.cxx.headerunit.bmi %s", headerunit.name)
batchcmds:vrunv(compinst:program(), table.join(compinst:compflags({target = target}), common_args, args), {envs = vcvars})
+ batchcmds:add_depfiles(headerunit.path)
- _add_module_to_mapper(mapper_file, headerunitflag .. ":angle", headerunit.name .. "=" .. path.filename(headerunit.name) .. get_bmi_extension())
+ _add_module_to_mapper(headerunitflag .. ":angle", headerunit.name .. "=" .. path.filename(headerunit.name) .. get_bmi_extension())
_add_objectfile_to_link_arguments(linker_file, objectfile)
end
depmtime = math.max(depmtime, os.mtime(bmifile))
@@ -251,7 +252,8 @@ function generate_user_headerunits_for_batchcmds(target, batchcmds, headerunits,
batchcmds:show_progress(opt.progress, "${color.build.object}generating.cxx.headerunit.bmi %s", headerunit.name)
batchcmds:vrunv(compinst:program(), table.join(compinst:compflags({target = target}), common_args, args), {envs = vcvars})
batchcmds:add_depfiles(headerunit.path)
- _add_module_to_mapper(mapper_file, headerunitflag .. headerunit.type, headerunit.name .. "=" .. path.relative(bmifile, cachedir))
+
+ _add_module_to_mapper(headerunitflag .. headerunit.type, headerunit.name .. "=" .. path.relative(bmifile, cachedir))
_add_objectfile_to_link_arguments(linker_file, objectfile)
depmtime = math.max(depmtime, os.mtime(bmifile))