Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
97 changes: 97 additions & 0 deletions .github/workflows/linux_build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
name: 🐧 Linux Builds

on:
push:
branches:
- '**'
pull_request:
branches:
- '**'

jobs:
build-linux:
runs-on: ubuntu-24.04

steps:
- name: Checkout Source Code
uses: actions/checkout@v4
with:
submodules: recursive

Comment thread
coderabbitai[bot] marked this conversation as resolved.
- name: Set up Clang Compiler
uses: egor-tensin/setup-clang@v1
Comment thread
AR-DEV-1 marked this conversation as resolved.
with:
version: 20

- name: Install System Dependencies
run: |
wget https://github.com/Kitware/CMake/releases/download/v4.3.0/cmake-4.3.0-linux-x86_64.tar.gz
tar -xzf cmake-4.3.0-linux-x86_64.tar.gz
echo "$(pwd)/cmake-4.3.0-linux-x86_64/bin" >> $GITHUB_PATH
Comment thread
coderabbitai[bot] marked this conversation as resolved.

sudo apt-get update
sudo apt-get install -y \
ninja-build \
ccache \
llvm-20 \
llvm-20-tools \
clang-tools-20 \
libc++-20-dev \
libc++abi-20-dev \
libgl1-mesa-dev \
libegl1-mesa-dev \
libwayland-egl1-mesa \
libasound2-dev \
libpulse-dev \
libwayland-dev \
libx11-dev \
libxext-dev \
libxrender-dev \
libxrandr-dev \
libxinerama-dev \
libxcursor-dev \
libxi-dev \
libxtst-dev
echo "/usr/lib/llvm-20/bin" >> $GITHUB_PATH

- name: Verify LLVM Toolchain
run: |
which clang
which clang++
which clang-scan-deps
clang --version
clang++ --version
clang-scan-deps --version

- name: Cache Build Artifacts
uses: hendrikmuhs/ccache-action@v1.2
with:
key: ${{ runner.os }}-ccache-${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }}
restore-keys: |
${{ runner.os }}-ccache-
max-size: "500M"

- name: Configure Build System
run: |
cmake --preset debug \
-B build/debug \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_BUILD_WITH_INSTALL_RPATH=TRUE \
-DCMAKE_INSTALL_RPATH="\$ORIGIN:\$ORIGIN/engine/native"
Comment thread
OldDev78 marked this conversation as resolved.
Comment thread
OldDev78 marked this conversation as resolved.

- name: Compile Target Binary
run: |
cmake --build build/debug -j$(nproc)
Comment thread
OldDev78 marked this conversation as resolved.

- name: Run Unit Tests
run: |
ctest --test-dir build/debug --output-on-failure -j$(nproc)

- name: Upload Engine Artifact
uses: actions/upload-artifact@v4
with:
name: linux_debug
path: build/debug/
if-no-files-found: error
retention-days: 7