diff --git a/clang/CMakeLists.txt b/clang/CMakeLists.txt --- a/clang/CMakeLists.txt +++ b/clang/CMakeLists.txt @@ -759,6 +759,7 @@ add_dependencies(clang-bootstrap-deps llvm-objcopy llvm-strip) set(${CLANG_STAGE}_OBJCOPY -DCMAKE_OBJCOPY=${LLVM_RUNTIME_OUTPUT_INTDIR}/llvm-objcopy) set(${CLANG_STAGE}_STRIP -DCMAKE_STRIP=${LLVM_RUNTIME_OUTPUT_INTDIR}/llvm-strip) + set(${CLANG_STAGE}_READELF -DCMAKE_READELF=${LLVM_RUNTIME_OUTPUT_INTDIR}/llvm-readelf) endif() endif() diff --git a/compiler-rt/cmake/Modules/AddCompilerRT.cmake b/compiler-rt/cmake/Modules/AddCompilerRT.cmake --- a/compiler-rt/cmake/Modules/AddCompilerRT.cmake +++ b/compiler-rt/cmake/Modules/AddCompilerRT.cmake @@ -598,6 +598,7 @@ CMAKE_OBJCOPY CMAKE_OBJDUMP CMAKE_STRIP + CMAKE_READELF CMAKE_SYSROOT LIBCXX_HAS_MUSL_LIBC PYTHON_EXECUTABLE diff --git a/llvm/cmake/modules/LLVMExternalProjectUtils.cmake b/llvm/cmake/modules/LLVMExternalProjectUtils.cmake --- a/llvm/cmake/modules/LLVMExternalProjectUtils.cmake +++ b/llvm/cmake/modules/LLVMExternalProjectUtils.cmake @@ -244,7 +244,8 @@ -DCMAKE_NM=${CMAKE_NM} -DCMAKE_OBJCOPY=${CMAKE_OBJCOPY} -DCMAKE_OBJDUMP=${CMAKE_OBJDUMP} - -DCMAKE_STRIP=${CMAKE_STRIP}) + -DCMAKE_STRIP=${CMAKE_STRIP} + -DCMAKE_READELF=${CMAKE_READELF}) set(llvm_config_path ${LLVM_CONFIG_PATH}) if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")