aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-03-16 00:08:09 +0000
committerUlrich Drepper <drepper@redhat.com>2004-03-16 00:08:09 +0000
commit6ac3639867e6ab13fa2d179cd5723483e5d92d60 (patch)
treefa2596687022a01d5b1d3ae67d3f248651ff576c
parent330aa7006317b2ae6a80ef795ebe1f204959e321 (diff)
downloadglibc-6ac3639867e6ab13fa2d179cd5723483e5d92d60.tar
glibc-6ac3639867e6ab13fa2d179cd5723483e5d92d60.tar.gz
glibc-6ac3639867e6ab13fa2d179cd5723483e5d92d60.tar.bz2
glibc-6ac3639867e6ab13fa2d179cd5723483e5d92d60.zip
Update.
2004-03-15 Ulrich Drepper <drepper@redhat.com> * sysdeps/sparc/fpu/bits/mathinline.h: Restore missing #ifdef. Patch by Richard Henderson. 2004-03-16 Jakub Jelinek <jakub@redhat.com> * sysdeps/generic/strtold_l.c (STRING_TYPE, STRTOLD, __STRTOLD, __STRTOD, INTERNAL, INTERNAL1): Define, use them. [! USE_WIDE_CHAR] (INTERNAL (__STRTOLD)): Add libc_hidden_def. * inet/getnameinfo.c: Include stdlib.h.
-rw-r--r--ChangeLog13
-rw-r--r--inet/getnameinfo.c1
-rw-r--r--sysdeps/generic/strtold_l.c36
-rw-r--r--sysdeps/sparc/fpu/bits/mathinline.h6
4 files changed, 45 insertions, 11 deletions
diff --git a/ChangeLog b/ChangeLog
index 88776587e2..37ddddc39c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2004-03-15 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/sparc/fpu/bits/mathinline.h: Restore missing #ifdef.
+ Patch by Richard Henderson.
+
+2004-03-16 Jakub Jelinek <jakub@redhat.com>
+
+ * sysdeps/generic/strtold_l.c (STRING_TYPE, STRTOLD, __STRTOLD,
+ __STRTOD, INTERNAL, INTERNAL1): Define, use them.
+ [! USE_WIDE_CHAR] (INTERNAL (__STRTOLD)): Add libc_hidden_def.
+
+ * inet/getnameinfo.c: Include stdlib.h.
+
2004-03-15 Richard Henderson <rth@redhat.com>
* math/Makefile (headers): Add bits/huge_valf.h, bits/huge_vall.h,
diff --git a/inet/getnameinfo.c b/inet/getnameinfo.c
index 447980d5d9..e62d5759b8 100644
--- a/inet/getnameinfo.c
+++ b/inet/getnameinfo.c
@@ -38,6 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <alloca.h>
#include <errno.h>
#include <netdb.h>
+#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <unistd.h>
diff --git a/sysdeps/generic/strtold_l.c b/sysdeps/generic/strtold_l.c
index e43654700f..690a8a92eb 100644
--- a/sysdeps/generic/strtold_l.c
+++ b/sysdeps/generic/strtold_l.c
@@ -20,21 +20,39 @@
#include <stdlib.h>
#include <xlocale.h>
-
-extern double ____strtod_l_internal (const char *, char **, int, __locale_t);
-
+#ifdef USE_WIDE_CHAR
+# define STRING_TYPE wchar_t
+# define STRTOLD wcstold_l
+# define __STRTOLD __wcstold_l
+# define __STRTOD __wcstod_l
+#else
+# define STRING_TYPE char
+# define STRTOLD strtold_l
+# define __STRTOLD __strtold_l
+# define __STRTOD __strtod_l
+#endif
+
+#define INTERNAL(x) INTERNAL1(x)
+#define INTERNAL1(x) __##x##_internal
+
+extern double INTERNAL (__STRTOD) (const STRING_TYPE *, STRING_TYPE **,
+ int, __locale_t);
/* There is no `long double' type, use the `double' implementations. */
long double
-____strtold_l_internal (const char *nptr, char **endptr, int group,
- __locale_t loc)
+INTERNAL (__STRTOLD) (const STRING_TYPE *nptr, STRING_TYPE **endptr,
+ int group, __locale_t loc)
{
- return ____strtod_l_internal (nptr, endptr, group, loc);
+ return INTERNAL (__STRTOD) (nptr, endptr, group, loc);
}
-
+#ifndef USE_WIDE_CHAR
+libc_hidden_def (INTERNAL (__STRTOLD))
+#endif
long double
-strtold (const char *nptr, char **endptr, __locale_t loc)
+weak_function
+__STRTOLD (const STRING_TYPE *nptr, STRING_TYPE **endptr, __locale_t loc)
{
- return ____strtod_l_internal (nptr, endptr, 0, loc);
+ return INTERNAL (__STRTOD) (nptr, endptr, 0, loc);
}
+weak_alias (__STRTOLD, STRTOLD)
diff --git a/sysdeps/sparc/fpu/bits/mathinline.h b/sysdeps/sparc/fpu/bits/mathinline.h
index 734ff0590d..fcbcf41f67 100644
--- a/sysdeps/sparc/fpu/bits/mathinline.h
+++ b/sysdeps/sparc/fpu/bits/mathinline.h
@@ -1,5 +1,5 @@
/* Inline math functions for SPARC.
- Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Jakub Jelinek <jakub@redhat.com>.
@@ -24,7 +24,9 @@
#include <bits/wordsize.h>
-#if defined __USE_ISOC99 && defined __GNUC__ && !__GNUC_PREREQ(3,0)
+#ifdef __GNUC__
+
+#if defined __USE_ISOC99 && !__GNUC_PREREQ(3,0)
# undef isgreater
# undef isgreaterequal
# undef isless