summaryrefslogtreecommitdiffstats
path: root/external/boost/clang-cl.patch.0
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--external/boost/clang-cl.patch.048
1 files changed, 48 insertions, 0 deletions
diff --git a/external/boost/clang-cl.patch.0 b/external/boost/clang-cl.patch.0
new file mode 100644
index 000000000..49259a0d5
--- /dev/null
+++ b/external/boost/clang-cl.patch.0
@@ -0,0 +1,48 @@
+--- boost/multi_array/base.hpp
++++ boost/multi_array/base.hpp
+@@ -222,7 +222,7 @@
+ // MSVC 2010 is broken in debug mode: it requires
+ // that an Output Iterator have output_iterator_tag in its iterator_category if
+ // that iterator is not bidirectional_iterator or random_access_iterator.
+-#if BOOST_WORKAROUND(BOOST_MSVC, >= 1600)
++#if BOOST_WORKAROUND(BOOST_MSVC, >= 1600) || defined __clang__
+ struct mutable_iterator_tag
+ : boost::random_access_traversal_tag, std::input_iterator_tag
+ {
+@@ -274,7 +274,7 @@
+ //
+ // iterator support
+ //
+-#if BOOST_WORKAROUND(BOOST_MSVC, >= 1600)
++#if BOOST_WORKAROUND(BOOST_MSVC, >= 1600) || defined __clang__
+ // Deal with VC 2010 output_iterator_tag requirement
+ typedef array_iterator<T,T*,mpl::size_t<NumDims>,reference,
+ mutable_iterator_tag> iterator;
+
+# clang-cl cannot use MSVC's ATOMIC_FLAG_INIT:
+--- boost/smart_ptr/detail/spinlock.hpp
++++ boost/smart_ptr/detail/spinlock.hpp
+@@ -43,7 +43,7 @@
+ #elif defined( BOOST_SP_USE_PTHREADS )
+ # include <boost/smart_ptr/detail/spinlock_pt.hpp>
+
+-#elif !defined( BOOST_NO_CXX11_HDR_ATOMIC )
++#elif !defined( BOOST_NO_CXX11_HDR_ATOMIC ) && !(defined __clang__ && defined _MSC_VER && _MSC_VER == 1916)
+ # include <boost/smart_ptr/detail/spinlock_std_atomic.hpp>
+
+ #elif defined(__GNUC__) && defined( __arm__ ) && !defined( __thumb__ )
+
+# 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()
+# ^
+--- boost/thread/detail/config.hpp
++++ boost/thread/detail/config.hpp
+@@ -396,7 +396,7 @@
+ #else //Use default
+ # if defined(BOOST_THREAD_PLATFORM_WIN32)
+ # if defined(BOOST_MSVC) || defined(BOOST_INTEL_WIN) \
+- || defined(__MINGW32__) || defined(MINGW32) || defined(BOOST_MINGW32)
++ || defined(__MINGW32__) || defined(MINGW32) || defined(BOOST_MINGW32) || defined __clang__
+ //For compilers supporting auto-tss cleanup
+ //with Boost.Threads lib, use Boost.Threads lib
+ # define BOOST_THREAD_USE_LIB