-
Notifications
You must be signed in to change notification settings - Fork 10
Search Visual Studio if not on PATH #10
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
Conversation
Linux is failing because the runner uses a deprecated ubuntu version. We'll need to fix this in a separate PR first. |
Oh you are gonna hate me for telling you this, but you should probably use vshwere.exe, CAKE already has wrapper methods for it as well 😅 |
Ah. I didn't use vswhere because it looked like an .exe that you had to download and the Microsoft documentation didn't mention that you could have it as a nuget and that Cake has a wrapper for it... gotta love official documentation. It's likely a cleaner and lighter code to use vswhere, I'll check it out and update the PR if need be. |
I've updated this to use |
It doesn't build on arm anymore because of this: libsdl-org/SDL#13254 This is due to a recent change in Visual Studio C++ compiler (since v15.44). We will need to wait for SDL 2.32.9 to release and point to it so that the latest Visual Studio can build arm64 again. Alternatively, we can inject |
I've updated to use Cake's vswhere, but this is still blocked while we wait for SDL 2.32.9 to release to fix the |
There's no sign of a new SDL 2 release in the coming days, so I upgraded SDL 2 to basically 2.32.8 + the ARM fix. I think it's safe to just grab that and tag it 2.32.8. It's pretty much the only change and it's not a functional one, so it's pretty much a bare 2.32.8. Once merged, I'll update the main repository. |
SDL 2.34.10 has released. This PR is ready to be merged and updated upstream. |
CMake and MSBuild are not defined in PATH by default on Windows.
This PR checks if they are on PATH like expected.
If they aren't, it will try to retrieve the latest Visual Studio installation and retrieve the tools from there.
This enables to build SDL without additional steps other than installing Visual Studio with the C++ workload (this helps debugging this repository and the native backend).
The way it retrieves the VS installation is kind of convoluted, but comes from what MS does to retrieve it (because it turns out finding recent VS installs is not as trivial as querying a register key; this method is the robust one).