Skip to content

Add FluidSyth Toolchains #96

Add FluidSyth Toolchains

Add FluidSyth Toolchains #96

Workflow file for this run

---
name: build
'on': [push, pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
linux-gcc:
name: linux-gcc
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt-get --yes install fluidsynth libfluidsynth-dev sordi gtk+2.0 libgtk2.0-dev libcairo2 lv2-dev
- name: Check out
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure
run: |
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=../install
- name: Build
run: cmake --build build
linux-clang-with-lld:
name: linux-clang-with-lld # clang with LLVM's linker LLD
runs-on: ubuntu-latest
steps:
- name: Install dependencies
run: sudo apt-get --yes install fluidsynth libfluidsynth-dev sordi gtk+2.0 libgtk2.0-dev libcairo2 lv2-dev
- name: Check out
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure
run: >
mkdir build && cd build &&
cmake ..
-DCMAKE_INSTALL_PREFIX=../install
-DCMAKE_C_COMPILER=clang
-DCMAKE_CXX_COMPILER=clang++
-DCMAKE_C_FLAGS="-fuse-ld=lld"
-DCMAKE_CXX_FLAGS="-fuse-ld=lld"
- name: Build
run: cmake --build build
macos:
name: macos
runs-on: macos-13
steps:
- name: Install dependencies
run: brew install automake fluid-synth gtk+ cairo lv2
- name: Check out
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure
run: |
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=../install
- name: Build
run: cmake --build build
# install does not work yet, but seems less critical for now
mingw-cross:
strategy:
matrix:
compiler:
- {bits: '32'}
- {bits: '64'}
name: mingw-${{matrix.compiler.bits}}-cross
runs-on: ubuntu-latest
steps:
- name: Install MinGW
run: |
sudo dpkg --add-architecture i386 # for wine32
sudo apt-get update # due to new architecture
sudo apt-get install -y mingw-w64
- name: Compile dependencies
run: |
cd /tmp
wget https://github.com/libexpat/libexpat/releases/download/R_2_5_0/expat-2.5.0.tar.bz2
tar xjf expat-2.5.0.tar.bz2
cd expat-2.5.0
./buildconf.sh
mkdir build
cd build
export CC=i686-w64-mingw32-gcc CXX=i686-w64-mingw32-g++ LD=i686-w64-mingw32-ld QA_PROCESSOR=gcov
cmake -DCMAKE_SYSTEM_NAME=Windows -DWIN32=ON -DMINGW=ON -DEXPAT_ATTR_INFO=ON ..
make VERBOSE=1 CTEST_OUTPUT_ON_FAILURE=1 all
sudo make install
cd /tmp
rm -rf /tmp/expat-2.5.0
wget https://github.com/FluidSynth/fluidsynth/archive/refs/tags/v2.3.4.tar.gz
tar xvfz v2.3.4.tar.gz
cd fluidsynth-2.3.4
mkdir build
cd build
export CC=i686-w64-mingw32-gcc CXX=i686-w64-mingw32-g++ LD=i686-w64-mingw32-ld
cmake -DCMAKE_TOOLCHAIN_FILE=../cmake/toolchains/FluidSynth-${{matrix.compiler.bits}}.cmake ..
sudo make install
- name: Install dependencies
run: |
sudo add-apt-repository ppa:tobydox/mingw-w64
sudo apt update
sudo apt-get install -y fluidsynth-mingw-w64
- name: Check out
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Configure
run: >
mkdir build && cd build &&
PATH=/opt/mingw${{matrix.compiler.bits}}/bin:$PATH
cmake ..
-DCMAKE_INSTALL_PREFIX=../install
-DCMAKE_TOOLCHAIN_FILE=../cmake/toolchains/Ubuntu-MinGW-W64-${{matrix.compiler.bits}}.cmake
-DCMAKE_PREFIX_PATH=/opt/mingw${{matrix.compiler.bits}}
- name: Build
run: cmake --build build