summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2002-09-06 00:25:50 +0000
committerEric Andersen <andersen@codepoet.org>2002-09-06 00:25:50 +0000
commite228070ee1857944afad5571eae50b8c6e2430c8 (patch)
tree3df4a3db9416cca9159be129d1aa14cf4a17d4b7
parent70ba13a96935d50f3790b0e7e674a74db15dea8d (diff)
Add in some weak aliases to allow C99 apps to compile w/o defining
_ISOC99_SOURCE, per what glibc does. -Erik
-rw-r--r--libm/fpmacros.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/libm/fpmacros.c b/libm/fpmacros.c
index 3dbc8a13c..10aa5bd41 100644
--- a/libm/fpmacros.c
+++ b/libm/fpmacros.c
@@ -20,6 +20,7 @@
**
***********************************************************************/
+#include <features.h>
#include "fp_private.h"
#define SIGN_MASK 0x80000000
@@ -223,6 +224,7 @@ long int __isinff ( float x )
}
return 0;
}
+weak_alias (__isinff, isinff)
long int __isinf ( double x )
{
@@ -232,6 +234,7 @@ long int __isinf ( double x )
}
return 0;
}
+weak_alias (__isinf, isinf)
#if 0
long int __isinfl ( long double x )
@@ -242,6 +245,9 @@ long int __isinfl ( long double x )
}
return 0;
}
+weak_alias (__isinfl, isinfl);
+#else
+weak_alias (__isinf, isinfl)
#endif
/***********************************************************************
@@ -264,12 +270,14 @@ long int __isnanf ( float x )
z.fval = x;
return (((z.lval&FEXP_MASK) == FEXP_MASK) && ((z.lval&FFRAC_MASK) != 0));
}
+weak_alias (__isnanf, isnanf);
long int __isnan ( double x )
{
long int class = __fpclassify(x);
return ( ( class == FP_SNAN ) || ( class == FP_QNAN ) );
}
+weak_alias (__isnan, isnan);
#if 0
long int __isnanl ( long double x )
@@ -277,5 +285,8 @@ long int __isnanl ( long double x )
long int class = __fpclassify(x);
return ( ( class == FP_SNAN ) || ( class == FP_QNAN ) );
}
+weak_alias (__isnanl, isnanl);
+#else
+weak_alias (__isnan, isnanl);
#endif