[Lldb-commits] [PATCH] D12396: Fix lldb build on older OSX versions after svn commit r244716
Dawn Perchik via lldb-commits
lldb-commits at lists.llvm.org
Wed Aug 26 18:35:58 PDT 2015
dawn created this revision.
dawn added a reviewer: jasonmolenda.
dawn added a subscriber: lldb-commits.
dawn set the repository for this revision to rL LLVM.
Older OSX versions don't define NSOperatingSystemVersion, so building lldb gets:
../tools/lldb/tools/debugserver/source/MacOSX/MachProcess.mm:2032:5: error: unknown type name 'NSOperatingSystemVersion'
NSOperatingSystemVersion vers = [[NSProcessInfo processInfo] operatingSystemVersion];
^
This patch fixes the build by having GetOSVersionNumbers return false if __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 101000, causing lldb to behave the same as it did before this patch.
Repository:
rL LLVM
http://reviews.llvm.org/D12396
Files:
tools/debugserver/source/MacOSX/MachProcess.mm
Index: tools/debugserver/source/MacOSX/MachProcess.mm
===================================================================
--- tools/debugserver/source/MacOSX/MachProcess.mm
+++ tools/debugserver/source/MacOSX/MachProcess.mm
@@ -2027,6 +2027,7 @@
{
bool success = false;
+#if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >= 101000)
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSOperatingSystemVersion vers = [[NSProcessInfo processInfo] operatingSystemVersion];
@@ -2040,6 +2041,7 @@
success = true;
[pool drain];
+#endif
return success;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D12396.33294.patch
Type: text/x-patch
Size: 597 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20150827/e7e3bb4f/attachment.bin>
More information about the lldb-commits
mailing list