This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Alpha build fix, locale-archive path fix


Hi!

open("/usr/lib/localelocale-archive", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
doesn't look right to me, unfortunately even with the fix below
glibc doesn't use the locale-archive:

rm -f /usr/lib/locale/locale-archive
localedef --add-to-archive en_US.iso885915
ln -sf /usr/lib/locale/locale-archive /usr/lib/localelocale-archive
LANG=en_US.iso885915 strace echo foo

open("/usr/lib/localelocale-archive", O_RDONLY|O_LARGEFILE) = 7
fstat64(7, {st_mode=S_IFREG|0644, st_size=291923, ...}) = 0
read(7, "\t\1\2\336\177\241\0@8\0\0\0\1\0\0\0\311\1\0\0\244\25\0"..., 56) = 56
mmap2(NULL, 9148, PROT_READ, MAP_SHARED, 7, 0) = 0x40013000
open("/usr/share/locale/locale.alias", O_RDONLY) = 9
fstat64(9, {st_mode=S_IFREG|0644, st_size=2601, ...}) = 0
mmap2(NULL, 2601, PROT_READ, MAP_SHARED, 9, 0) = 0x40016000
_llseek(9, 2601, [2601], SEEK_SET)      = 0
fstat64(9, {st_mode=S_IFREG|0644, st_size=2601, ...}) = 0
_llseek(9, 2601, [2601], SEEK_SET)      = 0
munmap(0x40016000, 2601)                = 0
close(9)                                = 0
open("/usr/lib/locale/en_US.iso885915/LC_IDENTIFICATION", O_RDONLY) = 9
fstat64(9, {st_mode=S_IFREG|0644, st_size=371, ...}) = 0
mmap2(NULL, 371, PROT_READ, MAP_PRIVATE, 9, 0) = 0x40016000
close(9)                                = 0

Will investigate.
Attached is a fix for Alpha too (not tested yet but IMHO it should work).

Another thing I came to when comparing nm -PD from older and current
libc.so's is that i386-*-linux* and i686-*-linux* configured glibc's
are not ABI compatible with each other (both ways) in the <bits/string*.h>
helper functions.
One e.g. exports __memcpy_by2 and lots of others while the other one exports
__memcpy_c and others.
I think we need to merge the two sets of helpers and export them from both
versions, so that -O0 compiled program linked against i386-*-linux* libc.so
will work against i686-*-linux* libc.so and vice versa.
What do you think?

2002-08-13  Jakub Jelinek  <jakub@redhat.com>

	* locale/loadarchive.c (archfname): Add missing slash.

	* sysdeps/generic/strtold.c (__strtold_internal): Add libc_hidden_def.
	* wcsmbs/wcstold.c (__wcstold_internal): Add libc_hidden_def.

--- libc/locale/loadarchive.c.jj	Tue Aug 13 01:59:13 2002
+++ libc/locale/loadarchive.c	Tue Aug 13 11:01:05 2002
@@ -39,7 +39,7 @@
 
 
 /* Name of the locale archive file.  */
-static const char archfname[] = LOCALEDIR "locale-archive";
+static const char archfname[] = LOCALEDIR "/locale-archive";
 
 
 /* Record of contiguous pages already mapped from the locale archive.  */
--- libc/sysdeps/generic/strtold.c.jj	Mon Jul  9 14:59:36 2001
+++ libc/sysdeps/generic/strtold.c	Tue Aug 13 06:49:45 2002
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2002 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -25,6 +25,7 @@ __strtold_internal (const char *nptr, ch
 {
   return __strtod_internal (nptr, endptr, group);
 }
+libc_hidden_def (__strtold_internal)
 
 long double
 strtold (const char *nptr, char **endptr)
--- libc/wcsmbs/wcstold.c.jj	Mon Jul  9 15:00:15 2001
+++ libc/wcsmbs/wcstold.c	Tue Aug 13 08:15:47 2002
@@ -52,6 +52,7 @@ __wcstold_internal (const wchar_t *nptr,
 {
   return __wcstod_internal (nptr, endptr, group);
 }
+libc_hidden_def (__wcstold_internal)
 
 long double
 wcstold (const wchar_t *nptr, wchar_t **endptr)

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]