Browse Source

Remote debugging: now only shows host and remote-gdb-server in the option popover

merge-requests/365/head
eidheim 10 years ago
parent
commit
3f35d73d0f
  1. 5
      src/debug_clang.cc
  2. 1
      src/project.cc

5
src/debug_clang.cc

@ -102,6 +102,8 @@ void Debug::Clang::start(const std::string &command, const boost::filesystem::pa
lldb::SBError error; lldb::SBError error;
if(!plugin.empty() && plugin!="host") { if(!plugin.empty() && plugin!="host") {
//TODO: support other plugins as well
//Plugin names for SBTarget::ConnectRemote does not seem to correspond to the ones from running "platform list" in lldb
process = std::unique_ptr<lldb::SBProcess>(new lldb::SBProcess(target.ConnectRemote(*listener, url.c_str(), "gdb-remote", error))); process = std::unique_ptr<lldb::SBProcess>(new lldb::SBProcess(target.ConnectRemote(*listener, url.c_str(), "gdb-remote", error)));
if(error.Fail()) { if(error.Fail()) {
Terminal::get().async_print(std::string("Error (debug): ")+error.GetCString()+'\n', true); Terminal::get().async_print(std::string("Error (debug): ")+error.GetCString()+'\n', true);
@ -528,7 +530,8 @@ std::vector<std::string> Debug::Clang::get_platform_list() {
} }
std::string line; std::string line;
while(std::getline(stream, line)) { while(std::getline(stream, line)) {
if(line.find("host")==0 || line.find("remote-")==0) { //TODO: support other plugins as well
if(line.find("host")==0 || line.find("remote-gdb-server")==0) {
size_t pos; size_t pos;
if((pos=line.find(": "))!=std::string::npos) { if((pos=line.find(": "))!=std::string::npos) {
line.replace(pos, 2, "\n"); line.replace(pos, 2, "\n");

1
src/project.cc

@ -169,6 +169,7 @@ Project::Clang::DebugOptionsPopover::DebugOptionsPopover() : Gtk::Popover() {
}); });
url.set_placeholder_text("URL"); url.set_placeholder_text("URL");
url.set_text("connect://host:port");
cross_compiling_vbox.pack_start(platform_list, true, true); cross_compiling_vbox.pack_start(platform_list, true, true);
cross_compiling_vbox.pack_end(url, true, true); cross_compiling_vbox.pack_end(url, true, true);

Loading…
Cancel
Save