void-packages/srcpkgs/R/patches/ppc.patch

34 lines
1.2 KiB
Diff

From 1b588f18b1802de3370515181f9ba04a2dee3f42 Mon Sep 17 00:00:00 2001
From: maechler <maechler@00db46b3-68df-0310-9c12-caf00c1e9a41>
Date: Wed, 25 Mar 2020 09:06:23 +0000
Subject: [PATCH] update (1 / LDBL_EPSILON) to all __powerpc__
git-svn-id: https://svn.r-project.org/R/trunk@78054 00db46b3-68df-0310-9c12-caf00c1e9a41
---
src/main/arithmetic.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/main/arithmetic.c b/src/main/arithmetic.c
index fc7496a8908..196431c7675 100644
--- src/main/arithmetic.c
+++ src/main/arithmetic.c
@@ -1,6 +1,6 @@
/*
* R : A Computer Language for Statistical Data Analysis
- * Copyright (C) 1998--2019 The R Core Team.
+ * Copyright (C) 1998--2020 The R Core Team.
* Copyright (C) 2003--2019 The R Foundation
* Copyright (C) 1995--1997 Robert Gentleman and Ross Ihaka
*
@@ -178,8 +178,9 @@ void attribute_hidden InitArithmetic()
#if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE)
-# ifdef __PPC64__
+# ifdef __powerpc__
// PowerPC 64 (when gcc has -mlong-double-128) fails constant folding with LDOUBLE
+ // Debian Bug#946836 shows it is needed also for 32-bit ppc, not just __PPC64__
# define q_1_eps (1 / LDBL_EPSILON)
# else
static LDOUBLE q_1_eps = 1 / LDBL_EPSILON;