[Lldb-commits] [lldb] r334784 - Add support for PLATFORM_*SIMULATOR
Frederic Riss via lldb-commits
lldb-commits at lists.llvm.org
Thu Jun 14 19:50:45 PDT 2018
Author: friss
Date: Thu Jun 14 19:50:45 2018
New Revision: 334784
URL: http://llvm.org/viewvc/llvm-project?rev=334784&view=rev
Log:
Add support for PLATFORM_*SIMULATOR
The toolchain in Xcode 10 uses a new LC_BUILD_VERSION entry to identify
simulator binaries. Add support for reading those to debugserver.
The exisitng test testing that code is currently failling when run
with Xcode 10, no need for a new test.
Modified:
lldb/trunk/tools/debugserver/source/MacOSX/MachProcess.mm
Modified: lldb/trunk/tools/debugserver/source/MacOSX/MachProcess.mm
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/tools/debugserver/source/MacOSX/MachProcess.mm?rev=334784&r1=334783&r2=334784&view=diff
==============================================================================
--- lldb/trunk/tools/debugserver/source/MacOSX/MachProcess.mm (original)
+++ lldb/trunk/tools/debugserver/source/MacOSX/MachProcess.mm Thu Jun 14 19:50:45 2018
@@ -607,6 +607,11 @@ const char *MachProcess::GetDeploymentIn
}
}
#if defined (LC_BUILD_VERSION)
+#ifndef PLATFORM_IOSSIMULATOR
+#define PLATFORM_IOSSIMULATOR 7
+#define PLATFORM_TVOSSIMULATOR 8
+#define PLATFORM_WATCHOSSIMULATOR 9
+#endif
if (cmd == LC_BUILD_VERSION) {
struct build_version_command build_vers;
if (ReadMemory(load_command_address, sizeof(struct build_version_command),
@@ -621,10 +626,13 @@ const char *MachProcess::GetDeploymentIn
case PLATFORM_MACOS:
return "macosx";
case PLATFORM_IOS:
+ case PLATFORM_IOSSIMULATOR:
return "ios";
case PLATFORM_TVOS:
+ case PLATFORM_TVOSSIMULATOR:
return "tvos";
case PLATFORM_WATCHOS:
+ case PLATFORM_WATCHOSSIMULATOR:
return "watchos";
case PLATFORM_BRIDGEOS:
return "bridgeos";
More information about the lldb-commits
mailing list