summaryrefslogtreecommitdiff
path: root/math/scilab/patches/patch-ad
blob: ab5306c2a0f08166a7797b4a07c9d73421f6b6c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
$NetBSD: patch-ad,v 1.2 1999/03/05 11:22:34 frueauf Exp $

--- ./routines/sparse/spConfig.h.orig	Sat Jul 18 22:31:40 1998
+++ ./routines/sparse/spConfig.h	Sat Aug  8 13:15:56 1998
@@ -430,5 +430,5 @@
 
 /* VAX machine constants */
-#ifdef vax
+#if  (defined(vax) && !defined(netbsd)) 
 #   define  MACHINE_RESOLUTION      6.93889e-18
 #   define  LARGEST_REAL            1.70141e+38
@@ -439,5 +439,5 @@
 
 /* MIPS machine constants */
-#ifdef mips
+#if (defined(mips) && !defined(netbsd)) 
 #   define  MACHINE_RESOLUTION      6.93889e-18
 #   define  LARGEST_REAL            1.70141e+38
@@ -469,5 +469,5 @@
 
 /* Sun machine constants */
-#ifdef sun
+#if (defined(sun) && !defined(netbsd))
 /* These values are rumored to be the correct values. */
 #   define  MACHINE_RESOLUTION      8.9e-15
@@ -478,5 +478,5 @@
 #endif
 /* DEC alpha machine constant*/
-#ifdef __alpha 
+#if (defined(__alpha) && !defined(netbsd)) 
 #   include <limits.h>
 #   include <float.h>
@@ -488,4 +488,13 @@
 #endif
 #ifdef linux
+#   include <limits.h>
+#   include <float.h>
+#   define  MACHINE_RESOLUTION      DBL_EPSILON
+#   define  LARGEST_REAL            DBL_MAX
+#   define  SMALLEST_REAL           DBL_MIN
+#   define  LARGEST_SHORT_INTEGER   SHRT_MAX
+#   define  LARGEST_LONG_INTEGER    LONG_MAX
+#endif
+#if defined(netbsd) || defined(freebsd)
 #   include <limits.h>
 #   include <float.h>