New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CRT linking option of Triplet not considered by CMake Toolchain #2966
Comments
@ras0219-msft Any comments? :) |
@ras0219-msft I may have a bit of time to look at this (it doesn't look like a complex task to me). In case you agree that it should behave as described. |
I just noticed that alot of the toolchain handling etc has changed in the past couple of days. As far as I understand, with the new |
@ras0219-msft Sorry for being so obtrusive, but it would be really great to know what to do about this. As mentioned, I would even have time to do another PR, in case you see the need for something being changed. |
There is the |
Hi everybody, Hi @ras0219-msft !
When installing packages with the
x64-windows-static
triplet, the CRT ist linked statically. When compiling with the CMake toolchain (scripts/buildsystems/vcpkg.cmake), andVCPKG_TARGET_TRIPLET=x64-windows-static
, the CRT is dynamically linked.Effectively this makes compilation a little difficult, as then a mismatch of runtimes is detected and compilation fails.
While some libraries (like sdl2) provide an configuration option to force runtime linkage to static or dynamic, I believe for libraries should generally not require notion of CRT linking types in such a way. The toolchain should instead correctly set
CMAKE_C(XX)_FLAGS
as with installation.Please let me know what you think. I would be great if someone could handle this (as I won't be able to get around to doing so myself in the near future.)
Cheers, Jonathan
The text was updated successfully, but these errors were encountered: