Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r81420 - trunk/libs/multiprecision/config
From: john_at_[hidden]
Date: 2012-11-19 06:02:08


Author: johnmaddock
Date: 2012-11-19 06:02:06 EST (Mon, 19 Nov 2012)
New Revision: 81420
URL: http://svn.boost.org/trac/boost/changeset/81420

Log:
Configure checks need to verify GMP and MPFR versions.
Text files modified:
   trunk/libs/multiprecision/config/has_gmp.cpp | 12 ++++++++++++
   trunk/libs/multiprecision/config/has_mpfr.cpp | 15 ++++++++++++++-
   2 files changed, 26 insertions(+), 1 deletions(-)

Modified: trunk/libs/multiprecision/config/has_gmp.cpp
==============================================================================
--- trunk/libs/multiprecision/config/has_gmp.cpp (original)
+++ trunk/libs/multiprecision/config/has_gmp.cpp 2012-11-19 06:02:06 EST (Mon, 19 Nov 2012)
@@ -5,3 +5,15 @@
 
 #include <gmp.h>
 
+#ifdef __GNUC__
+#pragma message #__GNU_MP_VERSION
+#pragma message #__GNU_MP_VERSION_MINOR
+#endif
+
+#if (__GNU_MP_VERSION < 4) || ((__GNU_MP_VERSION == 4) && (__GNU_MP_VERSION_MINOR < 2))
+#error "Incompatible GMP version"
+#endif
+
+
+
+

Modified: trunk/libs/multiprecision/config/has_mpfr.cpp
==============================================================================
--- trunk/libs/multiprecision/config/has_mpfr.cpp (original)
+++ trunk/libs/multiprecision/config/has_mpfr.cpp 2012-11-19 06:02:06 EST (Mon, 19 Nov 2012)
@@ -1,7 +1,20 @@
-// Copyright John Maddock 2008.
+// Copyright John Maddock 2012.
 // Use, modification and distribution are subject to the
 // Boost Software License, Version 1.0. (See accompanying file
 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
 
 #include <mpfr.h>
 
+#ifdef __GNUC__
+#pragma message MPFR_VERSION_STRING
+#endif
+
+#if (__GNU_MP_VERSION < 4) || ((__GNU_MP_VERSION == 4) && (__GNU_MP_VERSION_MINOR < 2))
+#error "Incompatible GMP version"
+#endif
+
+#if (MPFR_VERSION < 3)
+#error "Incompatible MPFR version"
+#endif
+
+


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