[PATCH] D152418: [clang] set python3 as required build dependency
Lu JiongJia via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 7 21:19:24 PDT 2023
Avimitin created this revision.
Avimitin added reviewers: gribozavr, aaron.ballman, phosek.
Herald added a project: All.
Avimitin requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
The required HTMLLogger include file needs python3 to run resource_bundle.py to bundle all the html/css/js resources. However, if user sets -DLLVM_INCLUDE_TESTS=OFF, CMake will not find python3 and the resource bundler will never be executed. This patch set the python3 as a required build dependency to fix this problem.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D152418
Files:
clang/CMakeLists.txt
Index: clang/CMakeLists.txt
===================================================================
--- clang/CMakeLists.txt
+++ clang/CMakeLists.txt
@@ -82,10 +82,10 @@
set( CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX} )
set( CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib${LLVM_LIBDIR_SUFFIX} )
- if(LLVM_INCLUDE_TESTS)
- find_package(Python3 ${LLVM_MINIMUM_PYTHON_VERSION} REQUIRED
- COMPONENTS Interpreter)
+ find_package(Python3 ${LLVM_MINIMUM_PYTHON_VERSION} REQUIRED
+ COMPONENTS Interpreter)
+ if(LLVM_INCLUDE_TESTS)
# Check prebuilt llvm/utils.
if(EXISTS ${LLVM_TOOLS_BINARY_DIR}/FileCheck${CMAKE_EXECUTABLE_SUFFIX}
AND EXISTS ${LLVM_TOOLS_BINARY_DIR}/count${CMAKE_EXECUTABLE_SUFFIX}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D152418.529496.patch
Type: text/x-patch
Size: 771 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230608/7addb499/attachment.bin>
More information about the cfe-commits
mailing list