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

Add getmingw, a tool to get/use MinGW builds #95

Merged
merged 4 commits into from
Dec 19, 2023
Merged

Conversation

dagood
Copy link
Member

@dagood dagood commented Dec 12, 2023

The main goals of this tool are:

  • Get MinGW builds in a repeatable way.
  • Run the same command against multiple builds of MinGW to check for problems.
  • Enable quick setup on a new machine and allow broad reuse. I think Go CLIs are good at this.

There are a few real-world situations that came up recently where this could be useful:

  • Add Windows 2019 test builders to CI go#1085
    • Setting up our own Windows CI to run Go tests against multiple MinGW builds. We can establish a compatibility matrix and a known way to securely acquire and set up the builds we test against in both AzDO and GitHub Actions.
    • Having a tool to run in CI to inspect PATH, gcc/clang version, etc. without manual work each time may help figure out why (e.g.) Chocolatey changes aren't having any effect in a particular CI system.
  • Diagnosing problems reported upstream with specific MinGW build configurations and confirming they're fixed across multiple versions.
  • Helping our internal partners.
    • Mingw erros with specific golang versions go#1081 is specific to an old build of MinGW on win2019, and this tool lets me test the scenario against many other MinGW versions without manually manipulating PATH repeatedly.
      To try it out remotely (e.g. on a fresh VM that needs MinGWs):
$env:GOPROXY = 'direct'
go install github.com/microsoft/go-infra/cmd/getmingw@dev/dagood/mingw-dl

getmingw run -source nixman -version 13.2.0-rt_v11-rev0 -arch x86_64 -threading posix -runtime msvcrt -- go test runtime/race -race

@dagood dagood requested a review from a team as a code owner December 12, 2023 06:35
@dagood dagood merged commit f2e20f3 into main Dec 19, 2023
@dagood dagood deleted the dev/dagood/mingw-dl branch December 19, 2023 22:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants