diff options
author | Adrian Prantl <aprantl@apple.com> | 2019-09-04 17:23:15 +0000 |
---|---|---|
committer | Adrian Prantl <aprantl@apple.com> | 2019-09-04 17:23:15 +0000 |
commit | 2461061168f4ac4ca8a1823768a00d1c63355b1b (patch) | |
tree | 4e38a76bbb1f43efde95d83428162d3cafeb3469 /lldb/tools/debugserver/source/MacOSX | |
parent | 40fe351cf699eda8d7d9a72c7bbbb37cef7f3164 (diff) | |
download | bcm5719-llvm-2461061168f4ac4ca8a1823768a00d1c63355b1b.tar.gz bcm5719-llvm-2461061168f4ac4ca8a1823768a00d1c63355b1b.zip |
Upstream macCatalyst support in debugserver and the macOS dynamic loader
plugin.
Unfortunately the test is currently XFAILed because of missing changes
to the clang driver.
Differential Revision: https://reviews.llvm.org/D67124
llvm-svn: 370931
Diffstat (limited to 'lldb/tools/debugserver/source/MacOSX')
-rw-r--r-- | lldb/tools/debugserver/source/MacOSX/MachProcess.mm | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/lldb/tools/debugserver/source/MacOSX/MachProcess.mm b/lldb/tools/debugserver/source/MacOSX/MachProcess.mm index a53ac9dda92..652a531dab0 100644 --- a/lldb/tools/debugserver/source/MacOSX/MachProcess.mm +++ b/lldb/tools/debugserver/source/MacOSX/MachProcess.mm @@ -762,12 +762,16 @@ bool MachProcess::GetMachOInformationFromMemory( uint32_t major_version, minor_version, patch_version; if (const char *lc_platform = GetDeploymentInfo( lc, load_cmds_p, major_version, minor_version, patch_version)) { - // APPLE INTERNAL: macCatalyst support + // macCatalyst support. + // // This handles two special cases: - // 1. Zippered frameworks have two deployment info load commands. - // Make sure to select the requested one. - // 2. The xctest binary is a pure macOS binary but is launched with - // DYLD_FORCE_PLATFORM=6. + // + // 1. Frameworks that have both a PLATFORM_MACOS and a + // PLATFORM_MACCATALYST load command. Make sure to select + // the requested one. + // + // 2. The xctest binary is a pure macOS binary but is launched + // with DYLD_FORCE_PLATFORM=6. if (dyld_platform == PLATFORM_MACCATALYST && inf.mach_header.filetype == MH_EXECUTE && inf.min_version_os_name.empty() && @@ -782,10 +786,12 @@ bool MachProcess::GetMachOInformationFromMemory( inf.min_version_os_version = GetMacCatalystVersionString(); } else if (dyld_platform != PLATFORM_MACCATALYST && inf.min_version_os_name == "macosx") { - // This is a zippered binary and the process is not running as - // PLATFORM_MACCATALYST. Stick with the macosx load command - // that we've already processed, ignore this one, which is - // presumed to be a PLATFORM_MACCATALYST one. + // This is a binary with both PLATFORM_MACOS and + // PLATFORM_MACCATALYST load commands and the process is not + // running as PLATFORM_MACCATALYST. Stick with the + // "macosx" load command that we've already processed, + // ignore this one, which is presumed to be a + // PLATFORM_MACCATALYST one. } else { inf.min_version_os_name = lc_platform; inf.min_version_os_version = ""; |