-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* delete juce header * set up JUCE library target * extract code to library target * add test * integrate test with CI
- Loading branch information
1 parent
edc4c18
commit 2242a5f
Showing
17 changed files
with
119 additions
and
45 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
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,3 +1,3 @@ | ||
[submodule "JUCE"] | ||
path = JUCE | ||
path = JUCE/JUCE | ||
url = https://github.com/juce-framework/JUCE.git |
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,29 @@ | ||
add_subdirectory(JUCE) | ||
|
||
add_library(juce_modules STATIC) | ||
add_library(valvestate::juce_modules ALIAS juce_modules) | ||
|
||
target_link_libraries(juce_modules | ||
PRIVATE | ||
juce::juce_audio_utils | ||
juce::juce_dsp | ||
PUBLIC | ||
juce::juce_recommended_config_flags | ||
juce::juce_recommended_warning_flags) | ||
|
||
# We're linking the modules privately, but we need to export | ||
# their compile flags | ||
target_compile_definitions(juce_modules | ||
PUBLIC | ||
JUCE_VST3_CAN_REPLACE_VST2=0 | ||
JUCE_WEB_BROWSER=0 | ||
JUCE_USE_CURL=0 | ||
JucePlugin_Build_Standalone=1 | ||
JUCE_STANDALONE_APPLICATION=JucePlugin_Build_Standalone | ||
INTERFACE | ||
$<TARGET_PROPERTY:juce_modules,COMPILE_DEFINITIONS>) | ||
|
||
# We also need to export the include directories for the modules | ||
target_include_directories(juce_modules | ||
SYSTEM INTERFACE | ||
$<TARGET_PROPERTY:juce_modules,INCLUDE_DIRECTORIES>) |
Submodule JUCE
updated
from 000000 to 5179f4
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,22 @@ | ||
add_library(valvestate_lib STATIC) | ||
add_library(valvestate::lib ALIAS valvestate_lib ) | ||
|
||
target_sources(valvestate_lib | ||
PRIVATE | ||
PluginProcessor.cpp | ||
dsp/Clipping.cpp | ||
dsp/Contour.cpp | ||
dsp/FMV.cpp | ||
dsp/GainControl.cpp | ||
dsp/InputFilter.cpp | ||
dsp/WaveShape.cpp | ||
ui/PluginEditor.cpp) | ||
|
||
target_include_directories(valvestate_lib PRIVATE .) | ||
|
||
target_link_libraries(valvestate_lib | ||
PUBLIC | ||
valvestate::juce_modules | ||
juce::juce_recommended_config_flags | ||
juce::juce_recommended_lto_flags | ||
juce::juce_recommended_warning_flags) |
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
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
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
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,23 @@ | ||
cmake_minimum_required(VERSION 3.22) | ||
project (ValvestateTest LANGUAGES CXX) | ||
|
||
include(FetchContent) | ||
FetchContent_Declare( | ||
googletest | ||
URL https://github.com/google/googletest/archive/03597a01ee50ed33e9dfd640b249b4be3799d395.zip | ||
) | ||
# For Windows: Prevent overriding the parent project's compiler/linker settings | ||
set(gtest_force_shared_crt ON CACHE BOOL "" FORCE) | ||
FetchContent_MakeAvailable(googletest) | ||
|
||
add_executable( | ||
test_clipping | ||
test_clipping.cpp | ||
) | ||
target_link_libraries( | ||
test_clipping | ||
GTest::gtest_main | ||
) | ||
|
||
include(GoogleTest) | ||
gtest_discover_tests(test_clipping) |
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,9 @@ | ||
#include <gtest/gtest.h> | ||
|
||
// Demonstrate some basic assertions. | ||
TEST(HelloTest, BasicAssertions) { | ||
// Expect two strings not to be equal. | ||
EXPECT_STRNE("hello", "world"); | ||
// Expect equality. | ||
EXPECT_EQ(7 * 6, 42); | ||
} |