Restore osx build #336
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: Vcpkg build | |
on: [push] | |
jobs: | |
build: | |
name: ${{ matrix.cfg.os }} | |
runs-on: ${{ matrix.cfg.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
cfg: | |
- { os: ubuntu-latest, triplet: x64-linux } | |
- { os: windows-2022, triplet: x64-windows-static-vs2022 } | |
- { os: macos-latest, triplet: x64-osx } | |
steps: | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.x" | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
lfs: false | |
- name: Install linux dependencies | |
if: ${{ matrix.cfg.os == 'ubuntu-latest' }} | |
run: sudo apt-get install nasm openssl | |
- name: Install osx dependencies | |
if: ${{ matrix.cfg.os == 'macos-latest' }} | |
run: brew install nasm automake autoconf | |
- name: Cache vcpkg packages | |
id: cache-vcpkg | |
uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cache/vcpkg | |
~/AppData/Local/vcpkg/archives | |
key: ${{ runner.os }}-${{ matrix.cfg.triplet }}-${{ hashFiles('vcpkg.json', '.git/modules/deps/vcpkg/shallow') }} | |
- name: Bootstrap the ports | |
run: python bootstrap.py --triplet ${{ matrix.cfg.triplet }} --clean-after-build | |
- name: Install build tools | |
run: ./deps/vcpkg/vcpkg fetch ninja | |
- name: Build the code | |
run: python build.py --triplet ${{ matrix.cfg.triplet }} --run-tests --dist | |
- name: Archive build logs | |
if: ${{ failure() }} | |
uses: actions/upload-artifact@v4 | |
with: | |
name: build-logs | |
path: | | |
deps/vcpkg/buildtrees/**/config*.log | |
deps/vcpkg/buildtrees/**/build*.log | |
deps/vcpkg/buildtrees/**/install*.log | |
deps/vcpkg/buildtrees/**/package*.log | |