diff options
| author | ruki <[email protected]> | 2019-10-25 00:48:22 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2019-10-24 22:50:18 +0800 |
| commit | 2f623aed782cd56f9cdd28e94e258c854cbfeab8 (patch) | |
| tree | 6d0c3e6e5a1e5b9dd26f99f5388b4dff5073ff22 /xmake/modules/package/manager/vcpkg/install_package.lua | |
| parent | e5f1534779029d20e2cb3f1d92405f7d88a976e0 (diff) | |
support vs_runtime for vcpkg
Diffstat (limited to 'xmake/modules/package/manager/vcpkg/install_package.lua')
| -rw-r--r-- | xmake/modules/package/manager/vcpkg/install_package.lua | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/xmake/modules/package/manager/vcpkg/install_package.lua b/xmake/modules/package/manager/vcpkg/install_package.lua index 3ee244c2f..b38fdad15 100644 --- a/xmake/modules/package/manager/vcpkg/install_package.lua +++ b/xmake/modules/package/manager/vcpkg/install_package.lua @@ -48,8 +48,14 @@ function main(name, opt) arch = "x64" end + -- init triplet + local triplet = arch .. "-" .. plat + if opt.plat == "windows" and opt.vs_runtime == "MT" then + triplet = triplet .. "-static" + end + -- init argv - local argv = {"install", string.format("%s:%s-%s", name, arch, plat)} + local argv = {"install", name .. ":" .. triplet} -- install package os.vrunv(path.join(vcpkgdir, "vcpkg"), argv) |
