Experiment with alternate msys2 environments in CI workflow #226
Workflow file for this run
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
name: CI | ||
# Controls when the workflow will run | ||
on: | ||
push: | ||
pull_request: | ||
workflow_dispatch: | ||
jobs: | ||
build-test: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- runner: "ubuntu-24.04" | ||
cc: "gcc" | ||
codegen: "amd64" | ||
- runner: "ubuntu-24.04" | ||
cc: "gcc" | ||
codegen: "c" | ||
- runner: "ubuntu-24.04" | ||
cc: "clang" | ||
codegen: "amd64" | ||
- runner: "ubuntu-24.04" | ||
cc: "clang" | ||
codegen: "c" | ||
- runner: "ubuntu-24.04" | ||
cc: "clang" | ||
codegen: "llvm" | ||
- runner: "macos-13" | ||
cc: "clang" | ||
codegen: "amd64" | ||
- runner: "macos-13" | ||
cc: "clang" | ||
codegen: "c" | ||
- runner: "macos-13" | ||
cc: "clang" | ||
codegen: "llvm" | ||
- runner: "macos-14" | ||
cc: "clang" | ||
codegen: "c" | ||
- runner: "macos-14" | ||
cc: "clang" | ||
codegen: "llvm" | ||
- runner: windows-2022 | ||
msystem: mingw64 | ||
cc: "gcc" | ||
codegen: "amd64" | ||
- runner: windows-2022 | ||
msystem: mingw64 | ||
cc: "gcc" | ||
codegen: "c" | ||
- runner: windows-2022 | ||
msystem: ucrt64 | ||
cc: "gcc" | ||
codegen: "amd64" | ||
- runner: windows-2022 | ||
msystem: ucrt64 | ||
cc: "gcc" | ||
codegen: "c" | ||
- runner: windows-2022 | ||
msystem: clang64 | ||
cc: "clang" | ||
codegen: "amd64" | ||
- runner: windows-2022 | ||
msystem: clang64 | ||
cc: "clang" | ||
codegen: "c" | ||
- runner: windows-2022 | ||
msystem: clang64 | ||
cc: "clang" | ||
codegen: "llvm" | ||
runs-on: ${{ matrix.runner }} | ||
defaults: | ||
run: | ||
shell: ${{ (startsWith(matrix.runner, 'windows') && 'msys2 {0}') || 'bash' }} | ||
steps: | ||
- name: Configure git | ||
shell: bash | ||
run: git config --global core.autocrlf false | ||
- name: Install msys2 (windows) | ||
if: ${{ startsWith(matrix.runner, 'windows') }} | ||
uses: msys2/setup-msys2@v2 | ||
with: | ||
msystem: ${{ matrix.msystem }} | ||
update: false | ||
install: >- | ||
base-devel | ||
git | ||
pactoys | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Install bootstrap dependencies | ||
uses: ./.github/actions/install-bootstrap-dependencies | ||
with: | ||
runner: ${{ matrix.runner }} | ||
install-llvm: ${{ matrix.codegen == 'llvm' }} | ||
- name: Check versions | ||
run: | | ||
PATH=$(pwd)/boot/bin:$PATH mlton | ||
echo | ||
make -version | ||
echo | ||
${{ matrix.cc }} --version | ||
echo | ||
if [[ "${{ matrix.codegen }}" == "llvm" ]]; then llvm-as -version; opt -version; llc -version; fi | ||
- name: Build | ||
run: | | ||
# make all | ||
PATH=$(pwd)/boot/bin:$PATH \ | ||
make \ | ||
CC=${{ matrix.cc }} \ | ||
OLD_MLTON_RUNTIME_ARGS="ram-slop 0.90" \ | ||
MLTON_RUNTIME_ARGS="ram-slop 0.90" \ | ||
MLTON_COMPILE_ARGS="-codegen ${{ matrix.codegen }}" \ | ||
$( if [[ -n "$WITH_GMP_DIR" ]]; then echo "WITH_GMP_DIR=$WITH_GMP_DIR"; fi ) \ | ||
WITH_ALL_RUNTIME=true \ | ||
WITH_DBG_RUNTIME=false \ | ||
MLTON_BINARY_RELEASE_SUFFIX=".${{ matrix.runner }}_${{ matrix.cc }}_${{ matrix.codegen }}" \ | ||
all | ||
- name: Test | ||
run: ./bin/regression -codegen ${{ matrix.codegen }} | ||
- name: Status | ||
run: | | ||
git status | ||
- name: Package | ||
run: | | ||
Check failure on line 143 in .github/workflows/ci.yml GitHub Actions / CIInvalid workflow file
|
||
# make binary-release | ||
make \ | ||
CC=${{ matrix.cc }} \ | ||
OLD_MLTON_RUNTIME_ARGS="ram-slop 0.90" \ | ||
MLTON_RUNTIME_ARGS="ram-slop 0.90" \ | ||
MLTON_COMPILE_ARGS="-codegen ${{ matrix.codegen }}" \ | ||
$( if [[ -n "$WITH_GMP_DIR" ]]; then echo "WITH_GMP_DIR=$WITH_GMP_DIR"; fi ) \ | ||
WITH_ALL_RUNTIME=true \ | ||
WITH_DBG_RUNTIME=false \ | ||
MLTON_BINARY_RELEASE_SUFFIX=".${{ matrix.runner }}${{ matrix.msystem && format('_msys2_{0}', matrix.msystem) || "" }}_${{ matrix.cc }}_${{ matrix.codegen }}" \ | ||
binary-release | ||
- name: Upload Artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: mlton..${{ matrix.runner }}${{ matrix.msystem && format('_msys2_{0}', matrix.msystem) || "" }}_${{ matrix.cc }}_${{ matrix.codegen }} | ||
path: ./*.tgz |