From 43951635e9b87048b1f4ebe7a2af40be319d7615 Mon Sep 17 00:00:00 2001 From: Filipe Coelho Date: Tue, 14 Dec 2021 22:16:37 +0000 Subject: [PATCH] Setup PawPaw and let it be used for CI extra deps (#93) * Setup PawPaw and let it be used for CI extra deps * Fix ci file * Update readme * Fix a typo * Fix another typo * Let PawPaw handle the build setup/env * Fix typo * One more fix * Update AudibleInstruments Signed-off-by: falkTX * Cleanup/Improve CardinalModuleWidget hackery Signed-off-by: falkTX * Use LTO in PawPaw, fix build setup again Signed-off-by: falkTX * Install libglib2.0-dev on CI static builds; Fix Prism conflicts Signed-off-by: falkTX * Investigate why CI fails to install arch ports Signed-off-by: falkTX * Ignore glib/fluidsynth for now Signed-off-by: falkTX * Cleanup Signed-off-by: falkTX * Fix a typo Signed-off-by: falkTX * Fix another typo Signed-off-by: falkTX * Use -m32 in linux-i686 builds Signed-off-by: falkTX * Try using g++-multilib instead of g++-i686-linux-gnu Signed-off-by: falkTX * Force fix macOS build * Use shasum5.28 --- .github/workflows/build.yml | 174 ++++++++++++--------- .gitmodules | 3 + Makefile | 5 +- README.md | 10 +- deps/Makefile | 4 + deps/PawPaw | 1 + include/app/RackWidget.hpp | 28 ---- include/plugin/Model.hpp | 29 ---- include/{app/ModuleWidget.hpp => rack.hpp} | 7 +- plugins/AudibleInstruments | 2 +- plugins/Makefile | 13 +- plugins/Prism | 2 +- src/CardinalModuleWidget.cpp | 22 +-- 13 files changed, 142 insertions(+), 158 deletions(-) create mode 160000 deps/PawPaw delete mode 100644 include/app/RackWidget.hpp delete mode 100644 include/plugin/Model.hpp rename include/{app/ModuleWidget.hpp => rack.hpp} (89%) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 561efbb..4b0c200 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,7 +10,7 @@ on: env: DEBIAN_FRONTEND: noninteractive HOMEBREW_NO_AUTO_UPDATE: 1 - LIBGL_ALWAYS_SOFTWARE: "true" + LIBGL_ALWAYS_SOFTWARE: 'true' jobs: linux-arm64: @@ -22,7 +22,11 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-linux-arm64 - name: Set up dependencies run: | @@ -32,22 +36,24 @@ jobs: echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-updates main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-arm64.list echo "deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-arm64.list sudo apt-get update -qq - sudo apt-get install -yqq g++-aarch64-linux-gnu libgl1-mesa-dev:arm64 liblo-dev:arm64 libx11-dev:arm64 libxcursor-dev:arm64 libxext-dev:arm64 libxrandr-dev:arm64 qemu-user-static + sudo apt-get install -yqq g++-aarch64-linux-gnu libdbus-1-dev:arm64 libgl1-mesa-dev:arm64 libx11-dev:arm64 libxcursor-dev:arm64 libxext-dev:arm64 libxrandr-dev:arm64 qemu-user-static - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build linux arm64 cross-compiled + - name: Build extra dependencies env: - CC: aarch64-linux-gnu-gcc - CXX: aarch64-linux-gnu-g++ - LDFLAGS: -static-libgcc -static-libstdc++ PKG_CONFIG_PATH: /usr/lib/aarch64-linux-gnu/pkgconfig run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh linux-aarch64 + - name: Build linux arm64 cross-compiled + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env linux-aarch64; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" @@ -69,7 +75,11 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-linux-armhf - name: Set up dependencies run: | @@ -79,22 +89,24 @@ jobs: echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal-updates main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-armhf.list echo "deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal-backports main restricted universe multiverse" | sudo tee -a /etc/apt/sources.list.d/ports-armhf.list sudo apt-get update -qq - sudo apt-get install -yqq g++-arm-linux-gnueabihf libgl1-mesa-dev:armhf liblo-dev:armhf libx11-dev:armhf libxcursor-dev:armhf libxext-dev:armhf libxrandr-dev:armhf qemu-user-static + sudo apt-get install -yqq g++-arm-linux-gnueabihf libdbus-1-dev:armhf libgl1-mesa-dev:armhf libx11-dev:armhf libxcursor-dev:armhf libxext-dev:armhf libxrandr-dev:armhf qemu-user-static - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build linux armhf cross-compiled + - name: Build extra dependencies env: - CC: arm-linux-gnueabihf-gcc - CXX: arm-linux-gnueabihf-g++ - LDFLAGS: -static-libgcc -static-libstdc++ PKG_CONFIG_PATH: /usr/lib/arm-linux-gnueabihf/pkgconfig run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh linux-armhf + - name: Build linux armhf cross-compiled + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env linux-armhf; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" @@ -107,7 +119,7 @@ jobs: path: | *.tar.gz - linux-x86: + linux-i686: runs-on: ubuntu-20.04 steps: - uses: actions/checkout@v2 @@ -116,39 +128,43 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache - key: ccache-linux-x86 + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets + key: ccache-linux-i686 - name: Set up dependencies run: | sudo dpkg --add-architecture i386 sudo apt-get update -qq - sudo apt-get install -yqq g++-i686-linux-gnu libgl1-mesa-dev:i386 liblo-dev:i386 libx11-dev:i386 libxcursor-dev:i386 libxext-dev:i386 libxrandr-dev:i386 + sudo apt-get install -yqq g++-multilib libdbus-1-dev:i386 libgl1-mesa-dev:i386 libx11-dev:i386 libxcursor-dev:i386 libxext-dev:i386 libxrandr-dev:i386 - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build linux x86 + - name: Build extra dependencies env: - CC: i686-linux-gnu-gcc - CXX: i686-linux-gnu-g++ - CFLAGS: -m32 - CXXFLAGS: -m32 - LDFLAGS: -m32 -static-libgcc -static-libstdc++ PKG_CONFIG_PATH: /usr/lib/i386-linux-gnu/pkgconfig run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh linux-i686 + - name: Build linux i686 + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env linux-i686; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" - name: Pack binaries run: | - tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-x86-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) + tar -c -h --hard-dereference -z -f ${{ github.event.repository.name }}-linux-i686-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }}.tar.gz -C bin $(ls bin | grep -e lv2 -e vst) - uses: actions/upload-artifact@v2 with: - name: ${{ github.event.repository.name }}-linux-x86-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} + name: ${{ github.event.repository.name }}-linux-i686-${{ github.event.pull_request.number || steps.slug.outputs.sha8 }} path: | *.tar.gz @@ -161,24 +177,31 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-linux-x86_64 - name: Set up dependencies run: | sudo apt-get update -qq - sudo apt-get install -yqq libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev + sudo apt-get install -yqq libdbus-1-dev libgl1-mesa-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build linux x86_64 - env: - LDFLAGS: -static-libgcc -static-libstdc++ + - name: Build extra dependencies run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh linux + - name: Build linux x86_64 + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env linux; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" @@ -243,7 +266,7 @@ jobs: - name: Set up dependencies run: | sudo apt-get update -qq - sudo apt-get install -yqq libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev libarchive-dev libjansson-dev libsamplerate0-dev libspeexdsp-dev + sudo apt-get install -yqq libgl1-mesa-dev liblo-dev libx11-dev libxcursor-dev libxext-dev libxrandr-dev libarchive-dev libjansson-dev libsamplerate0-dev libsndfile1-dev libspeexdsp-dev - name: Build linux x86_64 (sysdeps) run: | make features @@ -258,26 +281,31 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-win32 - name: Install ccache run: | brew install ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - name: Fix up Xcode run: | - export PATH="/usr/local/opt/ccache/libexec:${PATH}" sudo rm -Rf /Library/Developer/CommandLineTools/SDKs/* sudo xcode-select -s "/Applications/Xcode_12.3.app" - - name: Build macOS universal - env: - CFLAGS: -arch x86_64 -arch arm64 -DMAC_OS_X_VERSION_MAX_ALLOWED=MAC_OS_X_VERSION_10_12 -mmacosx-version-min=10.12 -mtune=generic -msse -msse2 - CXXFLAGS: -arch x86_64 -arch arm64 -DMAC_OS_X_VERSION_MAX_ALLOWED=MAC_OS_X_VERSION_10_12 -mmacosx-version-min=10.12 -mtune=generic -msse -msse2 - LDFLAGS: -arch x86_64 -arch arm64 -mmacosx-version-min=10.12 + - name: Build extra dependencies run: | + export PATH="/usr/local/opt/ccache/libexec:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh macos-universal + - name: Build macOS universal + run: | + export PATH="/usr/local/opt/ccache/libexec:${PATH}" + pushd deps/PawPaw; source local.env macos-universal; popd make features - make NOOPT=true WITH_LTO=true -j $(sysctl -n hw.logicalcpu) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(sysctl -n hw.logicalcpu) ./dpf/utils/package-osx-bundles.sh - name: Set sha8 id: slug @@ -297,7 +325,11 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-win32 - name: Set up dependencies run: | @@ -308,21 +340,18 @@ jobs: - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build win32 cross-compiled - env: - CC: i686-w64-mingw32-gcc - CXX: i686-w64-mingw32-g++ - EXE_WRAPPER: wine - PKG_CONFIG: "false" - WINEARCH: "win32" - WINEDEBUG: "-all" - WINEDLLOVERRIDES: "mscoree,mshtml=" + - name: Build extra dependencies run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh win32 + - name: Build win32 cross-compiled + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env win32; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" @@ -344,7 +373,11 @@ jobs: - name: Set up ccache uses: actions/cache@v2 with: - path: ~/.cache + path: | + ${HOME}/.cache + ${HOME}/PawPawBuilds/builds + ${HOME}/PawPawBuilds/downloads + ${HOME}/PawPawBuilds/targets key: ccache-win64 - name: Set up dependencies run: | @@ -353,21 +386,18 @@ jobs: - name: Install ccache run: | sudo apt-get install -yqq ccache - ccache --set-config=cache_dir=~/.cache + ccache --set-config=cache_dir=${HOME}/.cache ccache --set-config=compression=true - - name: Build win64 cross-compiled - env: - CC: x86_64-w64-mingw32-gcc - CXX: x86_64-w64-mingw32-g++ - EXE_WRAPPER: wine - PKG_CONFIG: "false" - WINEARCH: "win64" - WINEDEBUG: "-all" - WINEDLLOVERRIDES: "mscoree,mshtml=" + - name: Build extra dependencies run: | export PATH="/usr/lib/ccache:${PATH}" + ./deps/PawPaw/bootstrap-cardinal.sh win64 + - name: Build win64 cross-compiled + run: | + export PATH="/usr/lib/ccache:${PATH}" + pushd deps/PawPaw; source local.env win64; popd make features - make WITH_LTO=true -j $(nproc) + make NOOPT=true WITH_LTO=true WITH_PAWPAW=true -j $(nproc) - name: Set sha8 id: slug run: echo "::set-output name=sha8::$(echo ${{ github.sha }} | cut -c1-8)" diff --git a/.gitmodules b/.gitmodules index edc5587..1120180 100644 --- a/.gitmodules +++ b/.gitmodules @@ -121,3 +121,6 @@ [submodule "plugins/21kHz"] path = plugins/21kHz url = https://github.com/netboy3/21kHz-rack-plugins.git +[submodule "deps/PawPaw"] + path = deps/PawPaw + url = https://github.com/DISTRHO/PawPaw.git diff --git a/Makefile b/Makefile index efcba97..714524e 100644 --- a/Makefile +++ b/Makefile @@ -20,9 +20,6 @@ SYSDEPS ?= false CARLA_EXTRA_ARGS = \ HAVE_FFMPEG=false \ - HAVE_FLUIDSYNTH=false \ - HAVE_LIBMAGIC=false \ - HAVE_SNDFILE=false \ HAVE_PROJECTM=false \ HAVE_ZYN_DEPS=false \ HAVE_ZYN_UI_DEPS=false @@ -64,7 +61,7 @@ ifneq ($(WASM),true) ifneq ($(HEADLESS),true) ifneq ($(HAVE_OPENGL),true) -$(error X11 dependency not installed/available) +$(error OpenGL dependency not installed/available) endif ifneq ($(HAVE_X11),true) $(error X11 dependency not installed/available) diff --git a/README.md b/README.md index 2a3a1f9..24c0ade 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ It does not load external modules and does not connect to the official Rack libr Because it is using DPF, Cardinal already supports LV2 and VST2 with an extra JACK standalone mode if self-compiled. A VST3 version is in progress, already part of the build but still experimental. -**The project should be considered in alpha state at the moment.** +**The project should be considered in beta state at the moment.** ## Plugin variants @@ -54,10 +54,10 @@ But a couple of modules background's have their colors flipped, because damn we Most of the features already work, you can assume things work in general except when stated otherwise. Currently the following features are known NOT to work: -- Clipboard (copy&paste) -- Clock related triggers in built-in MIDI modules -- Export/import module selection -- File dialogs triggered by module right-click menus +- Clock related triggers in built-in MIDI modules [#25](https://github.com/DISTRHO/Cardinal/issues/25) +- VST3 support incomplete/experimental [#41](https://github.com/DISTRHO/Cardinal/issues/41) +- Factory (plugin-provided) presets [#58](https://github.com/DISTRHO/Cardinal/issues/58) +- File dialogs triggered by module right-click menus [#76, in progress](https://github.com/DISTRHO/Cardinal/issues/76) ### Current builds diff --git a/deps/Makefile b/deps/Makefile index ef94d8e..569e440 100644 --- a/deps/Makefile +++ b/deps/Makefile @@ -126,6 +126,10 @@ DEP_MAKE += DEP_FLAGS="$(BASE_FLAGS)" DEP_MAKE += DEP_MAC_SDK_FLAGS= DEP_MAKE += MACHINE=$(MACHINE)$(MACHINE_SUFFIX) +ifeq ($(MACOS),true) +DEP_MAKE += SHA256SUM="shasum5.28 -a 256" +endif + # -------------------------------------------------------------- # Rack internal dependencies target diff --git a/deps/PawPaw b/deps/PawPaw new file mode 160000 index 0000000..02ff3c6 --- /dev/null +++ b/deps/PawPaw @@ -0,0 +1 @@ +Subproject commit 02ff3c65f53a8997a2c313e17afdc491c6575f61 diff --git a/include/app/RackWidget.hpp b/include/app/RackWidget.hpp deleted file mode 100644 index 56c10e6..0000000 --- a/include/app/RackWidget.hpp +++ /dev/null @@ -1,28 +0,0 @@ -/* - * DISTRHO Cardinal Plugin - * Copyright (C) 2021 Filipe Coelho - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 3 of - * the License, or any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * For a full copy of the GNU General Public License see the LICENSE file. - */ - -#pragma once - -#ifdef BUILDING_PLUGIN_MODULES -# undef ModuleWidget -#endif - -#include_next - -#ifdef BUILDING_PLUGIN_MODULES -# define ModuleWidget CardinalModuleWidget -#endif diff --git a/include/plugin/Model.hpp b/include/plugin/Model.hpp deleted file mode 100644 index 83e3a7c..0000000 --- a/include/plugin/Model.hpp +++ /dev/null @@ -1,29 +0,0 @@ -/* - * DISTRHO Cardinal Plugin - * Copyright (C) 2021 Filipe Coelho - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License as - * published by the Free Software Foundation; either version 3 of - * the License, or any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * For a full copy of the GNU General Public License see the LICENSE file. - */ - -#pragma once - -#ifdef BUILDING_PLUGIN_MODULES -namespace rack { -namespace app { -struct CardinalModuleWidget; -} -} -# define ModuleWidget CardinalModuleWidget -#endif - -#include_next diff --git a/include/app/ModuleWidget.hpp b/include/rack.hpp similarity index 89% rename from include/app/ModuleWidget.hpp rename to include/rack.hpp index 7d49e44..3ca4cc6 100644 --- a/include/app/ModuleWidget.hpp +++ b/include/rack.hpp @@ -17,12 +17,7 @@ #pragma once -#ifdef BUILDING_PLUGIN_MODULES -# include -# undef ModuleWidget -#endif - -#include_next +#include_next #ifdef BUILDING_PLUGIN_MODULES namespace rack { diff --git a/plugins/AudibleInstruments b/plugins/AudibleInstruments index d31687d..e5f724d 160000 --- a/plugins/AudibleInstruments +++ b/plugins/AudibleInstruments @@ -1 +1 @@ -Subproject commit d31687dcb51bc851d9c8892ba75d4be3d472b264 +Subproject commit e5f724d2611e16669e9261b6e82b38e7d2283ed4 diff --git a/plugins/Makefile b/plugins/Makefile index e1ba83d..ef33470 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -543,8 +543,7 @@ PLUGIN_FILES += $(filter-out Prism/src/plugin.cpp, $(wildcard Prism/src/*.cpp)) PLUGIN_FILES += $(wildcard Prism/src/scales/*.cpp) # modules/types which are present in other plugins -PRISM_CUSTOM = bogaudio Filter FilterSetting Inputs Scale -# PRISM_CUSTOM_PER_FILE = PrismFilterSetting +PRISM_CUSTOM = bogaudio Scale # -------------------------------------------------------------- # rackwindows @@ -1084,6 +1083,15 @@ $(BUILD_DIR)/ImpromptuModular/src/Foundr%.cpp.o: ImpromptuModular/src/Foundr%.cp -DpluginInstance=pluginInstance__ImpromptuModular \ -DStepAttributes=StepAttributesKernel \ +$(BUILD_DIR)/ImpromptuModular/src/ImpromptuModular.cpp.o: ImpromptuModular/src/ImpromptuModular.cpp + -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" + @echo "Compiling $<" + $(SILENT)$(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@ \ + $(foreach m,$(IMPROMPTUMODULAR_CUSTOM),$(call custom_module_names,$(m),ImpromptuModular)) \ + -DpluginInstance=pluginInstance__ImpromptuModular \ + -Dinit=init__ImpromptuModular \ + -UBUILDING_PLUGIN_MODULES + $(BUILD_DIR)/ImpromptuModular%.cpp.o: ImpromptuModular%.cpp -@mkdir -p "$(shell dirname $(BUILD_DIR)/$<)" @echo "Compiling $<" @@ -1091,7 +1099,6 @@ $(BUILD_DIR)/ImpromptuModular%.cpp.o: ImpromptuModular%.cpp $(foreach m,$(IMPROMPTUMODULAR_CUSTOM),$(call custom_module_names,$(m),ImpromptuModular)) \ $(foreach m,$(IMPROMPTUMODULAR_CUSTOM_PER_FILE),$(call custom_per_file_names,$(m),ImpromptuModular_$(shell basename $*))) \ -DpluginInstance=pluginInstance__ImpromptuModular \ - -Dinit=init__ImpromptuModular \ -Wno-format-truncation $(BUILD_DIR)/JW-Modules/src/WavHead.cpp.o: JW-Modules/src/WavHead.cpp diff --git a/plugins/Prism b/plugins/Prism index 6b2510c..112da33 160000 --- a/plugins/Prism +++ b/plugins/Prism @@ -1 +1 @@ -Subproject commit 6b2510c601db8bd3b57cd5eef8c2924cb8badfc7 +Subproject commit 112da337214d5be1f14640066fe1d08b8ec740dc diff --git a/src/CardinalModuleWidget.cpp b/src/CardinalModuleWidget.cpp index c5cb043..fa1ca9c 100644 --- a/src/CardinalModuleWidget.cpp +++ b/src/CardinalModuleWidget.cpp @@ -25,31 +25,35 @@ * the License, or (at your option) any later version. */ -#define BUILDING_PLUGIN_MODULES -#include -#include -#include -#include -#undef ModuleWidget - #include "CardinalCommon.hpp" +#include +#include #include #include #include #include #include +#include #include namespace rack { namespace app { +struct CardinalModuleWidget : ModuleWidget { + CardinalModuleWidget() : ModuleWidget() {} + DEPRECATED CardinalModuleWidget(engine::Module* module) : ModuleWidget() { + setModule(module); + } + void onButton(const ButtonEvent& e) override; +}; + struct ModuleWidget::Internal { math::Vec dragOffset; math::Vec dragRackPos; - bool dragEnabled = true; + bool dragEnabled; math::Vec oldPos; - widget::Widget* panel = NULL; + widget::Widget* panel; }; static void CardinalModuleWidget__loadDialog(ModuleWidget* const w)