Skip to content

Commit de5bbe0

Browse files
chelcassanovamahesh-attarde
authored andcommitted
[lldb][rpc] Disable building lldb-rpc-gen tool (llvm#150699)
Disabling the lldb-rpc-gen tool while issues with certain builds are solved: llvm#148996
1 parent c8fbe5c commit de5bbe0

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

lldb/cmake/modules/LLDBConfig.cmake

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,8 @@ endif()
327327
# lldb-rpc sources in the first phase of host build so that they can
328328
# get built using the just-built Clang toolchain in the second phase.
329329
if (NOT DEFINED LLDB_CAN_USE_LLDB_RPC_SERVER)
330+
set(LLDB_CAN_USE_LLDB_RPC_SERVER OFF)
331+
else()
330332
if ((CMAKE_CROSSCOMPILING OR LLVM_HOST_TRIPLE MATCHES "${LLVM_DEFAULT_TARGET_TRIPLE}") AND
331333
CMAKE_SYSTEM_NAME MATCHES "AIX|Android|Darwin|FreeBSD|Linux|NetBSD|OpenBSD|Windows")
332334
set(LLDB_CAN_USE_LLDB_RPC_SERVER ON)
@@ -335,11 +337,16 @@ if (NOT DEFINED LLDB_CAN_USE_LLDB_RPC_SERVER)
335337
endif()
336338
endif()
337339

338-
if (CMAKE_CROSSCOMPILING)
339-
set(LLDB_BUILD_LLDBRPC OFF CACHE BOOL "")
340-
get_host_tool_path(lldb-rpc-gen LLDB_RPC_GEN_EXE lldb_rpc_gen_exe lldb_rpc_gen_target)
340+
341+
if (NOT DEFINED LLDB_BUILD_LLDBRPC)
342+
set(LLDB_BUILD_LLDBRPC OFF)
341343
else()
342-
set(LLDB_BUILD_LLDBRPC ON CACHE BOOL "")
344+
if (CMAKE_CROSSCOMPILING)
345+
set(LLDB_BUILD_LLDBRPC OFF CACHE BOOL "")
346+
get_host_tool_path(lldb-rpc-gen LLDB_RPC_GEN_EXE lldb_rpc_gen_exe lldb_rpc_gen_target)
347+
else()
348+
set(LLDB_BUILD_LLDBRPC ON CACHE BOOL "")
349+
endif()
343350
endif()
344351

345352
include(LLDBGenerateConfig)

0 commit comments

Comments
 (0)