Skip to content
Closed
Show file tree
Hide file tree
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
23 changes: 23 additions & 0 deletions .github/workflows/build_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,29 @@ jobs:
cmake --build "${{ github.workspace }}/cmake-build" --config "Debug" --target install
cmake --build "${{ github.workspace }}/cmake-build" --config "Release" --target install

- name: Check Installed Headers Compile Cleanly
run: |
mkdir -p header-check
cat <<EOF > header-check/CMakeLists.txt
cmake_minimum_required(VERSION 3.15)
project(HeaderCheck C)

set(PROJECTM_INCLUDE_DIR "${{ github.workspace }}/install/include")
file(GLOB_RECURSE PUBLIC_HEADERS "\${PROJECTM_INCLUDE_DIR}/*.h")

foreach(header IN LISTS PUBLIC_HEADERS)
file(RELATIVE_PATH header_rel "\${PROJECTM_INCLUDE_DIR}" "\${header}")
string(MAKE_C_IDENTIFIER "\${header_rel}" safe_name)
set(test_source "\${CMAKE_BINARY_DIR}/check_\${safe_name}.c")
file(WRITE "\${test_source}" "#include <\${header_rel}>\nint main(void){return 0;}\n")
add_executable("check_\${safe_name}" "\${test_source}")
target_include_directories("check_\${safe_name}" PRIVATE "\${PROJECTM_INCLUDE_DIR}")
endforeach()
EOF

cmake -S header-check -B header-check/build -DCMAKE_C_STANDARD=99
cmake --build header-check/build --parallel

- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
Expand Down
1 change: 1 addition & 0 deletions src/playlist/api/projectM-4/playlist_callbacks.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

#include "projectM-4/playlist_types.h"
#include <stdint.h>
#include <stdbool.h>

#ifdef __cplusplus
extern "C" {
Expand Down
Loading