diff options
author | David Seifert <soap@gentoo.org> | 2016-10-21 01:36:49 +0200 |
---|---|---|
committer | David Seifert <soap@gentoo.org> | 2016-10-21 01:38:48 +0200 |
commit | b066efd6375e70a8f412041473f32dc954e484b8 (patch) | |
tree | f2c3ba11e45a1de19c22e6e0eb559af54981a576 /sci-libs/beagle | |
parent | dev-util/artifactory-bin: version bump (diff) | |
download | gentoo-b066efd6375e70a8f412041473f32dc954e484b8.tar.gz gentoo-b066efd6375e70a8f412041473f32dc954e484b8.tar.bz2 gentoo-b066efd6375e70a8f412041473f32dc954e484b8.zip |
sci-libs/beagle: Allow for compiling with GCC 6
Gentoo-bug: 597342
* EAPI=6
* Fix patches to be -p1 compliant
Package-Manager: portage-2.3.2
Diffstat (limited to 'sci-libs/beagle')
-rw-r--r-- | sci-libs/beagle/beagle-3.0.3-r1.ebuild | 58 | ||||
-rw-r--r-- | sci-libs/beagle/files/beagle-3.0.3-fix-c++14.patch | 30 | ||||
-rw-r--r-- | sci-libs/beagle/files/beagle-3.0.3-gcc47.patch | 4 |
3 files changed, 90 insertions, 2 deletions
diff --git a/sci-libs/beagle/beagle-3.0.3-r1.ebuild b/sci-libs/beagle/beagle-3.0.3-r1.ebuild new file mode 100644 index 000000000000..f8122e2c48b4 --- /dev/null +++ b/sci-libs/beagle/beagle-3.0.3-r1.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=6 + +DESCRIPTION="Open BEAGLE, a versatile EC/GA/GP framework" +SRC_URI="mirror://sourceforge/beagle/${P}.tar.gz" +HOMEPAGE="http://beagle.gel.ulaval.ca/" + +SLOT="0" +LICENSE="LGPL-2.1" +KEYWORDS="~amd64 ~x86" +IUSE="doc examples static-libs" + +RDEPEND=" + sys-libs/zlib + !app-misc/beagle + !dev-libs/libbeagle" +DEPEND="${RDEPEND} + doc? ( app-doc/doxygen )" + +PATCHES=( + "${FILESDIR}/${PN}-3.0.3-gcc43.patch" + "${FILESDIR}/${PN}-3.0.3-gcc47.patch" + "${FILESDIR}/${PN}-3.0.3-fix-c++14.patch" +) + +src_prepare() { + default + sed -e "s:@LIBS@:@LIBS@ -lpthread:" \ + -i PACC/Threading/Makefile.in || die +} + +src_configure() { + econf \ + --enable-optimization \ + $(use_enable static-libs static) +} + +src_compile() { + default + use doc && emake doc +} + +src_install () { + use doc && local HTML_DOCS=( refman/. ) + if use examples; then + dodoc -r examples + docompress -x /usr/share/doc/${PF}/examples + fi + + default + + if ! use static-libs; then + find "${D}" -name '*.la' -delete || die + fi +} diff --git a/sci-libs/beagle/files/beagle-3.0.3-fix-c++14.patch b/sci-libs/beagle/files/beagle-3.0.3-fix-c++14.patch new file mode 100644 index 000000000000..896b58225890 --- /dev/null +++ b/sci-libs/beagle/files/beagle-3.0.3-fix-c++14.patch @@ -0,0 +1,30 @@ +Fix building with C++14, where destructors are noexcept(true) by default. +See also: https://bugs.gentoo.org/show_bug.cgi?id=597342 + +--- a/PACC/Threading/Thread.cpp ++++ b/PACC/Threading/Thread.cpp +@@ -79,6 +79,9 @@ + \attention If the destructor in the derived thread class (e.g. MyThread above) does not wait for thread termination, the potential hazardous situation is that the runtime system will have deleted all of its members before calling this destructor (in C++, class destructors are called in reversed sequence). Thus, the still running thread could access deleted data members with unpredictable and unexpected results. So beware! + */ + Threading::Thread::~Thread(void) ++#if __cplusplus >= 201103L ++ noexcept(false) ++#endif + { + lock(); + if(mThread) { +--- a/PACC/Threading/Thread.hpp ++++ b/PACC/Threading/Thread.hpp +@@ -53,7 +53,11 @@ + class Thread : public Condition { + public: + Thread(void); +- virtual ~Thread(void); ++ virtual ~Thread(void) ++#if __cplusplus >= 201103L ++ noexcept(false) ++#endif ++ ; + + void cancel(void); + bool isRunning(void) const; diff --git a/sci-libs/beagle/files/beagle-3.0.3-gcc47.patch b/sci-libs/beagle/files/beagle-3.0.3-gcc47.patch index cb3546c68a5c..b74fb32b9989 100644 --- a/sci-libs/beagle/files/beagle-3.0.3-gcc47.patch +++ b/sci-libs/beagle/files/beagle-3.0.3-gcc47.patch @@ -1,5 +1,5 @@ ---- beagle/include/beagle/RouletteT.hpp -+++ beagle/include/beagle/RouletteT.hpp +--- a/beagle/include/beagle/RouletteT.hpp ++++ b/beagle/include/beagle/RouletteT.hpp @@ -87,7 +87,7 @@ Beagle_StackTraceBeginM(); Beagle_AssertM(inWeight>=0.0); |