Merge pull request #350 from 4jcraft/fix/revert-ci

revert CI
This commit is contained in:
Tropical 2026-03-29 23:02:43 -05:00 committed by GitHub
commit 2c72e3de6d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -22,17 +22,58 @@ on:
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install Nix
uses: cachix/install-nix-action@v31
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y build-essential ccache python3 python3-pip ninja-build libsdl2-dev libgl-dev libglu1-mesa-dev libpthread-stubs0-dev libglm-dev
python -m pip install meson
# Set a reasonable ccache size
ccache -M 5G || true
python -m pip install meson
- name: Restore ccache
uses: actions/cache@v4
with:
nix_path: nixpkgs=channel:nixos-unstable
path: ~/.ccache
key: ${{ runner.os }}-ccache-${{ hashFiles('**/meson.build') }}
- name: Build
run: nix build --print-build-logs
- name: Restore meson cache
uses: actions/cache@v4
with:
path: ~/.cache/meson
key: ${{ runner.os }}-meson-${{ hashFiles('**/meson.build') }}
- name: Flake integrity
run: nix flake check
- name: Configure Meson
env:
CC: "ccache clang"
CXX: "ccache clang++"
CCACHE_DIR: ${{ runner.temp }}/ccache
run: |
mkdir -p "$CCACHE_DIR"
export CCACHE_DIR="$CCACHE_DIR"
meson setup build --wipe --native-file=./scripts/llvm_native.txt
- name: Build with Meson
env:
CC: "ccache clang"
CXX: "ccache clang++"
CCACHE_DIR: ${{ runner.temp }}/ccache
run: |
export CCACHE_DIR="${{ runner.temp }}/ccache"
# Use all available cores for faster parallel builds
meson compile -C build -j $(nproc) -v Minecraft.Client
- name: Install patchelf
run: sudo apt-get install -y patchelf
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: minecraft-client-linux-${{ github.sha }}
path: build/Minecraft.Client/Minecraft.Client
retention-days: 7