Skip to content

Commit c956ea3

Browse files
committed
GH Actions fixes
1 parent 2373129 commit c956ea3

File tree

4 files changed

+27
-7
lines changed

4 files changed

+27
-7
lines changed

.github/workflows/build.yml

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ jobs:
2323
#
2424
# To add more build types (Release, Debug, RelWithDebInfo, etc.) customize the build_type list.
2525
matrix:
26-
os: [ubuntu-latest, windows-latest]
26+
os: [ubuntu-latest, windows-latest, macos-latest]
2727
build_type: [Release]
28-
c_compiler: [gcc, clang, cl]
28+
#c_compiler: [gcc, clang, cl]
2929
include:
3030
- os: windows-latest
3131
c_compiler: cl
@@ -36,13 +36,16 @@ jobs:
3636
- os: ubuntu-latest
3737
c_compiler: clang
3838
cpp_compiler: clang++
39+
- os: macos-latest
40+
c_compiler: clang
41+
cpp_compiler: clang++
3942
exclude:
4043
- os: windows-latest
4144
c_compiler: gcc
4245
- os: windows-latest
4346
c_compiler: clang
44-
- os: ubuntu-latest
45-
c_compiler: cl
47+
- os: macos-latest
48+
c_compiler: gcc
4649

4750
steps:
4851
- uses: actions/checkout@v4
@@ -54,8 +57,14 @@ jobs:
5457
run: |
5558
echo "build-output-dir=${{ github.workspace }}/build" >> "$GITHUB_OUTPUT"
5659
57-
- name: Install opengl
58-
run: vcpkg install opengl
60+
- name: Install dependencies on Ubuntu
61+
if: runner.os == 'Linux'
62+
run: >
63+
sudo apt-get update && sudo apt-get install -y libgl1-mesa-dev
64+
xorg-dev libblocksruntime-dev
65+
66+
- name: CMake Version
67+
run: cmake --version
5968

6069
- name: Configure CMake
6170
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ endif()
3939

4040
if(CMAKE_C_COMPILER_ID STREQUAL "Clang")
4141
option(FORCE_CLANG_BLOCKS "Force enable Clang blocks" YES)
42+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-nan-infinity-disabled")
4243
endif()
4344

4445
# sanity checks...

VERSION.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ What's new in NEXT:
1616
* BUG: Fixes bug in cpSpaceShapeQuery to not miss collisions (by alanmillard)
1717
* BUG: Fix for cpSpaceShapeQuery using cpSegmentShape with null body (by maniek2332)
1818
* MISC: Fix spelling of positive (by skitt)
19-
19+
* MISC: Github actions that build on Windows/Linux/MacOS with MSVC/GCC/CLang
20+
* MISC: Fix warning for INFINITY on CLang 18+
2021

2122

2223
What's new in 7.0.3:

demo/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,15 @@ if(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
3838
list(APPEND chipmunk_demos_libraries BlocksRuntime)
3939
endif(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD")
4040

41+
42+
43+
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
44+
if(CMAKE_C_COMPILER_ID STREQUAL "Clang")
45+
list(APPEND chipmunk_demos_libraries BlocksRuntime)
46+
endif()
47+
endif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
48+
49+
4150
include_directories(${chipmunk_demos_include_dirs})
4251
link_directories(${chipmunk_demos_library_dirs})
4352
add_executable(chipmunk_demos ${chipmunk_demos_source_files})

0 commit comments

Comments
 (0)