]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - stdlib/strtold.c
hurd: Fix build
[thirdparty/glibc.git] / stdlib / strtold.c
index da9f92797b0736f35f73b063d0b26a1591914186..6a4e42812e39164238de1647ea2541a0db14c9fb 100644 (file)
@@ -1,6 +1,6 @@
 /* Read decimal floating point numbers.
    This file is part of the GNU C Library.
-   Copyright (C) 1995-2002,2003,2004,2006,2007 Free Software Foundation, Inc.
+   Copyright (C) 1995-2018 Free Software Foundation, Inc.
    Contributed by Ulrich Drepper <drepper@gnu.org>, 1995.
 
    The GNU C Library is free software; you can redistribute it and/or
    Lesser General Public License for more details.
 
    You should have received a copy of the GNU Lesser General Public
-   License along with the GNU C Library; if not, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
+   License along with the GNU C Library; if not, see
+   <http://www.gnu.org/licenses/>.  */
 
 /* The actual implementation for all floating point sizes is in strtod.c.
    These macros tell it to produce the `float' version, `strtof'.  */
 
-#include <bits/wordsize.h>
+#include <bits/floatn.h>
+#include <bits/long-double.h>
+
+#if __HAVE_FLOAT128 && !__HAVE_DISTINCT_FLOAT128
+# define strtof128 __hide_strtof128
+# define wcstof128 __hide_wcstof128
+#endif
+#if __HAVE_FLOAT64X_LONG_DOUBLE
+# define strtof64x __hide_strtof64x
+# define wcstof64x __hide_wcstof64x
+#endif
 
 #ifdef __LONG_DOUBLE_MATH_OPTIONAL
 # include <wchar.h>
@@ -63,3 +72,23 @@ long_double_symbol (libc, ____new_strtold_internal, __strtold_internal);
 libc_hidden_ver (____new_strtold_internal, __strtold_internal)
 # endif
 #endif
+
+#if __HAVE_FLOAT128 && !__HAVE_DISTINCT_FLOAT128
+# undef strtof128
+# undef wcstof128
+# ifdef USE_WIDE_CHAR
+weak_alias (NEW (wcstold), wcstof128)
+# else
+weak_alias (NEW (strtold), strtof128)
+# endif
+#endif
+
+#if __HAVE_FLOAT64X_LONG_DOUBLE
+# undef strtof64x
+# undef wcstof64x
+# ifdef USE_WIDE_CHAR
+weak_alias (NEW (wcstold), wcstof64x)
+# else
+weak_alias (NEW (strtold), strtof64x)
+# endif
+#endif