diff options
| author | ruki <[email protected]> | 2024-01-26 23:01:44 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-01-26 23:01:44 +0800 |
| commit | fd85ae0a81de712ca3837b262e936fd67b8f483f (patch) | |
| tree | 97894c8d36a17ca6437aedd10400b8f24574d783 /xmake/modules/core/tools/nvcc.lua | |
| parent | 042362f4c3f1dab8b6b5a32fcbbae20e66e224de (diff) | |
| parent | 2a43a89241ff5044661fa7449d6455386cd3a449 (diff) | |
Merge pull request #4630 from xmake-io/runtimes
Improve runtimes to support libc++/libstdc++
Diffstat (limited to 'xmake/modules/core/tools/nvcc.lua')
| -rw-r--r-- | xmake/modules/core/tools/nvcc.lua | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/xmake/modules/core/tools/nvcc.lua b/xmake/modules/core/tools/nvcc.lua index 604fbe505..127f51656 100644 --- a/xmake/modules/core/tools/nvcc.lua +++ b/xmake/modules/core/tools/nvcc.lua @@ -171,9 +171,15 @@ function nf_optimize(self, level) end -- make vs runtime flag -function nf_runtime(self, vs_runtime) - if self:is_plat("windows") and vs_runtime then - return '-Xcompiler "-' .. vs_runtime .. '"' +function nf_runtime(self, runtime) + if self:is_plat("windows") and runtime then + local maps = { + MT = '-Xcompiler "-MT"', + MD = '-Xcompiler "-MD"', + MTd = '-Xcompiler "-MTd"', + MDd = '-Xcompiler "-MDd"' + } + return maps[runtime] end end |
