[PATCH] D136700: clang: Add a cmake toggle to disable libclang's libxml2 dependency
Nico Weber via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 26 10:34:42 PDT 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rGdf239a6c17fa: clang: Add a cmake toggle to disable libclang's libxml2 dependency (authored by thakis).
Herald added a project: clang.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D136700/new/
https://reviews.llvm.org/D136700
Files:
clang/CMakeLists.txt
Index: clang/CMakeLists.txt
===================================================================
--- clang/CMakeLists.txt
+++ clang/CMakeLists.txt
@@ -147,7 +147,12 @@
"${LLVM_COMMON_CMAKE_UTILS}/Modules"
)
-if(LLVM_ENABLE_LIBXML2)
+# This allows disabling clang's XML dependency even if LLVM finds libxml2.
+# By default, clang depends on libxml2 if LLVM does.
+option(CLANG_ENABLE_LIBXML2 "Whether libclang may depend on libxml2"
+ ${LLVM_ENABLE_LIBXML2})
+
+if(CLANG_ENABLE_LIBXML2)
# Don't look for libxml if we're using MSan, since uninstrumented third party
# code may call MSan interceptors like strlen, leading to false positives.
if(NOT LLVM_USE_SANITIZER MATCHES "Memory.*")
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D136700.470861.patch
Type: text/x-patch
Size: 707 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20221026/4a3fda57/attachment-0001.bin>
More information about the cfe-commits
mailing list