Compare commits

...

16 commits

Author SHA1 Message Date
92b604fac3
Merge branch 'actions'
Some checks failed
Build / Format (push) Failing after 21s
Build / Lint (push) Successful in 1m38s
Build / Build (push) Successful in 38s
2025-02-23 13:31:55 -05:00
e53cc64dc9
Fix typo in CMake cache
Some checks failed
Build / Format (push) Failing after 19s
Build / Lint (push) Successful in 1m37s
Build / Build (push) Successful in 38s
2025-02-23 13:25:38 -05:00
5d1ca28978
Add linting via clang-tidy
Some checks failed
Build / Format (push) Failing after 20s
Build / Lint (push) Failing after 1m13s
Build / Build (push) Successful in 36s
2025-02-23 13:23:20 -05:00
7f987925b1
Fix executable name for real this time
Some checks failed
Build / Format (push) Failing after 21s
Build / Build (push) Successful in 38s
2025-02-23 12:58:58 -05:00
344de31b81
Re-enable formatting check
Some checks failed
Build / Format (push) Failing after 21s
Build / Build (push) Successful in 37s
2025-02-23 12:57:03 -05:00
dbc75c9958
Fix executable location 2025-02-23 12:56:29 -05:00
5675fea9de
Add a GLUT package that will hopefully be there
All checks were successful
Build / Build (push) Successful in 38s
2025-02-23 12:54:35 -05:00
2be2eac1ea
Remove libglut from the image installation
Some checks failed
Build / Build (push) Failing after 33s
2025-02-23 12:52:31 -05:00
0475c9ef93
Temporarily disable format check for brevity 2025-02-23 12:52:01 -05:00
9050410879
Add more headers
Some checks failed
Build / Format (push) Failing after 21s
Build / Build (push) Failing after 14s
2025-02-23 12:48:44 -05:00
ef07346fea
Add code formatting check
Some checks failed
Build / Format (push) Failing after 21s
Build / Build (push) Failing after 18s
2025-02-23 12:44:07 -05:00
0d79d17738
Add GLM headers to build action 2025-02-23 12:43:24 -05:00
4f4266327f
Reduce minimum required CMake version
Some checks failed
Build / Build (push) Failing after 19s
2025-02-23 12:08:11 -05:00
1e601da194
Install CMake for build
Some checks failed
Build / Build (push) Failing after 19s
2025-02-23 12:04:52 -05:00
f9c2ad3587
Fix typo
Some checks failed
Build / Build (push) Failing after 7s
2025-02-23 12:02:30 -05:00
641850eb50
Add draft of build action
Some checks failed
Build / Build (push) Failing after 3s
2025-02-23 11:58:07 -05:00
2 changed files with 55 additions and 2 deletions

View file

@ -0,0 +1,53 @@
---
on: [push]
name: Build
jobs:
format:
name: Format
runs-on: ubuntu-22.04
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Install clang-format
run: |
sudo apt-get update
sudo apt-get -y install clang-format
- name: Check the code's formatting
run: clang-format --dry-run src/*.h src/*.cpp 2>&1 | tee fmt.log; [ ! -s fmt.log ]
lint:
name: Lint
runs-on: ubuntu-22.04
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Install clang-tidy and the toolchain
run: |
sudo apt-get update
sudo apt-get -y install clang-tidy cmake freeglut3-dev libglew-dev libglm-dev
- name: Set up the build environment
run: cmake -S . -B cmake-build-debug -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- name: Have clang-tidy lint for errors
run: clang-tidy -p cmake-build-debug src/*.cpp src/*.h --warnings-as-errors='*'
build:
name: Build
runs-on: ubuntu-22.04
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Install the toolchain
run: |
sudo apt-get update
sudo apt-get -y install cmake freeglut3-dev libglew-dev libglm-dev
- name: Set up the build environment
run: cmake -S . -B cmake-build-debug
- name: Compile the code
run: cmake --build cmake-build-debug
- name: Save executable
uses: forgejo/upload-artifact@v4
with:
name: bin.zip
path: cmake-build-debug/perlin-shadows

View file

@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.27)
cmake_minimum_required(VERSION 3.22)
project(perlin-shadows)
set(CMAKE_CXX_STANDARD 14)
@ -36,4 +36,4 @@ file(READ src/shadow.frag SHADOW_FRAG)
file(READ src/shadow.geom SHADOW_GEOM)
configure_file(src/point_light.in.h src/point_light.h @ONLY)
target_include_directories(perlin-shadows PUBLIC "${CMAKE_CURRENT_BINARY_DIR}/src")
target_include_directories(perlin-shadows PUBLIC "${CMAKE_CURRENT_BINARY_DIR}/src")