[Rcpp-commits] r3789 - in pkg/Rcpp: . inst inst/include src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sat Oct 6 05:44:18 CEST 2012
Author: edd
Date: 2012-10-06 05:44:18 +0200 (Sat, 06 Oct 2012)
New Revision: 3789
Modified:
pkg/Rcpp/ChangeLog
pkg/Rcpp/DESCRIPTION
pkg/Rcpp/inst/NEWS.Rd
pkg/Rcpp/inst/include/RcppCommon.h
pkg/Rcpp/src/exceptions.cpp
Log:
simplifying the clang++ by directly checking for exception_defines header -- with thanks to Martin Morgan
Modified: pkg/Rcpp/ChangeLog
===================================================================
--- pkg/Rcpp/ChangeLog 2012-10-04 11:36:25 UTC (rev 3788)
+++ pkg/Rcpp/ChangeLog 2012-10-06 03:44:18 UTC (rev 3789)
@@ -1,3 +1,11 @@
+2012-10-05 Dirk Eddelbuettel <edd at debian.org>
+
+ * src/exceptions.cpp: Applied patch by Martin Morgan which untangles
+ the clang includes driven by version, and uses direct tests for
+ presence of the header file
+ * inst/include/RcppCommon.h: No longer define CLANG version meta
+ variables as we can directly include the relevant header
+
2012-09-30 Dirk Eddelbuettel <edd at debian.org>
* DESCRIPTION: Release 0.9.14
Modified: pkg/Rcpp/DESCRIPTION
===================================================================
--- pkg/Rcpp/DESCRIPTION 2012-10-04 11:36:25 UTC (rev 3788)
+++ pkg/Rcpp/DESCRIPTION 2012-10-06 03:44:18 UTC (rev 3789)
@@ -1,6 +1,6 @@
Package: Rcpp
Title: Seamless R and C++ Integration
-Version: 0.9.14
+Version: 0.9.14.1
Date: $Date$
Author: Dirk Eddelbuettel and Romain Francois, with contributions
by Douglas Bates and John Chambers
Modified: pkg/Rcpp/inst/NEWS.Rd
===================================================================
--- pkg/Rcpp/inst/NEWS.Rd 2012-10-04 11:36:25 UTC (rev 3788)
+++ pkg/Rcpp/inst/NEWS.Rd 2012-10-06 03:44:18 UTC (rev 3789)
@@ -2,6 +2,15 @@
\title{News for Package 'Rcpp'}
\newcommand{\cpkg}{\href{http://CRAN.R-project.org/package=#1}{\pkg{#1}}}
+\section{Changes in Rcpp version 0.9.15 (2012-xx-yy)}{
+ \itemize{
+ \item Untangling the clang++ build issue about the location of the
+ exceptions header by directly checking for the include file -- an
+ approach provided by Martin Morgan in a kindly contributed patch
+ as unit tests for them.
+ }
+}
+
\section{Changes in Rcpp version 0.9.14 (2012-09-30)}{
\itemize{
\item Added new Rcpp sugar functions trunc(), round() and signif(), as well
Modified: pkg/Rcpp/inst/include/RcppCommon.h
===================================================================
--- pkg/Rcpp/inst/include/RcppCommon.h 2012-10-04 11:36:25 UTC (rev 3788)
+++ pkg/Rcpp/inst/include/RcppCommon.h 2012-10-06 03:44:18 UTC (rev 3789)
@@ -95,15 +95,15 @@
#endif
#endif
-#ifdef __clang__
- #define CLANG_VERSION (__clang_major__ * 10000 + __clang_minor__ * 100 + __clang_patchlevel__)
- #if CLANG_VERSION < 30000
- #define IS_EARLIER_THAN_CLANG_300
- #endif
- #if CLANG_VERSION >= 30000
- #define IS_CLANG_300_OR_LATER
- #endif
-#endif
+// #ifdef __clang__
+// #define CLANG_VERSION (__clang_major__ * 10000 + __clang_minor__ * 100 + __clang_patchlevel__)
+// #if CLANG_VERSION < 30000
+// #define IS_EARLIER_THAN_CLANG_300
+// #endif
+// #if CLANG_VERSION >= 30000
+// #define IS_CLANG_300_OR_LATER
+// #endif
+// #endif
#ifdef __INTEL_COMPILER
// This is based on an email by Alexey Stukalov who tested
Modified: pkg/Rcpp/src/exceptions.cpp
===================================================================
--- pkg/Rcpp/src/exceptions.cpp 2012-10-04 11:36:25 UTC (rev 3788)
+++ pkg/Rcpp/src/exceptions.cpp 2012-10-06 03:44:18 UTC (rev 3789)
@@ -66,7 +66,7 @@
// compilers
#ifdef RCPP_HAS_DEMANGLING
#include <typeinfo>
-#ifdef __GNUC__
+#if defined(__GNUC__) && !defined(__clang__)
#ifdef IS_EARLIER_THAN_GCC_460
#include <exception_defines.h>
#endif
@@ -75,11 +75,12 @@
#endif
#endif
#ifdef __clang__
- #ifdef IS_EARLIER_THAN_CLANG_300
+ #if __has_include(<exception_defines.h>)
#include <exception_defines.h>
- #endif
- #ifdef IS_CLANG_300_OR_LATER
+ #elif __has_include(<bits/exception_defines.h>)
#include <bits/exception_defines.h>
+ #else
+ #error clang could not find <exception_defines.h>
#endif
#endif
#include <cxxabi.h>
More information about the Rcpp-commits
mailing list