Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r61874 - in branches/release/boost/config: . compiler
From: dgregor_at_[hidden]
Date: 2010-05-09 08:32:34


Author: dgregor
Date: 2010-05-09 08:32:33 EDT (Sun, 09 May 2010)
New Revision: 61874
URL: http://svn.boost.org/trac/boost/changeset/61874

Log:
Merge Clang configuration for Boost.Config from trunk
Added:
   branches/release/boost/config/compiler/clang.hpp
      - copied, changed from r61626, /trunk/boost/config/compiler/clang.hpp
Properties modified:
   branches/release/boost/config/ (props changed)
Text files modified:
   branches/release/boost/config/compiler/clang.hpp | 5 ++---
   branches/release/boost/config/select_compiler_config.hpp | 5 +++++
   2 files changed, 7 insertions(+), 3 deletions(-)

Copied: branches/release/boost/config/compiler/clang.hpp (from r61626, /trunk/boost/config/compiler/clang.hpp)
==============================================================================
--- /trunk/boost/config/compiler/clang.hpp (original)
+++ branches/release/boost/config/compiler/clang.hpp 2010-05-09 08:32:33 EDT (Sun, 09 May 2010)
@@ -8,7 +8,7 @@
 
 // Clang compiler setup.
 
-#if __has_feature(cxx_exceptions)
+#if __has_feature(cxx_exceptions) && !defined(BOOST_NO_EXCEPTIONS)
 #else
 # define BOOST_NO_EXCEPTIONS
 #endif
@@ -60,6 +60,5 @@
 #define BOOST_NO_EXTERN_TEMPLATE
 
 #ifndef BOOST_COMPILER
-// NOTE: Clang does not expose a version number
-# define BOOST_COMPILER "Clang C++"
+# define BOOST_COMPILER "Clang version " __clang_version__
 #endif

Modified: branches/release/boost/config/select_compiler_config.hpp
==============================================================================
--- branches/release/boost/config/select_compiler_config.hpp (original)
+++ branches/release/boost/config/select_compiler_config.hpp 2010-05-09 08:32:33 EDT (Sun, 09 May 2010)
@@ -15,6 +15,7 @@
 // compilers we support:
 
 # define BOOST_CXX_GCCXML 0
+# define BOOST_CXX_CLANG 0
 # define BOOST_CXX_COMO 0
 # define BOOST_CXX_DMC 0
 # define BOOST_CXX_INTEL 0
@@ -49,6 +50,10 @@
 // Comeau C++
 # define BOOST_COMPILER_CONFIG "boost/config/compiler/comeau.hpp"
 
+#elif defined __clang__
+// Clang C++ emulates GCC, so it has to appear early.
+# define BOOST_COMPILER_CONFIG "boost/config/compiler/clang.hpp"
+
 #elif defined __DMC__
 // Digital Mars C++
 # define BOOST_COMPILER_CONFIG "boost/config/compiler/digitalmars.hpp"


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk