From 6b68df576344f24f549030604c5413eb2062551a Mon Sep 17 00:00:00 2001
From: Stephan Bergmann <sbergman@redhat.com>
Date: Fri, 4 Mar 2016 09:58:44 +0100
Subject: Adapt to more warnings being enabled for clang-cl

Change-Id: I62b1e2f5b4918514a7a04bb6a44e55fc21a475af
---
 external/boost/clang-cl.patch.0 | 76 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 76 insertions(+)

(limited to 'external')

diff --git a/external/boost/clang-cl.patch.0 b/external/boost/clang-cl.patch.0
index 934eb5797fdf..2dcabfe17711 100755
--- a/external/boost/clang-cl.patch.0
+++ b/external/boost/clang-cl.patch.0
@@ -40,6 +40,17 @@
  
      template <class T>
      struct numeric_limits : chrono_numeric_limits<typename remove_cv<T>::type>
+--- boost/config/stdlib/dinkumware.hpp
++++ boost/config/stdlib/dinkumware.hpp
+@@ -96,7 +96,7 @@
+ #include <exception>
+ #endif
+ #include <typeinfo>
+-#if ( (!_HAS_EXCEPTIONS && !defined(__ghs__)) || (!_HAS_NAMESPACE && defined(__ghs__)) ) && !defined(__TI_COMPILER_VERSION__) && !defined(__VISUALDSPVERSION__)
++#if ( (!_HAS_EXCEPTIONS && !defined(__ghs__)) || (!(defined _HAS_NAMESPACE && _HAS_NAMESPACE) && defined(__ghs__)) ) && !defined(__TI_COMPILER_VERSION__) && !defined(__VISUALDSPVERSION__)
+ #  define BOOST_NO_STD_TYPEINFO
+ #endif  
+ 
 --- boost/date_time/filetime_functions.hpp
 +++ boost/date_time/filetime_functions.hpp
 @@ -27,6 +27,16 @@
@@ -79,6 +90,28 @@
  #else
          system_time st;
          GetSystemTime(&st);
+--- boost/exception/exception.hpp
++++ boost/exception/exception.hpp
+@@ -5,7 +5,7 @@
+ 
+ #ifndef UUID_274DA366004E11DCB1DDFE2E56D89593
+ #define UUID_274DA366004E11DCB1DDFE2E56D89593
+-#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
++#if defined __GNUC__ && (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+ #pragma GCC system_header
+ #endif
+ #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+--- boost/math/special_functions/log1p.hpp
++++ boost/math/special_functions/log1p.hpp
+@@ -396,7 +396,7 @@
+          "log1p<%1%>(%1%)", 0, pol);
+    return ::log1p(x); 
+ }
+-#elif defined(_MSC_VER) && (BOOST_MSVC >= 1400)
++#elif defined(_MSC_VER) && defined BOOST_MSVC && (BOOST_MSVC >= 1400)
+ //
+ // You should only enable this branch if you are absolutely sure
+ // that your compilers optimizer won't mess this code up!!
 --- boost/multi_array/base.hpp
 +++ boost/multi_array/base.hpp
 @@ -222,7 +222,7 @@
@@ -128,6 +161,39 @@
  #else
  #include <_mingw.h>
  #if !defined __MINGW64_VERSION_MAJOR
+--- boost/smart_ptr/intrusive_ptr.hpp
++++ boost/smart_ptr/intrusive_ptr.hpp
+@@ -220,7 +220,7 @@
+     return a != b.get();
+ }
+ 
+-#if __GNUC__ == 2 && __GNUC_MINOR__ <= 96
++#if defined __GUNC__ && __GNUC__ == 2 && __GNUC_MINOR__ <= 96
+ 
+ // Resolve the ambiguity between our op!= and the one in rel_ops
+ 
+--- boost/smart_ptr/shared_ptr.hpp
++++ boost/smart_ptr/shared_ptr.hpp
+@@ -780,7 +780,7 @@
+     return a.get() != b.get();
+ }
+ 
+-#if __GNUC__ == 2 && __GNUC_MINOR__ <= 96
++#if defined __GUNC__ && __GNUC__ == 2 && __GNUC_MINOR__ <= 96
+ 
+ // Resolve the ambiguity between our op!= and the one in rel_ops
+ 
+--- boost/ratio/config.hpp
++++ boost/ratio/config.hpp
+@@ -13,7 +13,7 @@
+ #include <boost/cstdint.hpp>
+ 
+ 
+-#if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) || !defined(__GXX_EXPERIMENTAL_CXX0X__)
++#if defined __GNUC__ && (__GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) || !defined(__GXX_EXPERIMENTAL_CXX0X__))
+ #  if ! defined BOOST_NO_CXX11_U16STRING
+ #    define BOOST_NO_CXX11_U16STRING
+ #  endif
 
 # workdir/UnpackedTarball/boost/libs/thread/src/win32/thread.cpp(1006,36) :  error: dllimport cannot be applied to non-inline function definition
 #     BOOST_THREAD_DECL void __cdecl on_process_enter()
@@ -143,6 +209,16 @@
        //For compilers supporting auto-tss cleanup
              //with Boost.Threads lib, use Boost.Threads lib
  #           define BOOST_THREAD_USE_LIB
+--- boost/throw_exception.hpp
++++ boost/throw_exception.hpp
+@@ -1,6 +1,6 @@
+ #ifndef UUID_AA15E74A856F11E08B8D93F24824019B
+ #define UUID_AA15E74A856F11E08B8D93F24824019B
+-#if (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
++#if defined __GUNC__ && (__GNUC__*100+__GNUC_MINOR__>301) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
+ #pragma GCC system_header
+ #endif
+ #if defined(_MSC_VER) && !defined(BOOST_EXCEPTION_ENABLE_WARNINGS)
 --- boost/type_traits/has_nothrow_assign.hpp
 +++ boost/type_traits/has_nothrow_assign.hpp
 @@ -24,7 +24,7 @@
-- 
cgit