Skip to content
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

setup windows builds on GitHub Actions #3969

Merged
merged 1 commit into from
Dec 20, 2019

Conversation

calebcartwright
Copy link
Member

I've been meaning to try out GitHub Actions (GHA) for a while, and I also feel like the AppVeyor jobs for rustfmt can take a while, get backed up in a queue, etc. so figured I'd try setting up windows jobs for rustfmt on GHA.

If folks are interested in giving GHA a try, my suggestion would be that we enable GHA alongside the current AppVeyor jobs for a trial period, and if it works well then we can disable the AppVeyor jobs later on.

The main benefits I see for using GHA:

  • faster builds/parallelization - AppVeyor only supports running 1 job at a time, resulting in a sequential execution of the channel/target combinations whereas GHA allows for running jobs in parallel. The result is that for rustfmt, AppVeyor takes 20+ minutes to complete whereas GHA will only take ~6-7 minutes (which will likely get faster in the future, details below)
  • inline within GitHub - just a bit easier/less context switching to have the CI right inline

One challenge I encountered while working on this was for the nightly-i686-pc-windows-gnu triple. However, after a chat in Discord earlier with @kinnison (thanks!) I realized that GHA does not (yet) have all the same pre-installed software that AppVeyor does: notably GHA is missing msys/mingw32.

GHA is likely to add msys2 to the pre-installed software set on the Windows runners, but in the interim, I added an extra step to work around that for the i686-pc-windows-gnu target which adds a 1 minute or so to the total build time (so the builds will presumably be a bit faster once msys2 is pre-isntalled)

@topecongiro
Copy link
Contributor

Excellent, thank you! I will keep both AppVeyor and GitHub Actions for a while and see if the latter is as stable as the former. If @calebcartwright is interested, you are more than welcome to go ahead and try GHA on other platforms as well! I would be happy to replace Travis+AppVeyor with GHA if it supports running Rust tests in all three platforms without any problem.

@topecongiro topecongiro merged commit 1e04b5e into rust-lang:master Dec 20, 2019
@calebcartwright
Copy link
Member Author

If @calebcartwright is interested, you are more than welcome to go ahead and try GHA on other platforms as well! I would be happy to replace Travis+AppVeyor with GHA if it supports running Rust tests in all three platforms without any problem

Will do! I'm fairly confident it's possible from a technical standpoint, just a matter of figuring out the right yaml incantations and ensuring the runners have everything they need.

May be a little while before I can get back around to GHA though. I started taking a look at #3903 to update the rustc-ap-* versions which is a bit of a mess (the visibility issues seem to have been resolved but the parser and session mods have been extracted from libsyntax into new, separate crates and so far it doesn't look like the parser is available in any of the latest rustc-ap-* crates 😢) and after that I was probably going to work on #3930

@calebcartwright calebcartwright deleted the gh-actions branch December 20, 2019 03:12
@topecongiro
Copy link
Contributor

I started taking a look at #3903

Great to hear that, thank you so much! I went ahead and assigned you in #3903 so that any effort won't be duplicated, as you may have already gone through, tackling this issue could be time-consuming. If you find any trouble, feel free to ask questions on GitHub or Discord (I will try to be available on Discord, but it would be helpful if you could mention me so that I could notice!)

the parser and session mods have been extracted from libsyntax into new, separate crates and so far it doesn't look like the parser is available in any of the latest rustc-ap-* crates

Hmm, so it looks like we need to ask rustc devs for updating the logic around choosing which rustc crates to publish as rustc-ap-* on crates.io. AFAIK it is managed by @alexcrichton in /~https://github.com/alexcrichton/rustc-auto-publish?

@calebcartwright
Copy link
Member Author

SGTM!

@karyon
Copy link
Contributor

karyon commented Oct 26, 2021

backported in #4436

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.

3 participants