Minor libc++abi changes to make things build better with gcc.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@211748 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/src/cxa_default_handlers.cpp b/src/cxa_default_handlers.cpp
index 27ffb71..a26ea2a 100644
--- a/src/cxa_default_handlers.cpp
+++ b/src/cxa_default_handlers.cpp
@@ -13,6 +13,7 @@
 #include <new>
 #include <exception>
 #include "abort_message.h"
+#include "config.h" // For __sync_swap
 #include "cxxabi.h"
 #include "cxa_handlers.hpp"
 #include "cxa_exception.hpp"
diff --git a/src/cxa_demangle.cpp b/src/cxa_demangle.cpp
index c67e20f..2d07686 100644
--- a/src/cxa_demangle.cpp
+++ b/src/cxa_demangle.cpp
@@ -4893,8 +4893,8 @@
 
 }  // unnamed namespace
 
-__attribute__ ((__visibility__("default")))
 extern "C"
+__attribute__ ((__visibility__("default")))
 char*
 __cxa_demangle(const char* mangled_name, char* buf, size_t* n, int* status)
 {
diff --git a/src/cxa_handlers.cpp b/src/cxa_handlers.cpp
index 6c13fcd..674933b 100644
--- a/src/cxa_handlers.cpp
+++ b/src/cxa_handlers.cpp
@@ -14,6 +14,7 @@
 #include <new>
 #include <exception>
 #include "abort_message.h"
+#include "config.h"
 #include "cxxabi.h"
 #include "cxa_handlers.hpp"
 #include "cxa_exception.hpp"