-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a Consolidated JUCE plugin side by side with Rack (#30)
With optional build etc...
- Loading branch information
Showing
20 changed files
with
3,925 additions
and
124 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: Build DAW Plugin | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- 'releases/**' | ||
tags: | ||
- 'v**' | ||
pull_request: | ||
workflow_dispatch: | ||
workflow_run: | ||
workflows: ["Update"] | ||
types: | ||
- completed | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
build_plugin: | ||
name: DAW Build - ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
include: | ||
- os: windows-latest | ||
- os: macos-latest | ||
- os: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Install Linux Deps; pick GCC9 | ||
if: runner.os == 'Linux' | ||
run: | | ||
sudo apt-get update | ||
sudo apt install libasound2-dev libx11-dev libxcomposite-dev libxcursor-dev libxext-dev libxinerama-dev libxrandr-dev libxrender-dev libfreetype6-dev libglu1-mesa-dev libjack-jackd2-dev | ||
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 12 | ||
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-12 12 | ||
- name: Build project | ||
run: | | ||
cmake -S . -B ./build -DCMAKE_BUILD_TYPE=Release -DCMAKE_OSX_ARCHITECTURES="arm64;x86_64" -DBUILD_JUCE_PLUGIN=TRUE | ||
cmake --build ./build --config Release --target awcons-installer | ||
- name: Show Build Directory | ||
run: | | ||
ls -l ./build | ||
- name: Show Installer Directory | ||
run: | | ||
ls -l ./build/installer | ||
- name: Upload artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
path: build/installer | ||
name: dawplugin-${{ matrix.os }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,79 @@ | ||
cmake_minimum_required(VERSION 3.16) | ||
cmake_policy(SET CMP0091 NEW) | ||
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.9" CACHE STRING "Minimum OS X deployment version") | ||
set(CMAKE_POSITION_INDEPENDENT_CODE ON) | ||
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>") | ||
|
||
project(Airwin2Rack VERSION 1.0 LANGUAGES C CXX) | ||
|
||
set(CMAKE_CXX_STANDARD 17) | ||
set(CMAKE_EXPORT_COMPILE_COMMANDS ON) | ||
set(CMAKE_CXX_VISIBILITY_PRESET hidden) | ||
set(CMAKE_VISIBILITY_INLINES_HIDDEN ON) | ||
|
||
add_subdirectory(libs/sst-rackhelpers) | ||
|
||
set(PLUGIN_NAME ${PROJECT_NAME}) | ||
set(ADDITIONAL_PLUGIN_DISTRIBUTABLES res LICENSE.md README.md) | ||
include(RackSDK.cmake) | ||
option(BUILD_JUCE_PLUGIN "Build a JUCE plugin" OFF) | ||
option(BUILD_RACK_PLUGIN "Build a VCV Rack plugin" OFF) | ||
|
||
message(STATUS "AirwinRackAdapter for Rack Build Process" ) | ||
message(STATUS "Installing into '${CMAKE_INSTALL_PREFIX}'") | ||
|
||
include(src/autogen_airwin/CMakeLists.txt) | ||
add_compile_options(-fvisibility=hidden -fvisibility-inlines-hidden) | ||
|
||
target_include_directories(${RACK_PLUGIN_LIB} PRIVATE src src/autogen_airwin/) | ||
target_sources(${RACK_PLUGIN_LIB} PRIVATE | ||
src/Airwin2Rack.cpp | ||
if(NOT MSVC) | ||
message(STATUS "Adding clang/gcc visibility options") | ||
add_compile_options(-fvisibility=hidden -fvisibility-inlines-hidden) | ||
endif() | ||
|
||
add_library(airwin-registry STATIC | ||
src/AirwinRegistry.cpp | ||
src/Module.cpp | ||
src/airwin2rackbase.cpp | ||
|
||
${AIRWIN_SOURCES} | ||
) | ||
${AIRWIN_SOURCES}) | ||
|
||
target_compile_definitions(airwin-registry PRIVATE _USE_MATH_DEFINES) | ||
|
||
if (NOT MSVC) | ||
# consistent even in warnings that chris is | ||
target_compile_options(airwin-registry PRIVATE | ||
-Wno-unused-function | ||
-Wno-unused-value | ||
-Wno-unused-but-set-variable | ||
-Wno-multichar | ||
) | ||
endif() | ||
target_include_directories(airwin-registry PUBLIC src) | ||
|
||
if (${BUILD_RACK_PLUGIN}) | ||
set(PLUGIN_NAME ${PROJECT_NAME}) | ||
set(ADDITIONAL_PLUGIN_DISTRIBUTABLES res LICENSE.md README.md) | ||
include(RackSDK.cmake) | ||
|
||
add_subdirectory(libs/sst-rackhelpers) | ||
|
||
target_include_directories(${RACK_PLUGIN_LIB} PRIVATE src src/autogen_airwin/) | ||
target_sources(${RACK_PLUGIN_LIB} PRIVATE | ||
src/Airwin2Rack.cpp | ||
src/Module.cpp | ||
) | ||
|
||
target_compile_options(${RACK_PLUGIN_LIB} PUBLIC -Wno-suggest-override -Wno-multichar -Wno-unused-value -Wno-unused-but-set-variable -Wno-unused-variable ) | ||
target_link_libraries(${RACK_PLUGIN_LIB} PUBLIC sst-rackhelpers) | ||
target_compile_options(${RACK_PLUGIN_LIB} PUBLIC -Wno-suggest-override -Wno-multichar -Wno-unused-value -Wno-unused-but-set-variable -Wno-unused-variable ) | ||
target_link_libraries(${RACK_PLUGIN_LIB} PUBLIC sst-rackhelpers airwin-registry) | ||
|
||
if(CMAKE_CXX_COMPILER_ID MATCHES "GNU") | ||
target_compile_options(${RACK_PLUGIN_LIB} PUBLIC -Wno-stringop-truncation) | ||
if(CMAKE_CXX_COMPILER_ID MATCHES "GNU") | ||
target_compile_options(${RACK_PLUGIN_LIB} PUBLIC -Wno-stringop-truncation) | ||
endif() | ||
endif() | ||
|
||
if (${BUILD_JUCE_PLUGIN}) | ||
|
||
file(GLOB AWCON_RESOURCES_GLOB | ||
res/*.ttf | ||
res/clipper.svg | ||
res/awpdoc/*.txt | ||
) | ||
include(cmake/CmakeRC.cmake) | ||
cmrc_add_resource_library(awconsolidated_resources ${AWCON_RESOURCES_GLOB}) | ||
|
||
add_subdirectory(src-juce) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# SPDX-License-Identifier: MIT | ||
# | ||
# SPDX-FileCopyrightText: Copyright (c) 2019-2023 Lars Melchior and contributors | ||
|
||
set(CPM_DOWNLOAD_VERSION 0.38.6) | ||
set(CPM_HASH_SUM "11c3fa5f1ba14f15d31c2fb63dbc8628ee133d81c8d764caad9a8db9e0bacb07") | ||
|
||
if(CPM_SOURCE_CACHE) | ||
set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") | ||
elseif(DEFINED ENV{CPM_SOURCE_CACHE}) | ||
set(CPM_DOWNLOAD_LOCATION "$ENV{CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") | ||
else() | ||
set(CPM_DOWNLOAD_LOCATION "${CMAKE_BINARY_DIR}/cmake/CPM_${CPM_DOWNLOAD_VERSION}.cmake") | ||
endif() | ||
|
||
# Expand relative path. This is important if the provided path contains a tilde (~) | ||
get_filename_component(CPM_DOWNLOAD_LOCATION ${CPM_DOWNLOAD_LOCATION} ABSOLUTE) | ||
|
||
file(DOWNLOAD | ||
https://github.com/cpm-cmake/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake | ||
${CPM_DOWNLOAD_LOCATION} EXPECTED_HASH SHA256=${CPM_HASH_SUM} | ||
) | ||
|
||
include(${CPM_DOWNLOAD_LOCATION}) |
Oops, something went wrong.