toolchains: fix MSVC rc.exe invocation#51151
Conversation
Change `-c65001` in `CMAKE_RC_FLAGS`, which some versions of `rc.exe` apparently throw an invalid invocation error on to `/c65001` which works fine. Signed-off-by: Rafael Kitover <rkitover@gmail.com>
|
I would like to have seen a reference to an actual report or documentation. |
|
Hi Kai. I don't exactly know what or where the problem was, but it was fixed with this change. I am using the latest Visual Studio 2026. I don't see any problems building ports that use MSYS2. Do you know of any that may be problematic? I'll be happy to fix any issues. This would only happen with commands being executed by MSYS2's |
|
It seems really strange to me that the toolchain files are "fixed" without knowing "what or where the problem was". Such changes invalidate everybody's cached artifacts. In vcpkg CI, there were no problems with msys2 based ports before and after this PR. Just FTR - but probably unrelated - the issues with msys2 mingw cmake and VS rc.exe look like #49203. |
|
@dg0yt I'm sorry, the change looked plausible to me but I agree we should probably be more specific about a "demonstrate the before/after fix". (There are a lot of Windows tools that require |
|
I had this problem and it was definitely the problem, because It's possible some government person was doing something to my toolchain and they have some version of |
Change
-c65001inCMAKE_RC_FLAGS, which some versions ofrc.exeapparently throw an invalid invocation error on to/c65001which works fine.