Fix libcmt/libcmtd.lib link warning#1338
Fix libcmt/libcmtd.lib link warning#1338antkmsft merged 3 commits intoAzure:masterfrom antkmsft:libcmtd
Conversation
| OSVmImage: 'windows-2019' | ||
| vcpkg.deps: 'curl[winssl] paho-mqtt cmocka' | ||
| VCPKG_DEFAULT_TRIPLET: 'x64-windows-static' | ||
| VCPKG_DEFAULT_TRIPLET: 'x64-windows-static-md' |
There was a problem hiding this comment.
What does -md mean in this context and how does that fix the underlying issue?
There was a problem hiding this comment.
I haven't looked too closely, but this might be interesting to follow up to understand why:
microsoft/vcpkg#1131 (comment)
It is discouraged to use
static-mdtriplet...
I wonder if the issue is with the static part or the -md part.
There was a problem hiding this comment.
@barcharcraz - can you please take a look at this as well and share your thoughts.
There was a problem hiding this comment.
That thread is from 2017. Probably there were issues back then. And also I can see that these triplets were added to the officiale vcpkg repo on February, so maybe there were other issues at a time. But now it is there. microsoft/vcpkg@71a9def. Right now, it seems permanent and I don't see why we can't use it.
The reason why we were getting the warning was that we built our SDK with dynamic runtime, but cmocka was built with a reference to static runtime, and we were inking them together, and that is what the warning was telling us. Now we build cmocka with the same runtime as our SDK, so now they are consistent, and there is no warning anymore.
| OSVmImage: 'windows-2019' | ||
| vcpkg.deps: '' | ||
| VCPKG_DEFAULT_TRIPLET: 'x64-windows-static' | ||
| VCPKG_DEFAULT_TRIPLET: 'x64-windows-static-md' |
There was a problem hiding this comment.
Does it make sense to use -md even for the release leg (presumably -md refers to some debug runtime)?
There was a problem hiding this comment.
It is not. -md stands for "multithreaded dynamic".
There was a problem hiding this comment.
Consider updating references x64-windows-static in docs to include -md. We have a couple of places if you search for triplet:
https://github.com/Azure/azure-sdk-for-c/blob/ef22522414e5b56acba056eae84dd3facda63865/sdk/samples/iot/README.md#set-environment-variables
Closes #1020