Skip to content

Bootstrap script improvements #880

Bootstrap script improvements

Bootstrap script improvements #880

Workflow file for this run

on:
push:
branches:
- main
pull_request:
jobs:
bootstrap:
runs-on: macos-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch the whole Git history
- run: ./bootstrap.sh
- uses: actions/upload-artifact@v4
with:
name: bootstrapped
path: jou_bootstrap
test:
needs: bootstrap
runs-on: macos-latest
timeout-minutes: 10
strategy:
matrix:
llvm-version: [14, 15, 16]
# Testing all levels because there was a bug that only happened with -O1. (#224)
opt-level: ['-O0', '-O1', '-O2', '-O3']
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: bootstrapped
- run: chmod +x jou_bootstrap
- run: brew install bash diffutils llvm@${{ matrix.llvm-version }}
- name: "Select LLVM version"
run: echo "LLVM_CONFIG=/opt/homebrew/opt/llvm@${{ matrix.llvm-version }}/bin/llvm-config" >> $GITHUB_ENV
- name: "Compile and test"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }}"
- name: "Compile the compiler with itself"
run: mv jou jou_bootstrap && make
- name: "Compile and test again"
run: ./runtests.sh --verbose --jou-flags "${{ matrix.opt-level }}"
doctest:
needs: bootstrap
runs-on: macos-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: bootstrapped
- run: chmod +x jou_bootstrap
- run: brew install bash diffutils llvm@15
- run: ./doctest.sh