summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKamil Rytarowski <n54@gmx.com>2017-03-22 17:24:37 +0000
committerKamil Rytarowski <n54@gmx.com>2017-03-22 17:24:37 +0000
commit26b09b27e5c7bc9e35875df4fc349529429c185e (patch)
treeb080537ac492f7c33550f60c95720628377dc8db
parenta27198853da9a8b547dcaa3791527f946d335578 (diff)
downloadbcm5719-llvm-26b09b27e5c7bc9e35875df4fc349529429c185e.tar.gz
bcm5719-llvm-26b09b27e5c7bc9e35875df4fc349529429c185e.zip
Reuse appropriate Launch and Attach on NetBSD
Summary: NetBSD ships with NativeProcessNetBSD inherited from NativeProcessProtocol. Link Plugins/Process/gdb-remote with lldbPluginProcessNetBSD in order to resolve correctly the linking to Launch and Attach from the NetBSD plugin. Sponsored by <The NetBSD Foundation> Reviewers: kettenis, labath, emaste, joerg Reviewed By: labath, emaste Subscribers: mgorny, #lldb Tags: #lldb Differential Revision: https://reviews.llvm.org/D31231 llvm-svn: 298524
-rw-r--r--lldb/source/Host/common/NativeProcessProtocol.cpp2
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/CMakeLists.txt4
2 files changed, 5 insertions, 1 deletions
diff --git a/lldb/source/Host/common/NativeProcessProtocol.cpp b/lldb/source/Host/common/NativeProcessProtocol.cpp
index eaa424e1646..9d4149d700b 100644
--- a/lldb/source/Host/common/NativeProcessProtocol.cpp
+++ b/lldb/source/Host/common/NativeProcessProtocol.cpp
@@ -504,7 +504,7 @@ Error NativeProcessProtocol::ResolveProcessArchitecture(lldb::pid_t pid,
return Error("failed to retrieve a valid architecture from the exe module");
}
-#ifndef __linux__
+#if !defined(__linux__) && !defined(__NetBSD__)
// These need to be implemented to support lldb-gdb-server on a given platform.
// Stubs are
// provided to make the rest of the code link on non-supported platforms.
diff --git a/lldb/source/Plugins/Process/gdb-remote/CMakeLists.txt b/lldb/source/Plugins/Process/gdb-remote/CMakeLists.txt
index da9087f4146..3d008f42499 100644
--- a/lldb/source/Plugins/Process/gdb-remote/CMakeLists.txt
+++ b/lldb/source/Plugins/Process/gdb-remote/CMakeLists.txt
@@ -11,6 +11,10 @@ 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()
+
add_lldb_library(lldbPluginProcessGDBRemote PLUGIN
GDBRemoteClientBase.cpp
GDBRemoteCommunication.cpp
OpenPOWER on IntegriCloud