diff options
| author | Ulrich Drepper <drepper@redhat.com> | 1996-09-12 02:51:03 +0000 |
|---|---|---|
| committer | Ulrich Drepper <drepper@redhat.com> | 1996-09-12 02:51:03 +0000 |
| commit | f0f1bf8536fe660cb6230a22694f9b7e6b02605e (patch) | |
| tree | a26814737a9eb5d4d5f4b0144f2fe610057a5d62 | |
| parent | 158ff48e348ece17fbda4d9b3c152df2f7cc76d0 (diff) | |
| download | glibc-f0f1bf8536fe660cb6230a22694f9b7e6b02605e.tar.xz glibc-f0f1bf8536fe660cb6230a22694f9b7e6b02605e.zip | |
update from main archive 960911cvs/libc-960912
Thu Sep 12 03:35:27 1996 Ulrich Drepper <drepper@cygnus.com>
* sysdeps/unix/sysv/linux/i386/Dist: Remove init-first.h.
* sysdeps/unix/sysv/linux/m68k/Dist: Likewise.
* sysdeps/unix/sysv/linux/Dist: Add init-first.h.
1996-09-11 Paul Eggert <eggert@twinsun.com>
* strftime.c (strftime):
Handle E and O modifiers, required for POSIX.2 and XPG4.
Don't use sprintf to format numbers; this way, we can handle time_t
correctly regardless of whether it's signed.
Don't dump core if format ends in %.
In default %c format, use %e instead of %d, for POSIX.2 compatibility.
For %z:
Use tm_gmtoff if available.
Output nothing if tm_isdst is negative.
Output correct value even if arg is 1969-12-31 23:59:59 UTC.
Don't assume that UTC offset is less than 24 hours;
Posix requires support for 24 hours, and there's no point
limiting it at all.
(HAVE_TM_GMTOFF, TYPE_SIGNED, INT_STRLEN_BOUND): New macros.
(CHAR_BIT): Define if <limits.h> doesn't.
(tm_diff): New function.
(fmt, <stdio.h>): Remove; no longer used.
Thu Sep 12 02:21:44 1996 Ulrich Drepper <drepper@cygnus.com>
* db/Makefile: Add extra-libs-others variable so that shared
library is built in `others' pass.
* elf/Makefile: Likewise.
* math/Makefile: Likewise.
* resolv/Makefile: Likewise.
* Makefile (generated): Add version.info.h.
* time/checktab.awk: New file. From ADO 96k.
* time/iso3166.tab: Likewise.
* time/tzselect.ksh: Likewise.
* time/zone.tab: Likewise.
* stdio-common/vfprintf.c: Correct cleanup registration. We
cannot use a macro
1996-09-11 Paul Eggert <eggert@twinsun.com>
* time/time.h (tm_gmtoff, tm_zone): Prefix with `__' unless
__USE_BSD; this is required for ANSI C compatibility.
* manual/time.texi: Replace GMT by UTC, daylight savings by
daylight saving, timezone by time zone.
Rewrite description of %V to match ISO 8601.
Fix TZ Posix string example for US Eastern time.
Explain tzname[1] when DST isn't used.
Explain tzname when multiple abbreviations used (e.g. EST/EWT/EDT).
Explain that timezone's sign is opposite from tm_gmtoff, and that
timezone lacks DST adjustment whereas tm_gmtoff has it.
Deprecate tzname and timezone.
Tue Sep 10 14:46:16 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
Implement Roland McGrath's idea of how to put an .interp into
shared libraries.
* interp.c: New file.
* Makerules (interp-obj): New object, linked into every shared
library.
(common-generated): Add interp.so.
(CFLAGS-interp.c): Pass name of interpreter.
Tue Sep 10 21:09:35 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* db/Makefile: Fix typo.
Tue Sep 10 19:29:53 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* nss/db-Makefile ($(VAR_DB)/passwd.db): Look for multiple
occurences of the same uid, and only generate a mapping for the
first one.
Tue Sep 10 03:14:59 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/unix/sysv/linux/system.c: New file, to override
sysdeps/unix/system.c.
Tue Sep 10 15:05:40 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* Makefile (before-compile): Add version-info.h, needed to build
version.d.
Tue Sep 10 14:14:33 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* sysdeps/unix/sysv/linux/m68k/sysdep.S: Remove check for
EWOULDBLOCK, never true on Linux.
(__errno_location): New function.
[_LIBC_REENTRANT]: Set errno using __errno_location function.
* sysdeps/unix/sysv/linux/m68k/sysdep.h [PIC]: Add second
syscall_error handler for reentrant libc.
Tue Sep 10 13:27:49 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
* elf/Makefile (extra-objs): Add eval.so to get dependencies.
Wed Sep 11 04:40:57 1996 Ulrich Drepper <drepper@cygnus.com>
* time/tzset.c (__tzname_cur_max): Use type `size_t' to avoid
warning.
* time/tzfile.c (compute_tzname_max): Likewise.
| -rw-r--r-- | ChangeLog | 107 | ||||
| -rw-r--r-- | Makefile | 5 | ||||
| -rw-r--r-- | Makerules | 9 | ||||
| -rw-r--r-- | db/Makefile | 3 | ||||
| -rw-r--r-- | elf/Makefile | 5 | ||||
| -rw-r--r-- | hurd/Makefile | 2 | ||||
| -rw-r--r-- | libio/putc_u.c | 4 | ||||
| -rw-r--r-- | libio/stdio.h | 10 | ||||
| -rw-r--r-- | manual/time.texi | 96 | ||||
| -rw-r--r-- | math/Makefile | 1 | ||||
| -rw-r--r-- | nss/db-Makefile | 3 | ||||
| -rw-r--r-- | resolv/Makefile | 1 | ||||
| -rw-r--r-- | stdio-common/vfprintf.c | 17 | ||||
| -rw-r--r-- | sysdeps/generic/dl-cache.c | 86 | ||||
| -rw-r--r-- | sysdeps/mach/hurd/dl-cache.c | 24 | ||||
| -rw-r--r-- | sysdeps/unix/sysv/linux/Dist | 1 | ||||
| -rw-r--r-- | sysdeps/unix/sysv/linux/i386/Dist | 1 | ||||
| -rw-r--r-- | sysdeps/unix/sysv/linux/m68k/Dist | 1 | ||||
| -rw-r--r-- | sysdeps/unix/sysv/linux/m68k/sysdep.S | 39 | ||||
| -rw-r--r-- | sysdeps/unix/sysv/linux/m68k/sysdep.h | 20 | ||||
| -rw-r--r-- | time/Makefile | 3 | ||||
| -rw-r--r-- | time/strftime.c | 399 | ||||
| -rw-r--r-- | time/time.h | 28 | ||||
| -rw-r--r-- | time/tzfile.c | 2 | ||||
| -rw-r--r-- | time/tzset.c | 2 |
25 files changed, 679 insertions, 190 deletions
@@ -1,3 +1,110 @@ +Thu Sep 12 03:35:27 1996 Ulrich Drepper <drepper@cygnus.com> + + * sysdeps/unix/sysv/linux/i386/Dist: Remove init-first.h. + * sysdeps/unix/sysv/linux/m68k/Dist: Likewise. + * sysdeps/unix/sysv/linux/Dist: Add init-first.h. + +1996-09-11 Paul Eggert <eggert@twinsun.com> + + * strftime.c (strftime): + Handle E and O modifiers, required for POSIX.2 and XPG4. + Don't use sprintf to format numbers; this way, we can handle time_t + correctly regardless of whether it's signed. + Don't dump core if format ends in %. + In default %c format, use %e instead of %d, for POSIX.2 compatibility. + For %z: + Use tm_gmtoff if available. + Output nothing if tm_isdst is negative. + Output correct value even if arg is 1969-12-31 23:59:59 UTC. + Don't assume that UTC offset is less than 24 hours; + Posix requires support for 24 hours, and there's no point + limiting it at all. + (HAVE_TM_GMTOFF, TYPE_SIGNED, INT_STRLEN_BOUND): New macros. + (CHAR_BIT): Define if <limits.h> doesn't. + (tm_diff): New function. + (fmt, <stdio.h>): Remove; no longer used. + +Thu Sep 12 02:21:44 1996 Ulrich Drepper <drepper@cygnus.com> + + * db/Makefile: Add extra-libs-others variable so that shared + library is built in `others' pass. + * elf/Makefile: Likewise. + * math/Makefile: Likewise. + * resolv/Makefile: Likewise. + + * Makefile (generated): Add version.info.h. + + * time/checktab.awk: New file. From ADO 96k. + * time/iso3166.tab: Likewise. + * time/tzselect.ksh: Likewise. + * time/zone.tab: Likewise. + + * stdio-common/vfprintf.c: Correct cleanup registration. We + cannot use a macro + +1996-09-11 Paul Eggert <eggert@twinsun.com> + + * time/time.h (tm_gmtoff, tm_zone): Prefix with `__' unless + __USE_BSD; this is required for ANSI C compatibility. + * manual/time.texi: Replace GMT by UTC, daylight savings by + daylight saving, timezone by time zone. + Rewrite description of %V to match ISO 8601. + Fix TZ Posix string example for US Eastern time. + Explain tzname[1] when DST isn't used. + Explain tzname when multiple abbreviations used (e.g. EST/EWT/EDT). + Explain that timezone's sign is opposite from tm_gmtoff, and that + timezone lacks DST adjustment whereas tm_gmtoff has it. + Deprecate tzname and timezone. + +Tue Sep 10 14:46:16 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + Implement Roland McGrath's idea of how to put an .interp into + shared libraries. + * interp.c: New file. + * Makerules (interp-obj): New object, linked into every shared + library. + (common-generated): Add interp.so. + (CFLAGS-interp.c): Pass name of interpreter. + +Tue Sep 10 21:09:35 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * db/Makefile: Fix typo. + +Tue Sep 10 19:29:53 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * nss/db-Makefile ($(VAR_DB)/passwd.db): Look for multiple + occurences of the same uid, and only generate a mapping for the + first one. + +Tue Sep 10 03:14:59 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * sysdeps/unix/sysv/linux/system.c: New file, to override + sysdeps/unix/system.c. + +Tue Sep 10 15:05:40 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * Makefile (before-compile): Add version-info.h, needed to build + version.d. + +Tue Sep 10 14:14:33 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * sysdeps/unix/sysv/linux/m68k/sysdep.S: Remove check for + EWOULDBLOCK, never true on Linux. + (__errno_location): New function. + [_LIBC_REENTRANT]: Set errno using __errno_location function. + * sysdeps/unix/sysv/linux/m68k/sysdep.h [PIC]: Add second + syscall_error handler for reentrant libc. + +Tue Sep 10 13:27:49 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> + + * elf/Makefile (extra-objs): Add eval.so to get dependencies. + +Wed Sep 11 04:40:57 1996 Ulrich Drepper <drepper@cygnus.com> + + * time/tzset.c (__tzname_cur_max): Use type `size_t' to avoid + warning. + * time/tzfile.c (compute_tzname_max): Likewise. + Wed Sep 11 02:57:31 1996 Ulrich Drepper <drepper@cygnus.com> * configure.in: Quote $add_ons argument in loop to generated @@ -84,6 +84,7 @@ subdirs := $(filter mach,$(subdirs)) $(filter hurd,$(subdirs)) \ headers := errno.h sys/errno.h errnos.h limits.h values.h \ features.h gnu-versions.h libc-lock.h aux = sysdep $(libc-init) version +before-compile = $(objpfx)version-info.h echo-headers: subdir_echo-headers @@ -251,12 +252,12 @@ distribute := README INSTALL FAQ NOTES NEWS PROJECTS \ ansidecl.h mkinstalldirs move-if-change install-sh \ configure configure.in aclocal.m4 config.sub config.guess\ config.h.in config.make.in config-name.in Makefile.in \ - autolock.sh munch-tmpl.c munch.awk \ + autolock.sh munch-tmpl.c munch.awk interp.c \ sysdep.h set-hooks.h libc-symbols.h version.h shlib-versions \ rpm/Makefile rpm/template rpm/rpmrc distribute := $(strip $(distribute)) -generated := $(generated) stubs.h +generated := $(generated) stubs.h version-info.h README: README.template version.c ; # Make-dist should update README. @@ -316,6 +316,15 @@ else no-whole-archive = endif +interp-obj = $(common-objpfx)interp.so +$(interp-obj): $(common-objpfx)%.so: $(..)%.c + $(compile-command.c) +common-generated += interp.so +CFLAGS-interp.c = -D'RUNTIME_LINKER="$(slibdir)/$(rtld-installed-name)"' + +$(common-objpfx)libc.so: $(interp-obj) +$(patsubst %,$(objpfx)%.so,$(extra-libs)): $(interp-obj) + define build-shlib $(LINK.o) -shared -o $@ $(sysdep-LDFLAGS) $(config-LDFLAGS) \ -B$(csu-objpfx) \ diff --git a/db/Makefile b/db/Makefile index 37dc282893..0ed798b6cf 100644 --- a/db/Makefile +++ b/db/Makefile @@ -9,6 +9,7 @@ subdir-dirs = btree db hash mpool recno vpath %.c $(subdir-dirs) extra-libs := libdb +extra-libs-others := $(extra-libs) libdb-routines := bt_close bt_conv bt_debug bt_delete bt_get \ bt_open bt_overflow bt_page bt_put bt_search \ bt_seq bt_split bt_utils \ @@ -39,7 +40,7 @@ CFLAGS-hash_func.c := -Wno-unused # The db code outsmarts the compiler frequently. override CFLAGS += -Wno-uninitialized -ifeq ($(build_shared),yes) +ifeq ($(build-shared),yes) $(objpfx)makedb: $(objpfx)libdb.so$(libdb.so-version) else $(objpfx)makedb: $(objpfx)libdb.a diff --git a/elf/Makefile b/elf/Makefile index cf9eaa8cb4..cbb9c11f42 100644 --- a/elf/Makefile +++ b/elf/Makefile @@ -37,7 +37,8 @@ rtld-routines := rtld $(dl-routines) dl-sysdep dl-minimal distribute = $(rtld-routines:=.c) dynamic-link.h do-rel.h dl-machine.h \ soinit.c sofini.c ldd.sh.in eval.c -extra-libs = libdl +extra-libs = libdl +extra-libs-others = $(extra-libs) libdl-routines := dlopen dlclose dlsym dlerror dladdr @@ -46,7 +47,7 @@ all: # Make this the default target; it will be defined in Rules. include ../Makeconfig ifeq (yes,$(build-shared)) -extra-objs = $(rtld-routines:=.so) soinit.so sofini.so +extra-objs = $(rtld-routines:=.so) soinit.so sofini.so eval.so generated = librtld.so dl-allobjs.so install-others = $(slibdir)/$(rtld-installed-name) install-bin = ldd diff --git a/hurd/Makefile b/hurd/Makefile index 2f2e36defe..873e695297 100644 --- a/hurd/Makefile +++ b/hurd/Makefile @@ -49,7 +49,7 @@ routines = hurdstartup hurdinit \ privports \ msgportdemux \ fopenport \ - vpprintf \ + vpprintf \ ports-get ports-set hurdports hurdmsg \ $(sig) $(dtable) hurdinline port-cleanup report-wait sig = hurdsig hurdfault siginfo hurd-raise preempt-sig \ diff --git a/libio/putc_u.c b/libio/putc_u.c index 18bbd491d8..85912e583f 100644 --- a/libio/putc_u.c +++ b/libio/putc_u.c @@ -29,3 +29,7 @@ putc_unlocked (c, fp) CHECK_FILE (fp, EOF); return _IO_putc_unlocked (c, fp); } + +#ifdef _LIBC_REENTRANT +weak_alias (putc_unlocked, _IO_putc_unlocked) +#endif diff --git a/libio/stdio.h b/libio/stdio.h index ce3da7df4c..3b399e5502 100644 --- a/libio/stdio.h +++ b/libio/stdio.h @@ -237,12 +237,10 @@ extern int putchar_unlocked __P ((int)); # ifndef _LIBC # define getc_unlocked(fp) _IO_getc_unlocked (fp) # define getc_locked(fp) fgetc (fp) -# define getchar_unlocked() getc_unlocked (stdin) -# define getchar_locked() getc_locked (stdin) -# define getc(fp) getc_locked (fp) -# define putchar_unlocked(c) putc_unlocked (c, stdout) -# define putchar_locked(c) putc_locked (c, stdout) -# define putc(c, fp) putc_locked (c, fp) +# define getchar_unlocked() _IO_getc_unlocked (stdin) +# define getchar_locked() getc (stdin) +# define putchar_unlocked(c) _IO_putc_unlocked (c, stdout) +# define putchar_locked(c) putc (c, stdout) # endif #endif /* __USE_REENTRANT */ diff --git a/manual/time.texi b/manual/time.texi index f439840170..9da23fbfb3 100644 --- a/manual/time.texi +++ b/manual/time.texi @@ -318,10 +318,10 @@ about the local time zone. It has the following members: @table @code @item int tz_minuteswest -This is the number of minutes west of GMT. +This is the number of minutes west of UTC. @item int tz_dsttime -If nonzero, daylight savings time applies during some part of the year. +If nonzero, daylight saving time applies during some part of the year. @end table The @code{struct timezone} type is obsolete and should never be used. @@ -504,15 +504,17 @@ information is not available. @item long int tm_gmtoff This field describes the time zone that was used to compute this -broken-down time value; it is the amount you must add to the local time -in that zone to get GMT, in units of seconds. The value is like that of -the variable @code{timezone} (@pxref{Time Zone Functions}). You can -also think of this as the ``number of seconds west'' of GMT. The -@code{tm_gmtoff} field is a GNU library extension. +broken-down time value, including any adjustment for daylight saving; it +is the number of seconds that you must add to UTC to get local time. +You can also think of this as the number of seconds east of UTC. For +example, for U.S. Eastern Standard Time, the value is @code{-5*60*60}. +The @code{tm_gmtoff} field is derived from BSD and is a GNU library +extension; it is not visible in a strict ANSI C environment. @item const char *tm_zone -This field is the name for the time zone that was used to -compute this broken-down time value. It is a GNU library extension. +This field is the name for the time zone that was used to compute this +broken-down time value. Like @code{tm_gmtoff}, this field is a BSD and +GNU extension, and is not visible in a strict ANSI C environment. @end table @end deftp @@ -538,7 +540,7 @@ Zone Functions}. @deftypefun {struct tm *} gmtime (const time_t *@var{time}) This function is similar to @code{localtime}, except that the broken-down time is expressed as Coordinated Universal Time (UTC)---that is, as -Greenwich Mean Time (GMT) rather than relative to the local time zone. +Greenwich Mean Time (GMT)---rather than relative to the local time zone. Recall that calendar times are @emph{always} expressed in coordinated universal time. @@ -728,10 +730,9 @@ The hour and minute in decimal numbers using the format @code{%H:%M}. This format is a GNU extension. @item %s -The seconds since the epoch, i.e., 1 January 1970 00:00:00 UTC. Note +The seconds since the epoch, i.e., 1970-01-01 00:00:00 UTC. Note that this value is the number of seconds between the epoch and the -current date as defined by the @code{localtime} system call. It is not -changed by the @code{--date} option. +current date as defined by the @code{localtime} system call. This format is a GNU extension. @@ -754,11 +755,14 @@ the first Sunday as the first day of the first week. All days preceding the first Sunday in the year are considered to be in week @code{0}. @item %V -The week number of the current year as a decimal number, starting with -the first Monday as the first day of the first week. If the week -containing January 1 has four or more days in the new year it is -considered to be week @code{1}. Otherwise it is week @code{53} of the -previous year. This is standardized in @w{ISO 8601:1988}. +The @w{ISO 8601:1988} week number as a decimal number (range @code{00} +to @code{53}). ISO weeks start with Monday and end with Sunday. Week +01 of a year is the first week which has the majority of its days in +that year; this is equivalent to the week containing the year's first +Thursday, and it is also equivalent to the week containing January 4. +Week 01 of a year can contain days from the previous year. The week +before week 01 of a year is the last week (52 or 53) of the previous +year even if it contains days from the new year. @item %w The day of the week as a decimal number, Sunday being @code{0}. @@ -783,10 +787,9 @@ The year as a decimal number, but without a century (range @code{00} to The year as a decimal number, including the century. @item %z -@w{RFC 822}/@w{ISO 8601:1988} style numeric time zone (e.g., -0600 or -+0100), or nothing if no time zone is determinable. This value reflects -the @emph{current} time zone. It is not changed by the @code{--date} -option. +@w{RFC 822}/@w{ISO 8601:1988} style numeric time zone (e.g., +@code{-0600} or @code{+0100}), or nothing if no time zone is +determinable. @item %Z The time zone or name or abbreviation (empty if the time zone can't be @@ -822,9 +825,9 @@ for accessing the time zone are declared in @file{time.h}. @cindex time zone You should not normally need to set @code{TZ}. If the system is -configured properly, the default timezone will be correct. You might +configured properly, the default time zone will be correct. You might set @code{TZ} if you are using a computer over the network from a -different timezone, and would like times reported to you in the timezone +different time zone, and would like times reported to you in the time zone that local for you, rather than what is local for the computer. In POSIX.1 systems the value of the @code{TZ} variable can be of one of @@ -858,7 +861,7 @@ negative if it is east. The hour must be between @code{0} and @code{23}, and the minute and seconds between @code{0} and @code{59}. For example, here is how we would specify Eastern Standard Time, but -without any daylight savings time alternative: +without any daylight saving time alternative: @smallexample EST+5 @@ -872,11 +875,11 @@ The second format is used when there is Daylight Saving Time: The initial @var{std} and @var{offset} specify the standard time zone, as described above. The @var{dst} string and @var{offset} specify the name -and offset for the corresponding daylight savings time time zone; if the +and offset for the corresponding daylight saving time time zone; if the @var{offset} is omitted, it defaults to one hour ahead of standard time. -The remainder of the specification describes when daylight savings time is -in effect. The @var{start} field is when daylight savings time goes into +The remainder of the specification describes when daylight saving time is +in effect. The @var{start} field is when daylight saving time goes into effect and the @var{end} field is when the change is made back to standard time. The following formats are recognized for these fields: @@ -904,16 +907,16 @@ effect, the change to the other time occurs. If omitted, the default is For example, here is how one would specify the Eastern time zone in the United States, including the appropriate daylight saving time and its dates -of applicability. The normal offset from GMT is 5 hours; since this is +of applicability. The normal offset from UTC is 5 hours; since this is west of the prime meridian, the sign is positive. Summer time begins on the first Sunday in April |
