diff options
author | Be <be@mixxx.org> | 2020-04-20 14:08:01 -0500 |
---|---|---|
committer | Be <be@mixxx.org> | 2020-04-20 14:20:05 -0500 |
commit | 3188119ab863e8949f36a62e24c32c02982636ba (patch) | |
tree | 1d53490915feea7a985a6f9e1738a34d9ec616f8 /CMakeLists.txt | |
parent | 192bdc6f7dfd7e1f744783b3ba13b3452129a1fe (diff) |
AnalyzerKeyFinder: make KeyFinder optional with a CMake option
cmake -DKEYFINDER=ON is required to build with KeyFinder
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 95ab8717c6..77ce8bddf8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -168,7 +168,6 @@ add_library(mixxx-lib STATIC EXCLUDE_FROM_ALL src/analyzer/analyzersilence.cpp src/analyzer/analyzerthread.cpp src/analyzer/analyzerwaveform.cpp - src/analyzer/plugins/analyzerkeyfinder.cpp src/analyzer/plugins/analyzerqueenmarybeats.cpp src/analyzer/plugins/analyzerqueenmarykey.cpp src/analyzer/plugins/analyzersoundtouchbeats.cpp @@ -1302,8 +1301,14 @@ endif() target_include_directories(mixxx-lib SYSTEM PUBLIC lib/fidlib) target_link_libraries(mixxx-lib PUBLIC fidlib) -#KeyFinder -target_link_libraries(mixxx-lib PUBLIC keyfinder) +# KeyFinder +find_package(KeyFinder) +option(KEYFINDER "KeyFinder" OFF) +if(KEYFINDER) + target_sources(mixxx-lib PRIVATE src/analyzer/plugins/analyzerkeyfinder.cpp) + target_compile_definitions(mixxx-lib PUBLIC __KEYFINDER__) + target_link_libraries(mixxx-lib PUBLIC KeyFinder::KeyFinder) +endif() # FLAC find_package(FLAC REQUIRED) |