mstorsjo / msvc-wine

Scripts for setting up and running MSVC in Wine on Linux
Other
684 stars 83 forks source link

Allow to use vsdownload on Windows #59

Closed glandium closed 1 year ago

glandium commented 1 year ago

The script can actually be useful to download VS on Windows too. When doing so, use the Windows-native msiexec tool to extract the MSIs, instead of msiextract.

And because of how open files are handled on Windows, use a context manager for the subprocess.check_call output, so that if it throws an exception, the file is not left open.

glandium commented 1 year ago

I presume the usecase is that this is faster and/or more customizable than using the build tools installer?

Yes, we're planning to use this to bootstrap the bits of VS required to build Firefox. We already use the script for cross compilation on CI, but we're going to use it for builds on developer machines, including Windows.

mstorsjo commented 1 year ago

LGTM, thanks for your contribution! And it's nice to hear that you've found this useful enough for Firefox builds :-)