]> granicus.if.org Git - clang/commitdiff
On Darwin, use the system's <unwind.h> whenever it is
authorDouglas Gregor <dgregor@apple.com>
Tue, 24 Jan 2012 15:12:50 +0000 (15:12 +0000)
committerDouglas Gregor <dgregor@apple.com>
Tue, 24 Jan 2012 15:12:50 +0000 (15:12 +0000)
available. Clang's <unwind.h> isn't ready for prime time. Fixes
<rdar://problem/10733587>.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148807 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Headers/unwind.h

index cef20cc214732fb08b59b1e55ce798df77232f08..28ad8043f2a466f2663b8830fbf8a53ac324e350 100644 (file)
 
 /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
 
-#if defined(__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__) && \
-    __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ >=  1070
-/* Starting in OS X Lion the SDK includes a unwind.h. We should just use it. */
-#include_next <unwind.h>
+#if defined(__APPLE__) && __has_include_next(<unwind.h>)
+/* Darwin typically has its own unwind.h; use it. */
+#  include_next <unwind.h>
 #else
 
 #include <stdint.h>