pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/math/R avoid computed static constant (which was in an...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/7d8f0654da3d
branches:  trunk
changeset: 504709:7d8f0654da3d
user:      markd <markd%pkgsrc.org@localhost>
date:      Mon Dec 19 12:51:50 2005 +0000

description:
avoid computed static constant (which was in any case the wrong value)
in log1p().  From R svn.  Should fix build on NetBSD-1.6.2.

diffstat:

 math/R/distinfo         |   3 ++-
 math/R/patches/patch-ae |  25 +++++++++++++++++++++++++
 2 files changed, 27 insertions(+), 1 deletions(-)

diffs (44 lines):

diff -r e3948caab521 -r 7d8f0654da3d math/R/distinfo
--- a/math/R/distinfo   Mon Dec 19 11:55:06 2005 +0000
+++ b/math/R/distinfo   Mon Dec 19 12:51:50 2005 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.27 2005/12/11 14:37:12 markd Exp $
+$NetBSD: distinfo,v 1.28 2005/12/19 12:51:50 markd Exp $
 
 SHA1 (R-2.2.0.tar.gz) = ebaafa21036877b4ee3d4de9d85cce20f5cf9cbc
 RMD160 (R-2.2.0.tar.gz) = 9f54eb83c34565cbc483d2ffcc7dcae730ca674a
@@ -7,4 +7,5 @@
 SHA1 (patch-ab) = b724b549cd9920865c4d4ae60c71dff48c4c0c06
 SHA1 (patch-ac) = ce9e1b9f3de07ea3724a1215cfe648770d5c09ca
 SHA1 (patch-ad) = 83c9b046822b1d350daec8739ca4ee2a6b7e1978
+SHA1 (patch-ae) = 1253bbd786dc912650598c4f11177de00a259fec
 SHA1 (patch-at) = d972e1072a7f6a30b5fbc2e5fa076bc5bdec5952
diff -r e3948caab521 -r 7d8f0654da3d math/R/patches/patch-ae
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/math/R/patches/patch-ae   Mon Dec 19 12:51:50 2005 +0000
@@ -0,0 +1,25 @@
+$NetBSD: patch-ae,v 1.11 2005/12/19 12:51:50 markd Exp $
+
+--- src/nmath/log1p.c.orig     2005-07-28 08:10:05.000000000 +1200
++++ src/nmath/log1p.c
+@@ -98,16 +98,17 @@ double log1p(double x)
+       -.33410026677731010351377066666666e-30,
+       +.63533936180236187354180266666666e-31,
+     };
+-    const static double xmin = -1 + sqrt(1/DBL_EPSILON);/*was sqrt(d1mach(4)); */
+ 
+ #ifdef NOMORE_FOR_THREADS
+     static int nlnrel = 0;
++    static double xmin = 0.0;
+ 
+-    if (nlnrel == 0) {/* initialize chebychev coefficients */
++    if (xmin == 0.0) xmin = -1 + sqrt(DBL_EPSILON);/*was sqrt(d1mach(4)); */
++    if (nlnrel == 0) /* initialize chebychev coefficients */
+       nlnrel = chebyshev_init(alnrcs, 43, DBL_EPSILON/20);/*was .1*d1mach(3)*/
+-    }
+ #else
+ # define nlnrel 22
++    const static double xmin = -0.999999985;
+ /* 22: for IEEE double precision where DBL_EPSILON =  2.22044604925031e-16 */
+ #endif
+ 



Home | Main Index | Thread Index | Old Index