From: khizmax Date: Thu, 25 Sep 2014 06:45:17 +0000 (+0400) Subject: Fix clang 3.4-3.5 64bit build (boost.atomic problem, see https://svn.boost.org/trac... X-Git-Tag: v2.0.0~291 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=5db6d9e828149308cb2d3bacf030443ccc490fed;p=libcds.git Fix clang 3.4-3.5 64bit build (boost.atomic problem, see https://svn.boost.org/trac/boost/ticket/9610) --- diff --git a/cds/compiler/clang/defs.h b/cds/compiler/clang/defs.h index 41e3e0f3..f2b3a046 100644 --- a/cds/compiler/clang/defs.h +++ b/cds/compiler/clang/defs.h @@ -14,7 +14,6 @@ # error "Compiler version error. Clang version 3.3.0 and above is supported" #endif - #if defined(_LIBCPP_VERSION) && !defined(CDS_USE_BOOST_ATOMIC) // Note: Clang libc++ atomic leads to program crash. // So, we use libcds atomic implementation @@ -23,6 +22,12 @@ #include +#if CDS_COMPILER_VERSION >= 30400 && CDS_COMPILER_VERSION < 30500 && CDS_PROCESSOR_ARCH == CDS_PROCESSOR_AMD64 + // Error compiling 64bit boost.atomic on clang 3.4 - 3.5 + // see https://svn.boost.org/trac/boost/ticket/9610 +# define BOOST_HAS_INT128 1 +#endif + #define alignof __alignof__ // C++11 inline namespace diff --git a/tests/cppunit/thread.h b/tests/cppunit/thread.h index 0cf4da76..68a02be9 100644 --- a/tests/cppunit/thread.h +++ b/tests/cppunit/thread.h @@ -3,6 +3,7 @@ #ifndef __CPPUNIT_THREAD_H #define __CPPUNIT_THREAD_H +#include #include "cppunit/cppunit_mini.h" #include #include