Skip to content

feat: Use CMAKE_MSVC_RUNTIME_LIBRARY for runtime selection in MSVC(#1…#1199

Merged
COM8 merged 1 commit intolibcpr:masterfrom
BestArthur:feature/msvc-runtime-selection
Mar 20, 2025
Merged

feat: Use CMAKE_MSVC_RUNTIME_LIBRARY for runtime selection in MSVC(#1…#1199
COM8 merged 1 commit intolibcpr:masterfrom
BestArthur:feature/msvc-runtime-selection

Conversation

@BestArthur
Copy link
Contributor

feat: Use CMAKE_MSVC_RUNTIME_LIBRARY for runtime selection in MSVC(#1198)

Previously, when BUILD_SHARED_LIBS was set to FALSE (OFF), the runtime library was
forcibly set to MultiThreaded. This commit replaces that behavior by using the
CMAKE_MSVC_RUNTIME_LIBRARY option, allowing users to select between MultiThreaded
and MultiThreadedDLL as a build option.

…bcpr#1198)

Previously, when BUILD_SHARED_LIBS was set to FALSE (OFF), the runtime library was
forcibly set to MultiThreaded. This commit replaces that behavior by using the
CMAKE_MSVC_RUNTIME_LIBRARY option, allowing users to select between MultiThreaded
and MultiThreadedDLL as a build option.
Copy link
Member

@COM8 COM8 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree @BestArthur. This should be set by the user. Thanks for creating the MR.

@COM8 COM8 merged commit 59e01ec into libcpr:master Mar 20, 2025
44 checks passed
@COM8 COM8 linked an issue Mar 20, 2025 that may be closed by this pull request
COM8 added a commit that referenced this pull request Mar 20, 2025
feat: Use CMAKE_MSVC_RUNTIME_LIBRARY for runtime selection in MSVC(#1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unable to select MultiThreaded or MultiThreadedDLL in MSVC environment

2 participants