summaryrefslogtreecommitdiffstats
path: root/newlib/libc
diff options
context:
space:
mode:
Diffstat (limited to 'newlib/libc')
-rw-r--r--newlib/libc/include/math.h8
-rw-r--r--newlib/libc/include/stdlib.h6
-rw-r--r--newlib/libc/stdlib/local.h9
3 files changed, 7 insertions, 16 deletions
diff --git a/newlib/libc/include/math.h b/newlib/libc/include/math.h
index 87b2626b5..3efdb3675 100644
--- a/newlib/libc/include/math.h
+++ b/newlib/libc/include/math.h
@@ -334,8 +334,8 @@ extern float log2f _PARAMS((float));
extern float hypotf _PARAMS((float, float));
#endif /* ! defined (_REENT_ONLY) */
-/* On platforms where long double math functions are supported. */
-#ifdef _HAVE_LDBL_MATH
+/* On platforms where long double equals double. */
+#ifdef _LDBL_EQ_DBL
/* Reentrant ANSI C functions. */
#ifndef __math_68881
extern long double atanl _PARAMS((long double));
@@ -400,14 +400,14 @@ extern long double lgammal _PARAMS((long double));
extern long double erfl _PARAMS((long double));
extern long double erfcl _PARAMS((long double));
#endif /* ! defined (_REENT_ONLY) */
-#else /* !_HAVE_LDBL_MATH */
+#else /* !_LDBL_EQ_DBL */
#ifdef __i386__
/* Other long double precision functions. */
extern _LONG_DOUBLE rintl _PARAMS((_LONG_DOUBLE));
extern long int lrintl _PARAMS((_LONG_DOUBLE));
extern _LONG_LONG_TYPE llrintl _PARAMS((_LONG_DOUBLE));
#endif /* __i386__ */
-#endif /* !_HAVE_LDBL_MATH */
+#endif /* !_LDBL_EQ_DBL */
#endif /* !defined (__STRICT_ANSI__) || defined(__cplusplus) || __STDC_VERSION__ >= 199901L */
diff --git a/newlib/libc/include/stdlib.h b/newlib/libc/include/stdlib.h
index 7dfb77983..8f7d31e18 100644
--- a/newlib/libc/include/stdlib.h
+++ b/newlib/libc/include/stdlib.h
@@ -199,11 +199,11 @@ int _EXFUN(_system_r,(struct _reent *, const char *));
_VOID _EXFUN(__eprintf,(const char *, const char *, unsigned int, const char *));
-/* On platforms where long double stdlib functions are supported. */
-#ifdef _HAVE_LDBL_STDLIB
+/* On platforms where long double equals double. */
+#ifdef _LDBL_EQ_DBL
extern long double strtold (const char *, char **);
extern long double wcstold (const wchar_t *, wchar_t **);
-#endif /* _HAVE_LDBL_STDLIB */
+#endif /* _LDBL_EQ_DBL */
_END_STD_C
diff --git a/newlib/libc/stdlib/local.h b/newlib/libc/stdlib/local.h
index 3e8eb02c6..703d70eed 100644
--- a/newlib/libc/stdlib/local.h
+++ b/newlib/libc/stdlib/local.h
@@ -63,13 +63,4 @@ int __iso_8859_index (const char *);
extern wchar_t __cp_conv[12][0x80];
int __cp_index (const char *);
-#include <float.h>
-
-/* Check if long double is as wide as double. */
-#if (!defined(__STRICT_ANSI__) || __STDC_VERSION__ > 199901L || \
- defined(__cplusplus)) && defined(LDBL_MANT_DIG) && \
- (DBL_MANT_DIG == LDBL_MANT_DIG && LDBL_MIN_EXP == DBL_MIN_EXP && \
- LDBL_MAX_EXP == DBL_MAX_EXP)
- #define _LDBL_EQ_DBL
-#endif
#endif