diff options
| author | Greg Clayton <gclayton@apple.com> | 2011-03-20 04:57:14 +0000 |
|---|---|---|
| committer | Greg Clayton <gclayton@apple.com> | 2011-03-20 04:57:14 +0000 |
| commit | 7a5388bf755acf4b56368758194984750af86ddb (patch) | |
| tree | c02331b4f156f238241041a7bae8668d338d79c9 /lldb/tools/debugserver/source/RNBRemote.cpp | |
| parent | 76c90c65e242ed7207f2154cb94f8f16b095c83f (diff) | |
| download | bcm5719-llvm-7a5388bf755acf4b56368758194984750af86ddb.tar.gz bcm5719-llvm-7a5388bf755acf4b56368758194984750af86ddb.zip | |
Split all of the core of LLDB.framework/lldb.so into a
static archive that can be linked against. LLDB.framework/lldb.so
exports a very controlled API. Splitting the API into a static
library allows other tools (debugserver for now) to use the power
of the LLDB debugger core, yet not export it as its API is not
portable or maintainable. The Host layer and many of the other
internal only APIs can now be statically linked against.
Now LLDB.framework/lldb.so links against "liblldb-core.a" instead
of compiling the .o files only for the shared library. This fix
is only for compiling with Xcode as the Makefile based build already
does this.
The Xcode projecdt compiler has been changed to LLVM. Anyone using
Xcode 3 will need to manually change the compiler back to GCC 4.2,
or update to Xcode 4.
llvm-svn: 127963
Diffstat (limited to 'lldb/tools/debugserver/source/RNBRemote.cpp')
| -rw-r--r-- | lldb/tools/debugserver/source/RNBRemote.cpp | 98 |
1 files changed, 98 insertions, 0 deletions
diff --git a/lldb/tools/debugserver/source/RNBRemote.cpp b/lldb/tools/debugserver/source/RNBRemote.cpp index 465abcb9076..ad5640d848a 100644 --- a/lldb/tools/debugserver/source/RNBRemote.cpp +++ b/lldb/tools/debugserver/source/RNBRemote.cpp @@ -3351,4 +3351,102 @@ RNBRemote::HandlePacket_qHostInfo (const char *p) strm << "ptrsize:" << std::dec << sizeof(void *) << ';'; return SendPacket (strm.str()); } +// +//struct ProcessInfo +//{ +// nub_process_t pid; +// std::string name; +// std::string user; +// std::string group; +// uint32_t cpu; // mach-o cpu type +// uint32_t sub; // mach-o cpu subtype +// +// void +// Clear() +// { +// pid = 0; +// name.clear(); +// user.clear(); +// group.clear(); +// cpu = 0; +// sub = 0; +// } +//}; +// +//static bool +//GetMacOSXProcessName (ProcessInfo &proc_info, +// const char *name_match) // can be NULL +//{ +// char process_name[MAXCOMLEN * 2 + 1]; +// int name_len = ::proc_name(proc_info.pid, process_name, MAXCOMLEN * 2); +// if (name_len == 0) +// return false; +// +// if (name_match == NULL || strcmp (name_match, process_name) == 0) +// { +// proc_info.name.assign (process_name, name_len); +// return true; +// } +// proc_info.name.clear(); +// return false; +//} +// +// +//static bool +//GetMacOSXProcessCPUType (ProcessInfo &proc_info) +//{ +// // Make a new mib to stay thread safe +// int mib[CTL_MAXNAME]={0,}; +// size_t mib_len = CTL_MAXNAME; +// if (::sysctlnametomib("sysctl.proc_cputype", mib, &mib_len)) +// return false; +// +// mib[mib_len] = proc_info.pid; +// mib_len++; +// +// cpu_type_t cpu = 0; +// cpu_type_t sub = 0; +// size_t cpu_len = sizeof(cpu); +// if (::sysctl (mib, mib_len, &cpu, &cpu_len, 0, 0) == 0) +// { +// switch (cpu) +// { +// case llvm::MachO::CPUTypeI386: sub = llvm::MachO::CPUSubType_I386_ALL; break; +// case llvm::MachO::CPUTypeX86_64: sub = llvm::MachO::CPUSubType_X86_64_ALL; break; +// default: break; +// } +// proc_info.cpu = cpu; +// proc_info.sub = sub; +// return true; +// } +// proc_info.cpu = 0; +// proc_info.sub = 0; +// return false; +//} + +rnb_err_t +RNBRemote::HandlePacket_qProcessInfo (const char *p) +{ + return RNBRemote::HandlePacket_UNIMPLEMENTED (p); +} + +rnb_err_t +RNBRemote::HandlePacket_qfProcessInfoAll (const char *p) +{ + return RNBRemote::HandlePacket_UNIMPLEMENTED (p); +} + +rnb_err_t +RNBRemote::HandlePacket_qfProcessInfoName (const char *p) +{ + return RNBRemote::HandlePacket_UNIMPLEMENTED (p); +} + +rnb_err_t +RNBRemote::HandlePacket_qsProcessInfo (const char *p) +{ + return RNBRemote::HandlePacket_UNIMPLEMENTED (p); +} + + |

