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:45:23 +0000
commite1f979b45d252c710cb9edfe4bbe65951e50fab5 (patch)
treec99eb27776105441c5816075ce275654ebf67d54 /CMakeLists.txt
parent8f1d1e25a9b48b80e880a32fad6a4231f048b83f (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 24b61cd61e..c3c24cdc77 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)
@@ -133,6 +136,7 @@ set(required_deps ASS
FriBidi
fstrcmp
Iconv
+ KissFFT
LibDvd
Lzo2
OpenSSL>=1.0.2