aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorVasyl Gello <vasek.gello@gmail.com>2021-10-18 22:58:31 +0000
committerVasyl Gello <vasek.gello@gmail.com>2021-10-20 08:28:29 +0000
commita9f8d3f4b1d5141410916b904a7d1f5230306bb3 (patch)
treea5a5676bd5154df62ddb238cc33b87e9f2f58dfc /CMakeLists.txt
parent53d7223d27c188e5dfecf235edeb7f1383edd1dc (diff)
Add option to use internal or external kissfft
By default, ENABLE_INTERNAL_KISSFFT is ON for all architectures. It is immutable on non-Unix systems because 'FindKissFFT.cmake' relies on 'pkg-config' tool not available in Windows and Android. If Kodi built with internal kissfft, the corresponding CMake search module sets kissfft's include directory to the copied location created by 'core_add_subdirs_from_filelist' macro expanded from 'cmake/treedata/common/externals.txt'. If Kodi built with system kissfft, the module detects the presence of header files and solib by 'pkg-config' and disables building the 'xbmc/contrib/kissfft' directory. Signed-off-by: Vasyl Gello <vasek.gello@gmail.com>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2f6f1c3ae0..1e46f87255 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -69,6 +69,9 @@ if(UNIX)
option(ENABLE_INTERNAL_UDFREAD "Enable internal udfread?" OFF)
option(ENABLE_INTERNAL_SPDLOG "Enable internal spdlog?" OFF)
endif()
+# prefer kissfft from xbmc/contrib but let use system one on unices
+include(CMakeDependentOption)
+cmake_dependent_option(ENABLE_INTERNAL_KISSFFT "Enable internal kissfft?" ON "UNIX" ON)
# System options
if(NOT WIN32)
option(WITH_ARCH "build with given arch" OFF)
@@ -134,6 +137,7 @@ set(required_deps ASS
fstrcmp
HarfBuzz
Iconv
+ KissFFT
LibDvd
Lzo2
OpenSSL>=1.1.0