From fbad490e184e8d188a6956f8870ff6ed997c8c37 Mon Sep 17 00:00:00 2001 From: John Bytheway <52664+jbytheway@users.noreply.github.com> Date: Sun, 3 Mar 2024 09:40:54 -0500 Subject: [PATCH] Remove the requirement to link with clangTidy This was added as part of the transition to LLVM 17, but it breaks the build against LLVM 17 for me locally. The fix was needed for the macOS build, but we've now found an alternative solution to that. See https://github.com/CleverRaven/Cataclysm-DDA/pull/72140 for details. --- tools/clang-tidy-plugin/CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/clang-tidy-plugin/CMakeLists.txt b/tools/clang-tidy-plugin/CMakeLists.txt index 46f3021206537..4d5f5e35fb1f7 100644 --- a/tools/clang-tidy-plugin/CMakeLists.txt +++ b/tools/clang-tidy-plugin/CMakeLists.txt @@ -55,7 +55,9 @@ if (CATA_CLANG_TIDY_EXECUTABLE) else () set(CataAnalyzerName CataAnalyzerPlugin) add_library(${CataAnalyzerName} MODULE ${CataAnalyzerSrc}) - target_link_libraries(${CataAnalyzerName} PRIVATE clangTidy) + if ("${CMAKE_SYSTEM_NAME}" MATCHES "Darwin") + target_link_options(${CataAnalyzerName} PRIVATE -undefined dynamic_lookup) + endif () endif () target_include_directories(${CataAnalyzerName} SYSTEM PRIVATE