2014-11-08 09:41:49 +08:00
|
|
|
if ( CMAKE_SYSTEM_NAME MATCHES "Linux" )
|
|
|
|
include_directories(
|
2015-05-10 23:22:09 +08:00
|
|
|
../../../../llvm/include
|
2014-11-08 09:41:49 +08:00
|
|
|
../../source/Plugins/Process/Linux
|
|
|
|
../../source/Plugins/Process/POSIX
|
|
|
|
)
|
|
|
|
endif ()
|
|
|
|
|
|
|
|
if ( CMAKE_SYSTEM_NAME MATCHES "FreeBSD" )
|
|
|
|
include_directories(
|
2015-05-10 23:22:09 +08:00
|
|
|
../../../../llvm/include
|
2014-11-08 09:41:49 +08:00
|
|
|
../../source/Plugins/Process/FreeBSD
|
|
|
|
../../source/Plugins/Process/POSIX
|
|
|
|
)
|
|
|
|
endif ()
|
2015-02-18 23:39:41 +08:00
|
|
|
|
2015-10-24 08:27:04 +08:00
|
|
|
if ( CMAKE_SYSTEM_NAME MATCHES "NetBSD" )
|
|
|
|
include_directories(
|
|
|
|
../../../../llvm/include
|
2017-03-22 01:30:47 +08:00
|
|
|
../../source/Plugins/Process/NetBSD
|
2015-10-24 08:27:04 +08:00
|
|
|
../../source/Plugins/Process/POSIX
|
|
|
|
)
|
|
|
|
endif ()
|
|
|
|
|
2013-11-22 02:39:32 +08:00
|
|
|
include_directories(../../source)
|
|
|
|
|
2017-07-07 19:02:19 +08:00
|
|
|
set(LLDB_PLUGINS)
|
|
|
|
|
|
|
|
if(CMAKE_SYSTEM_NAME MATCHES "Linux|Android")
|
|
|
|
list(APPEND LLDB_PLUGINS lldbPluginProcessLinux)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
if(CMAKE_SYSTEM_NAME MATCHES "NetBSD")
|
|
|
|
list(APPEND LLDB_PLUGINS lldbPluginProcessNetBSD)
|
|
|
|
endif()
|
|
|
|
|
2018-05-24 20:44:18 +08:00
|
|
|
if(CMAKE_SYSTEM_NAME MATCHES "Darwin")
|
|
|
|
list(APPEND LLDB_PLUGINS lldbPluginObjectFileMachO)
|
|
|
|
elseif(CMAKE_SYSTEM_NAME MATCHES "Windows")
|
|
|
|
list(APPEND LLDB_PLUGINS lldbPluginObjectFilePECOFF)
|
|
|
|
else()
|
|
|
|
list(APPEND LLDB_PLUGINS lldbPluginObjectFileELF)
|
|
|
|
endif()
|
|
|
|
|
[CMake] Revised LLDB.framework builds
Summary:
Add features to LLDB CMake builds that have so far only been available in Xcode. Clean up a few inconveniences and prepare further improvements.
Options:
* `LLDB_FRAMEWORK_BUILD_DIR` determines target directory (in build-tree)
* `LLDB_FRAMEWORK_INSTALL_DIR` **only** determines target directory in install-tree
* `LLVM_EXTERNALIZE_DEBUGINFO` allows externalized debug info (dSYM on Darwin, emitted to `bin`)
* `LLDB_FRAMEWORK_TOOLS` determines which executables will be copied to the framework's Resources (dropped symlinking, removed INCLUDE_IN_SUITE, removed dummy targets)
Other changes:
* clean up `add_lldb_executable()`
* include `LLDBFramework.cmake` from `source/API/CMakeLists.txt`
* use `*.plist.in` files, which are typical for CMake and independent from Xcode
* add clang headers to the framework bundle
Reviewers: xiaobai, JDevlieghere, aprantl, davide, beanz, stella.stamenova, clayborg, labath
Reviewed By: aprantl
Subscribers: friss, mgorny, lldb-commits, #lldb
Differential Revision: https://reviews.llvm.org/D55328
llvm-svn: 350391
2019-01-04 20:46:50 +08:00
|
|
|
add_lldb_tool(lldb-server
|
2015-10-22 03:34:26 +08:00
|
|
|
Acceptor.cpp
|
2015-01-15 05:01:15 +08:00
|
|
|
lldb-gdbserver.cpp
|
2015-02-18 23:39:41 +08:00
|
|
|
lldb-platform.cpp
|
2015-05-27 21:34:04 +08:00
|
|
|
lldb-server.cpp
|
|
|
|
LLDBServerUtilities.cpp
|
2018-05-24 20:44:18 +08:00
|
|
|
SystemInitializerLLGS.cpp
|
2016-01-29 19:59:57 +08:00
|
|
|
|
2017-02-09 05:00:46 +08:00
|
|
|
LINK_LIBS
|
|
|
|
lldbBase
|
|
|
|
lldbCore
|
|
|
|
lldbHost
|
|
|
|
lldbInitialization
|
|
|
|
lldbInterpreter
|
2017-07-07 19:02:19 +08:00
|
|
|
${LLDB_PLUGINS}
|
2017-02-09 05:00:46 +08:00
|
|
|
${LLDB_SYSTEM_LIBS}
|
|
|
|
|
|
|
|
LINK_COMPONENTS
|
|
|
|
Support
|
|
|
|
)
|
2017-02-01 05:12:52 +08:00
|
|
|
|
2017-12-07 04:53:03 +08:00
|
|
|
target_link_libraries(lldb-server PRIVATE ${LLDB_SYSTEM_LIBS})
|