-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix CMake option for choosing MSVC runtime library (#1054)
**Issue:** Building with `-DSTATIC_CRT=ON` didn't actually do anything. **Diagnosis:** Our CMake logic relied on `${CMAKE_BUILD_TYPE}` being set, but for multi-config generators like Visual Studio `${CMAKE_BUILD_TYPE}` is ignored and most users (and IDEs) don't bother setting it. **Description of changes:** 1) Use `$<CONFIG>` generator expressions, instead of checking `${CMAKE_BUILD_TYPE}`, to support multi-config generators like Visual Studio. See: https://cmake.org/cmake/help/v3.22/manual/cmake-buildsystem.7.html#build-configurations. 2) Deprecate ~STATIC_CRT~ option, replace with `AWS_STATIC_MSVC_RUNTIME_LIBRARY=OFF|ON`. - The old option name was confusing, since we refer to our codebase as "the CRT", but this option referred to Microsoft's C runtime library.
- Loading branch information
Showing
4 changed files
with
33 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters