summaryrefslogtreecommitdiff
path: root/mcon/U/d_dbl_dig.U
diff options
context:
space:
mode:
authorManoj Srivastava <srivasta@debian.org>2003-12-01 17:11:15 +0000
committerManoj Srivastava <srivasta@debian.org>2003-12-01 17:11:15 +0000
commit371472d9fb6a936149b105a6563a0550d35bdf1a (patch)
tree6d23751e44a7dddf4e29918551f1ea0513352622 /mcon/U/d_dbl_dig.U
Initial import of upstream branch
Initial import of upstream branch git-archimport-id: srivasta@debian.org--2003-primary/dist--upstream--3.70--base-0
Diffstat (limited to 'mcon/U/d_dbl_dig.U')
-rw-r--r--mcon/U/d_dbl_dig.U60
1 files changed, 60 insertions, 0 deletions
diff --git a/mcon/U/d_dbl_dig.U b/mcon/U/d_dbl_dig.U
new file mode 100644
index 0000000..12f824e
--- /dev/null
+++ b/mcon/U/d_dbl_dig.U
@@ -0,0 +1,60 @@
+?RCS: $Id: d_dbl_dig.U,v 3.0.1.1 1994/08/29 16:07:28 ram Exp $
+?RCS:
+?RCS: Copyright (c) 1991-1993, Raphael Manfredi
+?RCS:
+?RCS: You may redistribute only under the terms of the Artistic Licence,
+?RCS: as specified in the README file that comes with the distribution.
+?RCS: You may reuse parts of this distribution only within the terms of
+?RCS: that same Artistic Licence; a copy of which may be found at the root
+?RCS: of the source tree for dist 3.0.
+?RCS:
+?RCS: Original Author: Andy Dougherty <doughera@lafcol.lafayette.edu>
+?RCS:
+?RCS: $Log: d_dbl_dig.U,v $
+?RCS: Revision 3.0.1.1 1994/08/29 16:07:28 ram
+?RCS: patch32: created by ADO
+?RCS:
+?MAKE:d_dbl_dig: Myread contains cat rm Setvar i_limits i_float \
+ cppstdin cppflags cppminus
+?MAKE: -pick add $@ %<
+?S:d_dbl_dig:
+?S: This variable conditionally defines d_dbl_dig if this system's
+?S: header files provide DBL_DIG, which is the number of significant
+?S: digits in a double precision number.
+?S:.
+?C:HAS_DBL_DIG:
+?C: This symbol, if defined, indicates that this system's <float.h>
+?C: or <limits.h> defines the symbol DBL_DIG, which is the number
+?C: of significant digits in a double precision number. If this
+?C: symbol is not defined, a guess of 15 is usually pretty good.
+?C:.
+?H:#$d_dbl_dig HAS_DBL_DIG /* */
+?H:.
+?LINT:set d_dbl_dig
+: See if number of significant digits in a double precision number is known
+echo " "
+$cat >dbl_dig.c <<EOM
+#$i_limits I_LIMITS
+#$i_float I_FLOAT
+#ifdef I_LIMITS
+#include <limits.h>
+#endif
+#ifdef I_FLOAT
+#include <float.h>
+#endif
+#ifdef DBL_DIG
+printf("Contains DBL_DIG");
+#endif
+EOM
+$cppstdin $cppflags $cppminus < dbl_dig.c >dbl_dig.E 2>/dev/null
+if $contains 'DBL_DIG' dbl_dig.E >/dev/null 2>&1; then
+ echo "DBL_DIG found." >&4
+ val="$define"
+else
+ echo "DBL_DIG NOT found." >&4
+ val="$undef"
+fi
+$rm -f dbl_dig.?
+set d_dbl_dig
+eval $setvar
+