-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Open
Description
By default, a C++ application in VS uses the debug version of the C runtime library when building with Configuration=Debug. Since we only ship a release libnethost.lib
using the release CRT, if a consumer tries to link it in, they will hit mismatches between the runtime libraries (LNK2038
). In order to consume the static libnethost.lib
, they have to change the defaults for the Debug configuration to use the release version of the C runtime library.
Kind of a continuation of our 'we lack a defined/worn path for shipping native assets'. Possibilities:
- Ship a
libnethostd.lib
(and .pdb) on Windows that uses the debug CRT- Would add about 4MB
- Maintain and push people to vcpkg
- Port for nethost is there, but, to my knowledge, we have not been maintaining/updating
- Only support using the release CRT if using static nethost (and document)
- Consumers would need to compile with
/MT
and not define_DEBUG
(this is what DNNE is doing, cc @AaronRobinsonMSFT)
- Consumers would need to compile with
cc @vitek-karas
AaronRobinsonMSFT and tuokri
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
No status