diff --git a/scripts/buildsystems/msbuild/vcpkg-general.xml b/scripts/buildsystems/msbuild/vcpkg-general.xml index 5c84aa0daa..32610684d5 100644 --- a/scripts/buildsystems/msbuild/vcpkg-general.xml +++ b/scripts/buildsystems/msbuild/vcpkg-general.xml @@ -62,8 +62,11 @@ + + + Description="Specifies the triplet used by Vcpkg. Does not include the '-static' or '-static-md' suffixes that may be added by the 'Use static libraries' and 'Use Dynamic CRT' flags." /> diff --git a/scripts/buildsystems/msbuild/vcpkg.targets b/scripts/buildsystems/msbuild/vcpkg.targets index 9719f388ee..91c3e56d10 100644 --- a/scripts/buildsystems/msbuild/vcpkg.targets +++ b/scripts/buildsystems/msbuild/vcpkg.targets @@ -38,7 +38,10 @@ <_ZVcpkgLinkage /> <_ZVcpkgLinkage Condition="'$(VcpkgUseStatic)' == 'true'">-static - $(VcpkgPlatformTarget)-$(VcpkgOSTarget)$(_ZVcpkgLinkage) + <_ZVcpkgLinkageMD /> + <_ZVcpkgLinkageMD Condition="'$(VcpkgUseStatic)' == 'true' and '$(VcpkgUseMD)' == 'true'">-md + $(VcpkgPlatformTarget)-$(VcpkgOSTarget)$(_ZVcpkgLinkage)$(_ZVcpkgLinkageMD) + $(VcpkgTriplet)$(_ZVcpkgLinkage)$(_ZVcpkgLinkageMD)