summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/MacOSX-Kernel
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2012-05-08 01:45:38 +0000
committerGreg Clayton <gclayton@apple.com>2012-05-08 01:45:38 +0000
commit7051231709ac438a59b5b4577b93511584885794 (patch)
tree72e0e2af6ce771c65dd9171220075b812ae95f31 /lldb/source/Plugins/Process/MacOSX-Kernel
parentd6560a6384b9dc3c3e7189a60c117b2f0b5c0985 (diff)
downloadbcm5719-llvm-7051231709ac438a59b5b4577b93511584885794.tar.gz
bcm5719-llvm-7051231709ac438a59b5b4577b93511584885794.zip
<rdar://problem/11358639>
Switch over to the "*-apple-macosx" for desktop and "*-apple-ios" for iOS triples. Also make the selection process for auto selecting platforms based off of an arch much better. llvm-svn: 156354
Diffstat (limited to 'lldb/source/Plugins/Process/MacOSX-Kernel')
-rw-r--r--lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp21
1 files changed, 15 insertions, 6 deletions
diff --git a/lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp b/lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp
index 45ed9b5f854..3c08a147246 100644
--- a/lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp
+++ b/lldb/source/Plugins/Process/MacOSX-Kernel/ProcessKDP.cpp
@@ -71,13 +71,22 @@ ProcessKDP::CanDebug(Target &target, bool plugin_specified_by_name)
if (exe_module)
{
const llvm::Triple &triple_ref = target.GetArchitecture().GetTriple();
- if (triple_ref.getOS() == llvm::Triple::Darwin &&
- triple_ref.getVendor() == llvm::Triple::Apple)
+ switch (triple_ref.getOS())
{
- ObjectFile *exe_objfile = exe_module->GetObjectFile();
- if (exe_objfile->GetType() == ObjectFile::eTypeExecutable &&
- exe_objfile->GetStrata() == ObjectFile::eStrataKernel)
- return true;
+ case llvm::Triple::Darwin: // Should use "macosx" for desktop and "ios" for iOS, but accept darwin just in case
+ case llvm::Triple::MacOSX: // For desktop targets
+ case llvm::Triple::IOS: // For arm targets
+ if (triple_ref.getVendor() == llvm::Triple::Apple)
+ {
+ ObjectFile *exe_objfile = exe_module->GetObjectFile();
+ if (exe_objfile->GetType() == ObjectFile::eTypeExecutable &&
+ exe_objfile->GetStrata() == ObjectFile::eStrataKernel)
+ return true;
+ }
+ break;
+
+ default:
+ break;
}
}
return false;
OpenPOWER on IntegriCloud