[Lldb-commits] [lldb] f136ca8 - Put the arch-dep debugserver files in main CMakeLists.txt

Jason Molenda via lldb-commits lldb-commits at lists.llvm.org
Tue Feb 28 16:57:27 PST 2023


Author: Jason Molenda
Date: 2023-02-28T16:57:11-08:00
New Revision: f136ca84830942451fc20f8980dbc36028520920

URL: https://github.com/llvm/llvm-project/commit/f136ca84830942451fc20f8980dbc36028520920
DIFF: https://github.com/llvm/llvm-project/commit/f136ca84830942451fc20f8980dbc36028520920.diff

LOG: Put the arch-dep debugserver files in main CMakeLists.txt

The architecture dependent files for debugserver were
built out of their own separate CMakeLists.txt for historical
reasons; it's not necessary any longer.  Remove that file
and put them in the main debugserver CMakeLists.txt.

Differential Revision: https://reviews.llvm.org/D145020
rdar://105993317

Added: 
    

Modified: 
    lldb/tools/debugserver/source/CMakeLists.txt

Removed: 
    lldb/tools/debugserver/source/MacOSX/CMakeLists.txt


################################################################################
diff  --git a/lldb/tools/debugserver/source/CMakeLists.txt b/lldb/tools/debugserver/source/CMakeLists.txt
index c6e7e8cf49e85..2aaefb56cb4b6 100644
--- a/lldb/tools/debugserver/source/CMakeLists.txt
+++ b/lldb/tools/debugserver/source/CMakeLists.txt
@@ -2,8 +2,11 @@ include(CheckCXXCompilerFlag)
 include(CheckLibraryExists)
 include_directories(${CMAKE_CURRENT_BINARY_DIR}/..)
 include_directories(${LLDB_SOURCE_DIR}/source)
-
 include_directories(MacOSX)
+include_directories(MacOSX/i386)
+include_directories(MacOSX/x86_64)
+include_directories(MacOSX/arm)
+include_directories(MacOSX/arm64)
 
 function(check_certificate identity result_valid)
   execute_process(
@@ -108,8 +111,6 @@ endif ()
 
 find_library(SECURITY_LIBRARY Security)
 
-add_subdirectory(MacOSX)
-
 set(LLDB_CODESIGN_IDENTITY "" CACHE STRING
     "Identity override for debugserver; see 'Code Signing on macOS' in the documentation (Darwin only)")
 
@@ -227,6 +228,10 @@ set(lldbDebugserverCommonSources
   MacOSX/MachVMMemory.cpp
   MacOSX/MachVMRegion.cpp
   MacOSX/OsLogger.cpp
+  MacOSX/arm/DNBArchImpl.cpp
+  MacOSX/arm64/DNBArchImplARM64.cpp
+  MacOSX/i386/DNBArchImplI386.cpp
+  MacOSX/x86_64/DNBArchImplX86_64.cpp
   ${generated_mach_interfaces}
   ${DEBUGSERVER_VERS_GENERATED_FILE})
 
@@ -248,7 +253,6 @@ target_link_libraries(lldbDebugserverCommon
                       ${MOBILESERVICES_LIBRARY}
                       ${LOCKDOWN_LIBRARY}
                       ${CAROUSELSERVICES_LIBRARY}
-                      lldbDebugserverArchSupport
                       ${FOUNDATION_LIBRARY}
                       ${SECURITY_LIBRARY}
                       ${LIBCOMPRESSION}
@@ -313,7 +317,6 @@ if(APPLE_EMBEDDED)
                       INTERFACE ${COCOA_LIBRARY}
                       ${CORE_FOUNDATION_LIBRARY}
                       ${FOUNDATION_LIBRARY}
-                      lldbDebugserverArchSupport
                       ${SECURITY_LIBRARY}
                       ${LIBCOMPRESSION})
 

diff  --git a/lldb/tools/debugserver/source/MacOSX/CMakeLists.txt b/lldb/tools/debugserver/source/MacOSX/CMakeLists.txt
deleted file mode 100644
index 8f44d1bfbb436..0000000000000
--- a/lldb/tools/debugserver/source/MacOSX/CMakeLists.txt
+++ /dev/null
@@ -1,14 +0,0 @@
-list(APPEND SOURCES arm/DNBArchImpl.cpp arm64/DNBArchImplARM64.cpp)
-include_directories(${CURRENT_SOURCE_DIR}/arm ${CURRENT_SOURCE_DIR}/arm64)
-
-list(APPEND SOURCES i386/DNBArchImplI386.cpp x86_64/DNBArchImplX86_64.cpp)
-include_directories(${CURRENT_SOURCE_DIR}/i386 ${CURRENT_SOURCE_DIR}/x86_64)
-
-include_directories(..)
-
-include_directories(${LLDB_SOURCE_DIR}/tools/debugserver/source)
-add_library(lldbDebugserverArchSupport
-  ${SOURCES}
-  )
-
-set_target_properties(lldbDebugserverArchSupport PROPERTIES FOLDER "lldb libraries/debugserver")


        


More information about the lldb-commits mailing list