From a8ce247fc0c1c0efdd4a4f14b1d2ee1e128e0040 Mon Sep 17 00:00:00 2001 From: Michael Palimaka Date: Fri, 22 Jun 2012 10:03:08 +0000 Subject: Add patch from Debian to fix build with GCC 4.7, wrt bug #422895. (Portage version: 2.1.10.65/cvs/Linux x86_64) --- sci-mathematics/gmm/ChangeLog | 8 ++- sci-mathematics/gmm/files/gmm-4.1-gcc-4.7.patch | 67 +++++++++++++++++++++++++ sci-mathematics/gmm/gmm-4.1-r1.ebuild | 19 +++++++ 3 files changed, 93 insertions(+), 1 deletion(-) create mode 100644 sci-mathematics/gmm/files/gmm-4.1-gcc-4.7.patch create mode 100644 sci-mathematics/gmm/gmm-4.1-r1.ebuild (limited to 'sci-mathematics') diff --git a/sci-mathematics/gmm/ChangeLog b/sci-mathematics/gmm/ChangeLog index a54a3130a43d..cbca94571045 100644 --- a/sci-mathematics/gmm/ChangeLog +++ b/sci-mathematics/gmm/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for sci-mathematics/gmm # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/gmm/ChangeLog,v 1.23 2012/03/03 13:39:36 johu Exp $ +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/gmm/ChangeLog,v 1.24 2012/06/22 10:03:08 kensington Exp $ + +*gmm-4.1-r1 (22 Jun 2012) + + 22 Jun 2012; Michael Palimaka + +files/gmm-4.1-gcc-4.7.patch, +gmm-4.1-r1.ebuild: + Add patch from Debian to fix build with GCC 4.7, wrt bug #422895. 03 Mar 2012; Johannes Huber -gmm-3.1.ebuild: Remove old. diff --git a/sci-mathematics/gmm/files/gmm-4.1-gcc-4.7.patch b/sci-mathematics/gmm/files/gmm-4.1-gcc-4.7.patch new file mode 100644 index 000000000000..285fbc717dea --- /dev/null +++ b/sci-mathematics/gmm/files/gmm-4.1-gcc-4.7.patch @@ -0,0 +1,67 @@ +Description: fix FTBFS with gcc-4.7 +Author: Philipp Büttgenbach +Reviewed-by: Anton Gladky +Last-Update: 2012-04-20 + +--- a/include/gmm/gmm_except.h ++++ b/include/gmm/gmm_except.h +@@ -76,7 +76,7 @@ + } + # define GMM_THROW_(type, errormsg) { \ + std::stringstream msg; \ +- msg << "Error in "__FILE__ << ", line " \ ++ msg << "Error in " << __FILE__ << ", line " \ + << __LINE__ << " " << GMM_PRETTY_FUNCTION << ": \n" \ + << errormsg << ends; \ + throw (type)(msg.str()); \ +@@ -91,7 +91,7 @@ + } + # define GMM_THROW_(type, errormsg) { \ + std::stringstream msg; \ +- msg << "Error in "__FILE__ << ", line " \ ++ msg << "Error in " << __FILE__ << ", line " \ + << __LINE__ << " " << GMM_PRETTY_FUNCTION << ": \n" \ + << errormsg << ends; \ + ::abort(); \ +@@ -148,7 +148,7 @@ + + #define GMM_WARNING_MSG(level_, thestr) { \ + std::stringstream msg; \ +- msg << "Level " << level_ << " Warning in "__FILE__ << ", line " \ ++ msg << "Level " << level_ << " Warning in " << __FILE__ << ", line " \ + << __LINE__ << ": " << thestr << ends; \ + std::cerr << msg.str() << std::endl; \ + } +@@ -210,7 +210,7 @@ + #define GMM_TRACE_MSG(level_, thestr) { \ + GMM_TRACE_MSG_MPI { \ + std::stringstream msg; \ +- msg << "Trace " << level_ << " in "__FILE__ << ", line " \ ++ msg << "Trace " << level_ << " in " << __FILE__ << ", line " \ + << __LINE__ << ": " << thestr \ + << ends; \ + std::cout << msg.str() << std::endl; \ + +Description: fix FTBFS with gcc-4.7 +Author: Anton Gladky +Last-Update: 2012-05-25 + +--- a/include/gmm/gmm_vector.h ++++ b/include/gmm/gmm_vector.h +@@ -235,14 +235,14 @@ + template void wsvector::clean(double eps) { + iterator it = this->begin(), itf = it, ite = this->end(); + while (it != ite) { +- ++itf; if (gmm::abs(it->second) <= eps) erase(it); it = itf; ++ ++itf; if (gmm::abs(it->second) <= eps) base_type::erase(it); it = itf; + } + } + + template void wsvector::resize(size_type n) { + if (n < nbl) { + iterator it = this->begin(), itf = it, ite = this->end(); +- while (it != ite) { ++itf; if (it->first >= n) erase(it); it = itf; } ++ while (it != ite) { ++itf; if (it->first >= n) base_type::erase(it); it = itf; } + } + nbl = n; + } diff --git a/sci-mathematics/gmm/gmm-4.1-r1.ebuild b/sci-mathematics/gmm/gmm-4.1-r1.ebuild new file mode 100644 index 000000000000..561cc55643b2 --- /dev/null +++ b/sci-mathematics/gmm/gmm-4.1-r1.ebuild @@ -0,0 +1,19 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/gmm/gmm-4.1-r1.ebuild,v 1.1 2012/06/22 10:03:08 kensington Exp $ + +EAPI=4 + +inherit base + +DESCRIPTION="Generic C++ template library for sparse, dense and skyline matrices" +SRC_URI="http://download.gna.org/getfem/stable/${P}.tar.gz" +HOMEPAGE="http://www-gmm.insa-toulouse.fr/getfem/" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~x86 ~x86-fbsd ~amd64-linux ~x86-linux" +IUSE="" + +DOCS=( AUTHORS ) +PATCHES=( "${FILESDIR}/${P}-gcc-4.7.patch" ) -- cgit v1.2.3-65-gdbad