Skip to content

Commit

Permalink
refactor: Improve CI
Browse files Browse the repository at this point in the history
Enable fail fast
Normalize install package list
Bump checkout action version
Fix macOS capitalization
Add workflow dispatch
  • Loading branch information
uyjulian committed Nov 25, 2023
1 parent 4241ba9 commit 732769f
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions .github/workflows/compilation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,42 +5,51 @@ on:
pull_request:
repository_dispatch:
types: [run_build]
workflow_dispatch: {}

jobs:
build:
runs-on: ${{ matrix.os[0] }}
strategy:
matrix:
os: [[macos-latest, bash], [ubuntu-latest, bash], [windows-latest, msys2]]
fail-fast: false
defaults:
run:
shell: ${{ matrix.os[1] }} {0}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Install Ubuntu texinfo bison flex
- name: Install Ubuntu packages
if: matrix.os[0] == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get -y install texinfo bison flex gettext libgmp3-dev libmpfr-dev libmpc-dev
echo "MSYSTEM=x64" >> $GITHUB_ENV
- name: Install Mac texinfo bison flex
if: matrix.os[0] == 'macOS-latest'
- name: Install macOS packages
if: matrix.os[0] == 'macos-latest'
run: |
brew update
brew install texinfo bison flex gnu-sed gsl gmp mpfr libmpc
echo "MSYSTEM=x64" >> $GITHUB_ENV
- name: Install MSYS2 texinfo bison flex
- name: Install MSYS2 packages
if: matrix.os[0] == 'windows-latest'
uses: msys2/setup-msys2@v2
with:
msystem: MINGW32
install: base-devel git make texinfo flex bison patch binutils mingw-w64-i686-gcc mpc-devel
install: |
base-devel git make texinfo flex bison patch binutils mingw-w64-i686-gcc mpc-devel tar
mingw-w64-i686-cmake mingw-w64-i686-extra-cmake-modules mingw-w64-i686-make mingw-w64-i686-libogg
update: true
shell: msys2 {0}

- name: Runs all the stages in the shell
continue-on-error: false
run: |
export PS2DEV=$PWD/ps2dev
export PS2SDK=$PS2DEV/ps2sdk
Expand Down

0 comments on commit 732769f

Please sign in to comment.