From bd54a4e2d4375e127edcec827c79e568aafb8df4 Mon Sep 17 00:00:00 2001 From: LLVM Packaging Team Date: Sun, 12 Mar 2017 08:49:18 +0000 Subject: [PATCH] unwind-chain-inclusion # Without this patch, the first local include of unwind.h might, with the # __has_include_next, try to include the one from the system. # It might be /usr/include/clang/3.4/include/unwind.h # Because of the #ifndef __CLANG_UNWIND_H, it might never include any declaration # from the system. Gbp-Pq: Name unwind-chain-inclusion.diff --- clang/lib/Headers/unwind.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/clang/lib/Headers/unwind.h b/clang/lib/Headers/unwind.h index 303d7928..44e10cc2 100644 --- a/clang/lib/Headers/unwind.h +++ b/clang/lib/Headers/unwind.h @@ -23,9 +23,6 @@ /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/ -#ifndef __CLANG_UNWIND_H -#define __CLANG_UNWIND_H - #if defined(__APPLE__) && __has_include_next() /* Darwin (from 11.x on) provide an unwind.h. If that's available, * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE, @@ -53,6 +50,9 @@ # endif #else +#ifndef __CLANG_UNWIND_H +#define __CLANG_UNWIND_H + #include #ifdef __cplusplus @@ -277,6 +277,7 @@ _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *); } #endif +#endif /* __CLANG_UNWIND_H */ + #endif -#endif /* __CLANG_UNWIND_H */ -- 2.30.2