[PATCH] D145449: [Fuchsia] Add LLDB options to stage 1 cmake.
Daniel Thornburgh via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 6 16:05:37 PST 2023
mysterymath created this revision.
mysterymath added reviewers: phosek, haowei.
Herald added a subscriber: abrachet.
Herald added a project: All.
mysterymath requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
LLVM_ENABLE_PROJECTS is automatically forwarded from stage 1 builds to
stage 2 builds, so setting FUCHSIA_ENABLE_LLDB has no effect on
two-stage builds.
Instead, add FUCHSIA_ENABLE_LLDB to the stage one build as well.
This also disables curses and libedit by default for now in both stage1
and stage 2 builds; these should be opt-in.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D145449
Files:
clang/cmake/caches/Fuchsia-stage2.cmake
clang/cmake/caches/Fuchsia.cmake
Index: clang/cmake/caches/Fuchsia.cmake
===================================================================
--- clang/cmake/caches/Fuchsia.cmake
+++ clang/cmake/caches/Fuchsia.cmake
@@ -4,7 +4,7 @@
set(PACKAGE_VENDOR Fuchsia CACHE STRING "")
-set(LLVM_ENABLE_PROJECTS "bolt;clang;clang-tools-extra;lld;llvm;polly" CACHE STRING "")
+set(_FUCHSIA_ENABLE_PROJECTS "bolt;clang;clang-tools-extra;lld;llvm;polly")
set(LLVM_ENABLE_DIA_SDK OFF CACHE BOOL "")
set(LLVM_ENABLE_LIBEDIT OFF CACHE BOOL "")
@@ -17,6 +17,8 @@
set(LLVM_INCLUDE_DOCS OFF CACHE BOOL "")
set(LLVM_INCLUDE_EXAMPLES OFF CACHE BOOL "")
set(LLVM_USE_RELATIVE_PATHS_IN_FILES ON CACHE BOOL "")
+set(LLDB_ENABLE_CURSES OFF CACHE BOOL "")
+set(LLDB_ENABLE_LIBEDIT OFF CACHE BOOL "")
# Passthrough stage1 flags to stage1.
set(_FUCHSIA_BOOTSTRAP_PASSTHROUGH
@@ -30,6 +32,9 @@
LLVM_ENABLE_CURL
CURL_ROOT
OpenSSL_ROOT
+ FUCHSIA_ENABLE_LLDB
+ LLDB_ENABLE_CURSES
+ LLDB_ENABLE_LIBEDIT
CMAKE_FIND_PACKAGE_PREFER_CONFIG
CMAKE_SYSROOT
CMAKE_MODULE_LINKER_FLAGS
@@ -157,6 +162,12 @@
install-distribution-toolchain
clang CACHE STRING "")
+set(FUCHSIA_ENABLE_LLDB OFF CACHE BOOL "Enable LLDB")
+if(FUCHSIA_ENABLE_LLDB)
+ list(APPEND _FUCHSIA_ENABLE_PROJECTS lldb)
+endif()
+set(LLVM_ENABLE_PROJECTS ${_FUCHSIA_ENABLE_PROJECTS} CACHE STRING "")
+
get_cmake_property(variableNames VARIABLES)
foreach(variableName ${variableNames})
if(variableName MATCHES "^STAGE2_")
Index: clang/cmake/caches/Fuchsia-stage2.cmake
===================================================================
--- clang/cmake/caches/Fuchsia-stage2.cmake
+++ clang/cmake/caches/Fuchsia-stage2.cmake
@@ -23,6 +23,8 @@
set(LLVM_INCLUDE_EXAMPLES OFF CACHE BOOL "")
set(LLVM_STATIC_LINK_CXX_STDLIB ON CACHE BOOL "")
set(LLVM_USE_RELATIVE_PATHS_IN_FILES ON CACHE BOOL "")
+set(LLDB_ENABLE_CURSES OFF CACHE BOOL "")
+set(LLDB_ENABLE_LIBEDIT OFF CACHE BOOL "")
if(WIN32)
set(LLVM_USE_CRT_RELEASE "MT" CACHE STRING "")
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145449.502848.patch
Type: text/x-patch
Size: 1985 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230307/cc893673/attachment-0001.bin>
More information about the cfe-commits
mailing list