Skip to content

Commit cb37122

Browse files
committed
Expand CI for msys2
1 parent 587cf97 commit cb37122

File tree

1 file changed

+19
-9
lines changed

1 file changed

+19
-9
lines changed

.github/workflows/windows-alt.yml

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -187,39 +187,49 @@ jobs:
187187
- name: x86_64-w64-mingw32 Build/Test
188188
run:
189189
./tests/ci/run_cross_mingw_tests.sh x86_64 w64-mingw32 "-DCMAKE_BUILD_TYPE=Release"
190-
mingw-clang:
190+
msys2:
191191
if: github.repository_owner == 'aws'
192192
runs-on: windows-latest
193+
strategy:
194+
fail-fast: false
195+
matrix:
196+
include:
197+
- { sys: mingw64 }
198+
- { sys: ucrt64 }
199+
- { sys: clang64 }
193200
steps:
194201
- name: Install MSYS2
195202
uses: msys2/setup-msys2@v2
196203
id: setup_msys2
197204
with:
198-
msystem: CLANG64 # x86_64 clang-based environment
205+
msystem: ${{ matrix.sys }}
199206
update: true
200207
pacboy: >-
201-
clang
208+
toolchain
209+
cmake
210+
ninja
211+
cc
202212
nasm
203213
go
204214
- name: Update Environment
205215
shell: bash
206216
run: |
207-
echo "GOPATH=${{ steps.setup_msys2.outputs.msys2-location }}\clang64" >> $GITHUB_ENV
208-
echo "GOROOT=${{ steps.setup_msys2.outputs.msys2-location }}\clang64\lib\go" >> $GITHUB_ENV
209-
echo "${{ steps.setup_msys2.outputs.msys2-location }}\clang64\bin" >> $GITHUB_PATH
217+
SYSROOT=$(cygpath -a -m '${{ steps.setup_msys2.outputs.msys2-location }}\${{ matrix.sys }}')
218+
echo "GOPATH=${SYSROOT}" >> $GITHUB_ENV
219+
echo "GOROOT=${SYSROOT}/lib/go" >> $GITHUB_ENV
220+
echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV
221+
cygpath -w ${SYSROOT}/bin >> $GITHUB_PATH
210222
- name: Checkout
211223
uses: actions/checkout@v4
212224
- name: Setup CMake
213225
uses: threeal/[email protected]
214226
with:
215227
generator: Ninja
216228
build-dir: ./build
217-
c-compiler: ${{ steps.setup_msys2.outputs.msys2-location }}\clang64\bin\clang.exe
218-
cxx-compiler: ${{ steps.setup_msys2.outputs.msys2-location }}\clang64\bin\clang++.exe
219229
options: |
220230
CMAKE_SYSTEM_NAME=Windows \
221231
CMAKE_SYSTEM_PROCESSOR=x86_64 \
222-
CMAKE_FIND_ROOT_PATH='${{ steps.setup_msys2.outputs.msys2-location }}\clang64\' \
232+
CMAKE_FIND_ROOT_PATH='${{ steps.setup_msys2.outputs.msys2-location }}\${{ matrix.sys }}\' \
223233
CMAKE_FIND_ROOT_PATH_MODE_PROGRAM=NEVER \
224234
CMAKE_FIND_ROOT_PATH_MODE_LIBRARY=ONLY \
225235
CMAKE_FIND_ROOT_PATH_MODE_INCLUDE=ONLY \

0 commit comments

Comments
 (0)