mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
sci-astronomy/casacore: Allow for compiling with GCC 6
Gentoo-bug: 594186 Patch taken from upstream master branch Package-Manager: portage-2.3.0
This commit is contained in:
@@ -34,7 +34,10 @@ DEPEND="${RDEPEND}
|
||||
doc? ( app-doc/doxygen )
|
||||
test? ( sci-astronomy/casa-data sci-astronomy/sofa_c )"
|
||||
|
||||
PATCHES=( "${FILESDIR}/${PN}-disable-tpath-test.patch" )
|
||||
PATCHES=(
|
||||
"${FILESDIR}/${PN}-disable-tpath-test.patch"
|
||||
"${FILESDIR}/${PN}-2.1.0-fix-c++14.patch"
|
||||
)
|
||||
|
||||
pkg_pretend() {
|
||||
if [[ $(tc-getCC)$ == *gcc* ]] && [[ ${MERGE_TYPE} != binary ]]; then
|
||||
|
||||
45
sci-astronomy/casacore/files/casacore-2.1.0-fix-c++14.patch
Normal file
45
sci-astronomy/casacore/files/casacore-2.1.0-fix-c++14.patch
Normal file
@@ -0,0 +1,45 @@
|
||||
From 3a45f84ccb6f08270fd6fd299eaf1b5401199d77 Mon Sep 17 00:00:00 2001
|
||||
From: Tammo Jan Dijkema <T.J.Dijkema@gmail.com>
|
||||
Date: Fri, 18 Mar 2016 10:43:13 +0100
|
||||
Subject: [PATCH] Add std to isinf and isnan, fixes #337
|
||||
|
||||
---
|
||||
casa/BasicMath/Math.cc | 4 ++--
|
||||
casa/BasicMath/test/tMathNaN.cc | 2 +-
|
||||
2 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/casa/BasicMath/Math.cc b/casa/BasicMath/Math.cc
|
||||
index d1bd984..00659e3 100644
|
||||
--- a/casa/BasicMath/Math.cc
|
||||
+++ b/casa/BasicMath/Math.cc
|
||||
@@ -178,7 +178,7 @@ Bool isInf(Float val) {
|
||||
// infinite. I can only have access to Solaris, Linux and SGI machines to
|
||||
// determine this.
|
||||
#if defined(AIPS_LINUX)
|
||||
- return (isinf(Double(val)));
|
||||
+ return (std::isinf(Double(val)));
|
||||
#elif defined(AIPS_DARWIN)
|
||||
return (std::isinf(Double(val)));
|
||||
#elif defined(AIPS_SOLARIS) || defined(AIPS_IRIX)
|
||||
@@ -212,7 +212,7 @@ Bool isInf(Double val) {
|
||||
// infinite. I can only have access to Solaris, Linux and SGI machines to
|
||||
// determine this.
|
||||
#if defined(AIPS_LINUX)
|
||||
- return (isinf(Double(val)));
|
||||
+ return (std::isinf(Double(val)));
|
||||
#elif defined(AIPS_DARWIN)
|
||||
return (std::isinf(Double(val)));
|
||||
#elif defined(AIPS_SOLARIS) || defined(AIPS_IRIX)
|
||||
diff --git a/casa/BasicMath/test/tMathNaN.cc b/casa/BasicMath/test/tMathNaN.cc
|
||||
index f1a73bc..0c330d1 100644
|
||||
--- a/casa/BasicMath/test/tMathNaN.cc
|
||||
+++ b/casa/BasicMath/test/tMathNaN.cc
|
||||
@@ -43,7 +43,7 @@
|
||||
((*(Int *)(x) & 0x007fffff) != 0x00000000))
|
||||
|
||||
inline Bool isNaN_isnan(Float val) {
|
||||
- return (isnan(Double(val)));
|
||||
+ return (std::isnan(Double(val)));
|
||||
}
|
||||
|
||||
inline Bool isNaN_isnanf(const Float& val) {
|
||||
Reference in New Issue
Block a user