Environment Updates #51
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: Checks | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
jobs: | |
BuildWindows: | |
runs-on: windows-latest | |
name: Build Windows | |
strategy: | |
fail-fast: false | |
matrix: | |
build_type: [RelWithDebInfo] | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: Install clang | |
uses: msys2/setup-msys2@v2 | |
with: | |
location: D:\ | |
update: true | |
install: >- | |
mingw-w64-clang-x86_64-clang | |
mingw-w64-clang-x86_64-ninja | |
- name: Add msys to path | |
run: | | |
echo "D:\msys64\clang64\bin\" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8 | |
- name: Build | |
uses: threeal/[email protected] | |
with: | |
source-dir: ${{ github.workspace }} | |
build-dir: ${{ github.workspace }}/build | |
generator: Ninja | |
cxx-compiler: clang++ | |
c-compiler: clang | |
build-args: --target DummyEditor --parallel 16 --config ${{ matrix.build_type }} | |
options: CMAKE_BUILD_TYPE=${{ matrix.build_type }} DE_FORCE_NO_PCH=ON | |
BuildUbuntu: | |
runs-on: ubuntu-latest | |
name: Build Ubuntu | |
strategy: | |
fail-fast: false | |
matrix: | |
build_type: [RelWithDebInfo] | |
c_compiler: [clang-19] | |
cpp_compiler: [clang++-19] | |
steps: | |
- name: Install Packages | |
run: | | |
sudo apt update | |
sudo apt install libwayland-dev libxkbcommon-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libgtk-3-dev ninja-build | |
wget https://apt.llvm.org/llvm.sh | |
chmod +x llvm.sh | |
sudo ./llvm.sh 19 all | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: Build | |
uses: threeal/[email protected] | |
with: | |
source-dir: ${{ github.workspace }} | |
build-dir: ${{ github.workspace }}/build | |
generator: Ninja | |
cxx-compiler: ${{ matrix.cpp_compiler }} | |
c-compiler: ${{ matrix.c_compiler }} | |
build-args: --target DummyEditor --parallel 16 --config ${{ matrix.build_type }} | |
options: CMAKE_BUILD_TYPE=${{ matrix.build_type }} DE_FORCE_NO_PCH=ON | |
Linter: | |
runs-on: ubuntu-latest | |
name: Clang Tidy | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: Install Packages | |
run: | | |
sudo apt update | |
sudo apt install libwayland-dev libxkbcommon-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libgtk-3-dev | |
wget https://apt.llvm.org/llvm.sh | |
chmod +x llvm.sh | |
sudo ./llvm.sh 19 all | |
- name: Configure Cmake | |
uses: threeal/[email protected] | |
with: | |
source-dir: ${{ github.workspace }} | |
build-dir: ${{ github.workspace }}/build | |
generator: Unix Makefiles | |
cxx-compiler: clang++-19 | |
c-compiler: clang-19 | |
options: CMAKE_BUILD_TYPE=RelWithDebInfo CMAKE_EXPORT_COMPILE_COMMANDS=ON DE_FORCE_NO_PCH=ON | |
run-build: false | |
- uses: cpp-linter/cpp-linter-action@v2 | |
id: linter | |
with: | |
style: 'file' | |
tidy-checks: '' | |
verbosity: info | |
version: 18 | |
files-changed-only: false | |
database: '${{ github.workspace }}/build' | |
repo-root: '${{ github.workspace }}' | |
ignore: 'build/**|Examples/**|Sandbox/**|DummyEngine/Platform/**' | |
step-summary: true | |
- name: Check Linter Results | |
if: steps.linter.outputs.checks-failed > 0 | |
run: exit 1 |