summary refs log tree commit diff
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2000-04-21 03:43:31 +0000
committerUlrich Drepper <drepper@redhat.com>2000-04-21 03:43:31 +0000
commita0edd63e7c41336220353a6055662f38f5429a50 (patch)
treeaba5d9cb1144e26c93d610a7ae7a5d4569416a6f
parentdfcaa6429a6cecc15ed49b5a92474c1f54f693c4 (diff)
downloadglibc-a0edd63e7c41336220353a6055662f38f5429a50.tar.gz
glibc-a0edd63e7c41336220353a6055662f38f5429a50.tar.xz
glibc-a0edd63e7c41336220353a6055662f38f5429a50.zip
Update.
2000-04-19  Jakub Jelinek  <jakub@redhat.com>

	* locale/programs/ld-ctype.c (ctype_output): Set size of the idx
	field to nelems * sizeof (uint32_t).
	* locale/programs/ld-address.c (address_output): Align word fields
	properly.
	* locale/programs/ld-monetary.c (monetary_output): Likewise.
	Don't restart idx pointers to idx end at the duo_int_curr_symbol
	field.
	Avoid giving arbitrary garbage in the crncystr field.
	Use sizeof(uint32_t) instead of 4 for len in uno_valid_from,
	uno_valid_to, duo_valid_from, duo_valid_to and conversion_rate
	fields.
	* locale/programs/ld-numeric.c (numeric_output): Likewise.
	Don't restart idx pointers to idx end at the decimal_point_wc field.
	* locale/programs/ld-time.c (time_output): week_1stday should be
	word, not byte.  Align it properly.

2000-04-19  H.J. Lu  <hjl@gnu.org>

	* csu/gmon-start.c (_start): Declared as "extern void".
	(etext): Likewise.

2000-04-18  Andreas Jaeger  <aj@suse.de>

	* manual/install.texi (Running make install): Don't mention utmpd
	anymore.

2000-04-18  Andreas Jaeger  <aj@suse.de>

	* linuxthreads/Versions: Use ld instead of ld.so.

	* elf/Makefile (ld-map): Use ld.map.

	* Versions.def: Use ld instead of ld.so.
	* elf/Versions: Likewise.
	* sysdeps/mach/hurd/Versions: Likewise.
-rw-r--r--ChangeLog38
-rw-r--r--Versions.def2
-rw-r--r--elf/Makefile2
-rw-r--r--elf/Versions2
-rw-r--r--linuxthreads/Versions2
-rw-r--r--linuxthreads/sysdeps/pthread/bits/libc-lock.h2
-rw-r--r--locale/programs/ld-address.c23
-rw-r--r--locale/programs/ld-ctype.c2
-rw-r--r--locale/programs/ld-monetary.c39
-rw-r--r--locale/programs/ld-numeric.c17
-rw-r--r--locale/programs/ld-time.c12
-rw-r--r--manual/install.texi6
-rw-r--r--sysdeps/mach/hurd/Versions2
13 files changed, 107 insertions, 42 deletions
diff --git a/ChangeLog b/ChangeLog
index d93ca18a0d..ec7e3f8191 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,41 @@
+2000-04-19  Jakub Jelinek  <jakub@redhat.com>
+
+	* locale/programs/ld-ctype.c (ctype_output): Set size of the idx
+	field to nelems * sizeof (uint32_t).
+	* locale/programs/ld-address.c (address_output): Align word fields
+	properly.
+	* locale/programs/ld-monetary.c (monetary_output): Likewise.
+	Don't restart idx pointers to idx end at the duo_int_curr_symbol
+	field.
+	Avoid giving arbitrary garbage in the crncystr field.
+	Use sizeof(uint32_t) instead of 4 for len in uno_valid_from,
+	uno_valid_to, duo_valid_from, duo_valid_to and conversion_rate
+	fields.
+	* locale/programs/ld-numeric.c (numeric_output): Likewise.
+	Don't restart idx pointers to idx end at the decimal_point_wc field.
+	* locale/programs/ld-time.c (time_output): week_1stday should be
+	word, not byte.  Align it properly.
+
+2000-04-19  H.J. Lu  <hjl@gnu.org>
+
+	* csu/gmon-start.c (_start): Declared as "extern void".
+	(etext): Likewise.
+
+2000-04-18  Andreas Jaeger  <aj@suse.de>
+
+	* manual/install.texi (Running make install): Don't mention utmpd
+	anymore.
+
+2000-04-18  Andreas Jaeger  <aj@suse.de>
+
+	* linuxthreads/Versions: Use ld instead of ld.so.
+
+	* elf/Makefile (ld-map): Use ld.map.
+
+	* Versions.def: Use ld instead of ld.so.
+	* elf/Versions: Likewise.
+	* sysdeps/mach/hurd/Versions: Likewise.
+
 2000-04-20  Andreas Jaeger  <aj@suse.de>
 
 	* elf/rtld.c (print_statistics): Move ifndef further up.
diff --git a/Versions.def b/Versions.def
index 14842e77dd..fd1a8c9cad 100644
--- a/Versions.def
+++ b/Versions.def
@@ -80,7 +80,7 @@ libutil {
 libdb1 {
   GLIBC_2.0
 }
-ld.so {
+ld {
   GLIBC_2.0
   GLIBC_2.1
   GLIBC_2.1.1
diff --git a/elf/Makefile b/elf/Makefile
index 8aae5e00fc..fc7ce789d1 100644
--- a/elf/Makefile
+++ b/elf/Makefile
@@ -50,7 +50,7 @@ include ../Makeconfig
 before-compile = $(objpfx)trusted-dirs.h
 
 ifeq ($(versioning),yes)
-ld-map		= $(common-objpfx)ld.so.map
+ld-map		= $(common-objpfx)ld.map
 endif
 
 ifeq (yes,$(build-shared))
diff --git a/elf/Versions b/elf/Versions
index 26fd7d62ae..374110c832 100644
--- a/elf/Versions
+++ b/elf/Versions
@@ -16,7 +16,7 @@ libc {
   }
 }
 
-ld.so {
+ld {
   GLIBC_2.0 {
     # global variables
     _dl_debug_impcalls; _dl_debug_fd;
diff --git a/linuxthreads/Versions b/linuxthreads/Versions
index 5579bea011..e8f7f4e30c 100644
--- a/linuxthreads/Versions
+++ b/linuxthreads/Versions
@@ -22,7 +22,7 @@ libc {
   }
 }
 
-ld.so {
+ld {
   GLIBC_2.0 {
     # Internal libc interface to libpthread
     __libc_internal_tsd_get; __libc_internal_tsd_set;
diff --git a/linuxthreads/sysdeps/pthread/bits/libc-lock.h b/linuxthreads/sysdeps/pthread/bits/libc-lock.h
index 479a2f7a32..29584ed4d8 100644
--- a/linuxthreads/sysdeps/pthread/bits/libc-lock.h
+++ b/linuxthreads/sysdeps/pthread/bits/libc-lock.h
@@ -209,6 +209,7 @@ extern int __pthread_mutexattr_destroy (pthread_mutexattr_t *__attr);
 extern int __pthread_mutexattr_settype (pthread_mutexattr_t *__attr,
 					int __kind);
 
+#ifdef __USE_UNIX98
 extern int __pthread_rwlock_init (pthread_rwlock_t *__rwlock,
 				  __const pthread_rwlockattr_t *__attr);
 
@@ -223,6 +224,7 @@ extern int __pthread_rwlock_wrlock (pthread_rwlock_t *__rwlock);
 extern int __pthread_rwlock_trywrlock (pthread_rwlock_t *__rwlock);
 
 extern int __pthread_rwlock_unlock (pthread_rwlock_t *__rwlock);
+#endif
 
 extern int __pthread_key_create (pthread_key_t *__key,
 				 void (*__destr_function) (void *));
diff --git a/locale/programs/ld-address.c b/locale/programs/ld-address.c
index 3b743638a8..da801d09d4 100644
--- a/locale/programs/ld-address.c
+++ b/locale/programs/ld-address.c
@@ -328,7 +328,7 @@ address_output (struct localedef_t *locale, struct charmap_t *charmap,
 		const char *output_path)
 {
   struct locale_address_t *address = locale->categories[LC_ADDRESS].address;
-  struct iovec iov[2 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS)];
+  struct iovec iov[3 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS)];
   struct locale_file data;
   uint32_t idx[_NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS)];
   size_t cnt = 0;
@@ -374,39 +374,46 @@ address_output (struct localedef_t *locale, struct charmap_t *charmap,
   ++cnt;
 
   idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+
+  /* Align following data */
+  iov[cnt].iov_base = (void *) "\0\0";
+  iov[cnt].iov_len = ((idx[cnt - 2] + 3) & ~3) - idx[cnt - 2];
+  idx[cnt - 2] = (idx[cnt - 2] + 3) & ~3;
+  ++cnt;
+
   iov[cnt].iov_base = (void *) &address->country_num;
   iov[cnt].iov_len = sizeof (uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) address->country_isbn;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) address->lang_name;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) address->lang_ab;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) address->lang_term;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) address->lang_lib;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
-  assert (cnt == 2 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS));
+  assert (cnt == 3 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS));
 
   write_locale_data (output_path, "LC_ADDRESS",
-		     2 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS), iov);
+		     3 + _NL_ITEM_INDEX (_NL_NUM_LC_ADDRESS), iov);
 }
 
 
diff --git a/locale/programs/ld-ctype.c b/locale/programs/ld-ctype.c
index 9cf4d2c5f5..8bef3ee7ca 100644
--- a/locale/programs/ld-ctype.c
+++ b/locale/programs/ld-ctype.c
@@ -796,7 +796,7 @@ ctype_output (struct localedef_t *locale, struct charmap_t *charmap,
   iov[0].iov_len = sizeof (data);
 
   iov[1].iov_base = (void *) idx;
-  iov[1].iov_len = sizeof (idx);
+  iov[1].iov_len = nelems * sizeof (uint32_t);
 
   idx[0] = iov[0].iov_len + iov[1].iov_len;
   offset = 0;
diff --git a/locale/programs/ld-monetary.c b/locale/programs/ld-monetary.c
index 7e99b3f514..dd5b51c777 100644
--- a/locale/programs/ld-monetary.c
+++ b/locale/programs/ld-monetary.c
@@ -361,7 +361,7 @@ monetary_output (struct localedef_t *locale, struct charmap_t *charmap,
 {
   struct locale_monetary_t *monetary
     = locale->categories[LC_MONETARY].monetary;
-  struct iovec iov[2 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY)];
+  struct iovec iov[3 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY)];
   struct locale_file data;
   uint32_t idx[_NL_ITEM_INDEX (_NL_NUM_LC_MONETARY)];
   size_t cnt = 0;
@@ -452,7 +452,7 @@ monetary_output (struct localedef_t *locale, struct charmap_t *charmap,
   ++cnt;
 
   idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
-  iov[cnt].iov_base = (void *) &monetary->crncystr;
+  iov[cnt].iov_base = (void *) monetary->crncystr;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
 
@@ -486,7 +486,7 @@ monetary_output (struct localedef_t *locale, struct charmap_t *charmap,
   iov[cnt].iov_len = 1;
   ++cnt;
 
-  idx[cnt - 2] = iov[0].iov_len + iov[1].iov_len;
+  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) monetary->duo_int_curr_symbol;
   iov[cnt].iov_len = strlen (iov[cnt].iov_base) + 1;
   ++cnt;
@@ -567,44 +567,51 @@ monetary_output (struct localedef_t *locale, struct charmap_t *charmap,
   ++cnt;
 
   idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+
+  /* Align following data */
+  iov[cnt].iov_base = (void *) "\0\0";
+  iov[cnt].iov_len = ((idx[cnt - 2] + 3) & ~3) - idx[cnt - 2];
+  idx[cnt - 2] = (idx[cnt - 2] + 3) & ~3;
+  ++cnt;
+
   iov[cnt].iov_base = (void *) &monetary->uno_valid_from;
-  iov[cnt].iov_len = 4;
+  iov[cnt].iov_len = sizeof(uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &monetary->uno_valid_to;
-  iov[cnt].iov_len = 4;
+  iov[cnt].iov_len = sizeof(uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &monetary->duo_valid_from;
-  iov[cnt].iov_len = 4;
+  iov[cnt].iov_len = sizeof(uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &monetary->duo_valid_to;
-  iov[cnt].iov_len = 4;
+  iov[cnt].iov_len = sizeof(uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) monetary->conversion_rate;
-  iov[cnt].iov_len = 8;
+  iov[cnt].iov_len = 2 * sizeof(uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &monetary->mon_decimal_point_wc;
   iov[cnt].iov_len = sizeof (uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &monetary->mon_thousands_sep_wc;
   iov[cnt].iov_len = sizeof (uint32_t);
   ++cnt;
 
-  assert (cnt == 2 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY));
+  assert (cnt == 3 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY));
 
   write_locale_data (output_path, "LC_MONETARY",
-		     2 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY), iov);
+		     3 + _NL_ITEM_INDEX (_NL_NUM_LC_MONETARY), iov);
 }
 
 
diff --git a/locale/programs/ld-numeric.c b/locale/programs/ld-numeric.c
index 017c41fdc2..80a557c317 100644
--- a/locale/programs/ld-numeric.c
+++ b/locale/programs/ld-numeric.c
@@ -133,7 +133,7 @@ numeric_output (struct localedef_t *locale, struct charmap_t *charmap,
 		const char *output_path)
 {
   struct locale_numeric_t *numeric = locale->categories[LC_NUMERIC].numeric;
-  struct iovec iov[2 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC)];
+  struct iovec iov[3 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC)];
   struct locale_file data;
   uint32_t idx[_NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC)];
   size_t cnt = 0;
@@ -163,19 +163,26 @@ numeric_output (struct localedef_t *locale, struct charmap_t *charmap,
   iov[cnt].iov_len = numeric->grouping_len;
   ++cnt;
 
-  idx[cnt - 2] = iov[0].iov_len + iov[1].iov_len;
+  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+
+  /* Align following data */
+  iov[cnt].iov_base = (void *) "\0\0";
+  iov[cnt].iov_len = ((idx[cnt - 2] + 3) & ~3) - idx[cnt - 2];
+  idx[cnt - 2] = (idx[cnt - 2] + 3) & ~3;
+  ++cnt;
+
   iov[cnt].iov_base = (void *) &numeric->decimal_point_wc;
   iov[cnt].iov_len = sizeof (uint32_t);
   ++cnt;
 
-  idx[cnt - 2] = idx[cnt - 3] + iov[cnt - 1].iov_len;
+  idx[cnt - 3] = idx[cnt - 4] + iov[cnt - 1].iov_len;
   iov[cnt].iov_base = (void *) &numeric->thousands_sep_wc;
   iov[cnt].iov_len = sizeof (uint32_t);
 
-  assert (cnt + 1 == 2 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC));
+  assert (cnt + 1 == 3 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC));
 
   write_locale_data (output_path, "LC_NUMERIC",
-		     2 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC), iov);
+		     3 + _NL_ITEM_INDEX (_NL_NUM_LC_NUMERIC), iov);
 }
 
 
diff --git a/locale/programs/ld-time.c b/locale/programs/ld-time.c
index 99e029c755..b42dba0100 100644
--- a/locale/programs/ld-time.c
+++ b/locale/programs/ld-time.c
@@ -502,7 +502,7 @@ time_output (struct localedef_t *locale, struct charmap_t *charmap,
   struct iovec iov[2 + _NL_ITEM_INDEX (_NL_NUM_LC_TIME)
 		  + time->num_era - 1
 		  + 2 * 99
-		  + 1 + time->num_era * 10 - 1];
+		  + 2 + time->num_era * 10 - 1];
   struct locale_file data;
   uint32_t idx[_NL_ITEM_INDEX (_NL_NUM_LC_TIME)];
   size_t cnt, last_idx, num, n;
@@ -811,8 +811,14 @@ time_output (struct localedef_t *locale, struct charmap_t *charmap,
   ++cnt;
   ++last_idx;
 
+  /* We must align the following data.  */
+  iov[2 + cnt].iov_base = (void *) "\0\0";
+  iov[2 + cnt].iov_len = ((idx[last_idx] + 3) & ~3) - idx[last_idx];
+  idx[last_idx] = (idx[last_idx] + 3) & ~3;
+  ++cnt;
+
   iov[2 + cnt].iov_base = (void *) &time->week_1stday;
-  iov[2 + cnt].iov_len = 1;
+  iov[2 + cnt].iov_len = sizeof(uint32_t);
   idx[1 + last_idx] = idx[last_idx] + iov[2 + cnt].iov_len;
   ++cnt;
   ++last_idx;
@@ -849,7 +855,7 @@ time_output (struct localedef_t *locale, struct charmap_t *charmap,
   assert (cnt == (_NL_ITEM_INDEX (_NL_NUM_LC_TIME)
 		  + time->num_era - 1
 		  + 2 * 99
-		  + 1 + time->num_era * 10 - 1));
+		  + 2 + time->num_era * 10 - 1));
   assert (last_idx  == _NL_ITEM_INDEX (_NL_NUM_LC_TIME));
 
   write_locale_data (output_path, "LC_TIME", 2 + cnt, iov);
diff --git a/manual/install.texi b/manual/install.texi
index 2ed9670261..dbbd2cccb5 100644
--- a/manual/install.texi
+++ b/manual/install.texi
@@ -274,12 +274,10 @@ paths for installation.  This is useful when setting up a chroot
 environment or preparing a binary distribution.  The directory should be
 specified with an absolute file name.
 
-Glibc 2.1 includes two daemons, @code{nscd} and @code{utmpd}, which you
+Glibc 2.2 includes a daemon called @code{nscd}, which you
 may or may not want to run.  @code{nscd} caches name service lookups; it
 can dramatically improve performance with NIS+, and may help with DNS as
-well.  @code{utmpd} allows programs that use the old format for the
-@file{utmp} file to coexist with new programs.  For more information see
-the file @file{login/README.utmpd}.
+well.
 
 One auxiliary program, @file{/usr/libexec/pt_chown}, is installed setuid
 @code{root}.  This program is invoked by the @code{grantpt} function; it
diff --git a/sysdeps/mach/hurd/Versions b/sysdeps/mach/hurd/Versions
index 863fa5069b..4cfbdfd1b7 100644
--- a/sysdeps/mach/hurd/Versions
+++ b/sysdeps/mach/hurd/Versions
@@ -9,7 +9,7 @@ libc {
   }
 }
 
-ld.so {
+ld {
   GLIBC_2.0 {
     # variables that must be shared with libc
     __hurd_sigthread_stack_base; __hurd_sigthread_stack_end;