summaryrefslogtreecommitdiff
path: root/modules/strptime
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2007-02-12 18:49:19 +0000
committerPaul Eggert <eggert@cs.ucla.edu>2007-02-12 18:49:19 +0000
commit3ac9552429c5a500717e1d3d129c32f7d0ea37a3 (patch)
treed4fdd783d13d128eb9982d352264195f37acb429 /modules/strptime
parent4bc8b69ccf12c40ba0eec577b18e24bdd3cbc945 (diff)
downloadgnulib-3ac9552429c5a500717e1d3d129c32f7d0ea37a3.tar.gz
New module 'time', so that apps can include <time.h> as per
POSIX and GNU instead of separate include files like time_r.h and timegm.h. This implementation tries out a simpler approach for replacing decls in standard include files (as compared to the string module), somewhat as an experiment. * config/srclist.txt: Comment out mktime.c for now. * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example since it doesn't apply any more. Use generic wording instead. * MODULES.html.sh (Support for systems lacking POSIX:2001): New module 'time'. * lib/time_.h, m4/time_h.m4, modules/time: New files. * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove. * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H. Don't include <sys/types.h>; no longer needed since we assume C89. * lib/mktime.c: Don't include "time_r.h"; no longer needed. * lib/strftime.c: Likewise. * lib/time_r.c: Likewise. * lib/nanosleep.c (nanosleep): #undef after include files, not before. * lib/nanosleep.c: Include <time.h> first, to check interface. * lib/strptime.c: Likewise. * lib/time_r.c: Likewise. * lib/timegm.c: Likewise. * lib/strptime.c: Don't include strptime.h or time_r.h; no longer needed. * lib/timegm.c: Don't include timegm.h; no longer needed. * lib/timespec.h: Don't include <sys/time.h> before <time.h>; time.h now handles any problems in that area. (struct timespec, nanosleep): Remove; time.h now arranges for these. * lib/xnanosleep.c: Don't include timespec.h; no longer needed now that time.h defines struct timespec. * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared. Set REPLACE_NANOSLEEP. Don't AC_DEFINE nanosleep; the time module now handles that. * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME. * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer needed. Set REPLACE_LOCALTIME. * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM. * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4. (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or nanosleep; time_h.m4 now does that. Don't require gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time module handles this now. * modules/getdate (Depends-on): Remove timespec. Add time. * modules/nanosleep (Depends-on): Likewise. * modules/stat-time (Depends-on): Likewise. * modules/nanosleep (Include): Include time.h, not timespec.h. * modules/strptime (Files): Remove lib/strptime.h. (Depends-on): Add extensions, time. (Include): Include time.h, not strptime.h. * modules/time_r (Files): Remove lib/time_r.h. (Depends-on): Add time. (Include): Include time.h, not time_r.h. * modules/timegm: Likewise. * modules/timespec (Description): Now does timespec-related decls of our own, instead of struct timespec itself. (Depends-on): Add time; remove extensions. (Maintainer): Add self. * modules/utimecmp (Depends-on): Add time; remove timespec. * modules/utimens (Depends-on): Likewise. * modules/xnanosleep (Depends-on): Likewise.
Diffstat (limited to 'modules/strptime')
-rw-r--r--modules/strptime5
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/strptime b/modules/strptime
index 690c762413..799170a3a8 100644
--- a/modules/strptime
+++ b/modules/strptime
@@ -2,16 +2,17 @@ Description:
Convert a string representation of time to a tm structure.
Files:
-lib/strptime.h
lib/strptime.c
m4/strptime.m4
m4/tm_gmtoff.m4
Depends-on:
+extensions
sys_time
string
strcase
stdbool
+time
time_r
configure.ac:
@@ -20,7 +21,7 @@ gl_FUNC_STRPTIME
Makefile.am:
Include:
-"strptime.h"
+<time.h>
License:
LGPL