Unwind: make it build on Darwin again
The support for the LSB eh_frame_hdr extension was overzealous in trying to
include headers. Be more careful to permit building on Darwin.
git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@230837 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/src/Unwind/AddressSpace.hpp b/src/Unwind/AddressSpace.hpp
index f9e64ae..abcac41 100644
--- a/src/Unwind/AddressSpace.hpp
+++ b/src/Unwind/AddressSpace.hpp
@@ -55,11 +55,14 @@
extern EHTEntry __exidx_start;
extern EHTEntry __exidx_end;
#endif // !defined(_LIBUNWIND_IS_BAREMETAL)
+#endif // LIBCXXABI_ARM_EHABI
-#elif _LIBUNWIND_SUPPORT_DWARF_UNWIND
+#if defined(__linux__)
+#if _LIBUNWIND_SUPPORT_DWARF_UNWIND && _LIBUNWIND_SUPPORT_DWARF_INDEX
#include <link.h>
#include "EHHeaderParser.hpp"
-#endif // LIBCXXABI_ARM_EHABI
+#endif
+#endif
namespace libunwind {