-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: add Windows builds using MinGW toolchain
This commit implements Windows testing and builds using MinGW toolchain. Some details about the implementation: - DLLs are built within CI from Microsoft's vcpkg repository as it appears to be the most reliable source for pinned versions out there. - MinGW toolchain comes from https://github.com/niXman/mingw-builds-binaries as they provide a toolchain with little to no extras, reducing variables and binary surface in our builds. This toolchain targets UCRT runtime, which is bundled with Windows 10 and above.
- Loading branch information
Showing
2 changed files
with
96 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Setup MinGW environment | ||
description: Download and setup MinGW environment for Windows | ||
inputs: | ||
mingw-version: | ||
description: The release tag from niXman/mingw-builds-binaries to use | ||
required: false | ||
default: "13.2.0-rt_v11-rev1" | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- if: runner.os != 'Windows' | ||
name: Error when used on non-Windows runners | ||
run: | | ||
echo "::error::This action does not support $RUNNER_OS" | ||
exit 1 | ||
shell: bash | ||
|
||
- name: Download from niXman/mingw-builds-binaries | ||
id: download | ||
uses: robinraju/[email protected] | ||
with: | ||
repository: niXman/mingw-builds-binaries | ||
tag: ${{ inputs.mingw-version }} | ||
fileName: x86_64-*-win32-*-ucrt*.7z | ||
|
||
- name: Extract MinGW and add to PATH | ||
run: | | ||
7z x "$MINGW_ARCHIVE" | ||
echo "$RUNNER_TEMP/mingw32/bin" >> "$GITHUB_PATH" | ||
shell: bash | ||
env: | ||
MINGW_ARCHIVE: ${{ fromJson(steps.download.outputs.downloaded_files)[0] }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters