CI: Bump ubuntu to 22.04. #23
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: "Build" | |
on: | |
push: | |
branches: | |
- '**' | |
pull_request: | |
jobs: | |
linux: | |
name: Linux | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
include: | |
- name: arm64 | |
tool: aarch64-unknown-linux-musl | |
- name: arm32 | |
tool: arm-unknown-linux-musleabi | |
- name: arm32hf | |
tool: arm-unknown-linux-musleabihf | |
- name: arm32v7 | |
tool: armv7-unknown-linux-musleabi | |
- name: arm32v7hf | |
tool: armv7-unknown-linux-musleabihf | |
- name: loong64 | |
tool: loongarch64-unknown-linux-musl | |
- name: m68k | |
tool: m68k-unknown-linux-musl | |
- name: microblazeel | |
tool: microblazeel-xilinx-linux-musl | |
- name: microblaze | |
tool: microblaze-xilinx-linux-musl | |
- name: mips64el | |
tool: mips64el-unknown-linux-musl | |
- name: mips64 | |
tool: mips64-unknown-linux-musl | |
- name: mips32el | |
tool: mipsel-unknown-linux-musl | |
- name: mips32elsf | |
tool: mipsel-unknown-linux-muslsf | |
- name: mips32 | |
tool: mips-unknown-linux-musl | |
- name: mips32sf | |
tool: mips-unknown-linux-muslsf | |
- name: powerpc64 | |
tool: powerpc64-unknown-linux-musl | |
- name: powerpc | |
tool: powerpc-unknown-linux-musl | |
- name: riscv32 | |
tool: riscv32-unknown-linux-musl | |
- name: riscv64 | |
tool: riscv64-unknown-linux-musl | |
- name: s390x | |
tool: s390x-ibm-linux-musl | |
- name: sh | |
tool: sh-multilib-linux-musl | |
- name: sheb | |
tool: sh-multilib-linux-musl | |
env: | |
CFLAGS: "-mb" | |
- name: x86_32 | |
tool: x86_64-multilib-linux-musl | |
env: | |
CFLAGS: "-m32" | |
- name: x86_64 | |
tool: x86_64-multilib-linux-musl | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
submodules: true | |
- name: Build ${{ matrix.name }} | |
run: | | |
sudo mkdir -p /opt/x-tools | |
wget https://github.com/musl-cross/musl-cross/releases/download/20240923/${{ matrix.tool }}.tgz | |
sudo tar xf ${{ matrix.tool }}.tgz -C /opt/x-tools | |
make CROSS_PREFIX=/opt/x-tools/${{ matrix.tool }}/bin/${{ matrix.tool }}- CFLAGS=${{ matrix.env.CFLAGS }} ENABLE_STATIC=1 -j`nproc` | |
macos: | |
name: macOS | |
runs-on: macos-14 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
submodules: true | |
- name: Build native | |
run: | | |
make | |
make clean | |
- name: Build cross | |
run: | | |
./build-apple.sh | |
llvm: | |
name: LLVM | |
runs-on: ubuntu-22.04 | |
if: github.event_name != 'release' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 1 | |
submodules: true | |
- name: Prepare | |
run: | | |
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - | |
sudo add-apt-repository -y 'deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy main' | |
sudo apt install -y clang | |
- name: Build | |
run: | | |
make CC=clang ENABLE_STATIC=1 -j`nproc` |