summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorZephyron <zephyron@citron-emu.org>2025-01-09 17:24:53 +1000
committerZephyron <zephyron@citron-emu.org>2025-01-09 17:24:53 +1000
commitd3ed42af8f697fde240b26e02aab0c6cf3c137c5 (patch)
tree2308050f43d9c1ee4fb8f362e516901ff7b3e710 /CMakeLists.txt
parent0cf545858d6b969be2df4d8b81f4baece3a8f175 (diff)
feat: make LLVM Demangle optional via CMake flag
Added new CMake option CITRON_USE_LLVM_DEMANGLE (default: ON) to control whether the project uses LLVM's Demangle component. This allows building without LLVM dependencies when demangling support is not needed. Co-authored-by: reg_server
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt6
1 files changed, 5 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index eda476c6b..f3f92194b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -66,6 +66,8 @@ option(CITRON_DOWNLOAD_TIME_ZONE_DATA "Always download time zone binaries" OFF)
option(CITRON_ENABLE_PORTABLE "Allow citron to enable portable mode if a user folder is found in the CWD" ON)
+option(CITRON_USE_LLVM_DEMANGLE "Use LLVM Demangle" ON)
+
CMAKE_DEPENDENT_OPTION(CITRON_USE_FASTER_LD "Check if a faster linker is available" ON "NOT WIN32" OFF)
CMAKE_DEPENDENT_OPTION(USE_SYSTEM_MOLTENVK "Use the system MoltenVK lib (instead of the bundled one)" OFF "APPLE" OFF)
@@ -295,7 +297,9 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PROJECT_BINARY_DIR}/bin)
find_package(Boost 1.79.0 REQUIRED context)
find_package(enet 1.3 MODULE)
find_package(fmt 9 REQUIRED)
-find_package(LLVM 17.0.2 MODULE COMPONENTS Demangle)
+if (CITRON_USE_LLVM_DEMANGLE)
+ find_package(LLVM 17.0.2 MODULE COMPONENTS Demangle)
+endif()
find_package(lz4 REQUIRED)
find_package(nlohmann_json 3.8 REQUIRED)
find_package(Opus 1.3 MODULE)