Add cmake build to CI tests

Signed-off-by: falkTX <falktx@falktx.com>
This commit is contained in:
falkTX 2023-05-24 01:38:02 +02:00
parent 7305c38cd3
commit ef009b303e
No known key found for this signature in database
GPG Key ID: CDBAA37ABC74FBA0
3 changed files with 54 additions and 3 deletions

50
.github/workflows/cmake.yml vendored Normal file
View File

@ -0,0 +1,50 @@
name: cmake
on:
push:
branches:
- '*'
pull_request:
branches:
- '*'
env:
DEBIAN_FRONTEND: noninteractive
HOMEBREW_NO_AUTO_UPDATE: 1
jobs:
macos-11:
runs-on: macos-11
steps:
- uses: actions/checkout@v3
- name: Set up dependencies
run: |
brew install cmake fluid-synth libmagic libsndfile pkg-config
- name: configure
run: cmake -S cmake -B cmake
- name: build
run: make -C cmake -j $(sysctl -n hw.logicalcpu)
ubuntu-20_04:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- name: Set up dependencies
run: |
sudo apt-get install -yqq cmake libfluidsynth-dev libmagic-dev libsndfile1-dev libx11-dev pkg-config
- name: configure
run: cmake -S cmake -B cmake
- name: build
run: make -C cmake -j $(nproc)
ubuntu-22_04:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up dependencies
run: |
sudo apt-get install -yqq cmake libfluidsynth-dev libmagic-dev libsndfile1-dev libx11-dev pkg-config
- name: configure
run: cmake -S cmake -B cmake
- name: build
run: make -C cmake -j $(nproc)

View File

@ -16,7 +16,6 @@ set_property(GLOBAL PROPERTY INTERPROCEDURAL_OPTIMIZATION TRUE)
#######################################################################################################################
# required dependencies
find_package(PkgConfig)
find_package(Threads REQUIRED)
if(NOT (APPLE OR HAIKU OR WIN32))
@ -30,6 +29,8 @@ endif()
#######################################################################################################################
# optional dependencies
find_package(PkgConfig)
if(PKGCONFIG_FOUND)
pkg_check_modules(FLUIDSYNTH IMPORTED_TARGET fluidsynth)
pkg_check_modules(SNDFILE IMPORTED_TARGET sndfile)
@ -621,7 +622,7 @@ if (APPLE)
../source/backend/plugin/CarlaPluginCLAP.cpp
../source/backend/plugin/CarlaPluginVST2.cpp
../source/backend/plugin/CarlaPluginVST3.cpp
PROPERTIES COMPILE_FLAGS -ObjC++)
PROPERTIES COMPILE_FLAGS -ObjC++)
endif()
#######################################################################################################################

View File

@ -1,4 +1,4 @@
# carla cmake build setup
# Carla cmake build setup
This directory contains a cmake build setup for a few Carla libraries and tools.
It is not meant as a stock replacement for the regular Carla build, but simply as a way to more easily integrate Carla into other projects that already use cmake.