From 88c14dcf4d4df04f3c12f7d506484993850c55ad Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Mon, 29 Jan 2007 23:12:55 +0000 Subject: * lib/strptime.h (strptime): Use 'restrict' for args where POSIX requires this. * lib/strptime.c (strptime): Likewise. Change license notice from LGPL to GPL, since gnulib-tool will change this as needed. Include if _LIBC is not defined, not if HAVE_CONFIG_H is defined. Include "strptime.h" first, to check interface. Do not #undef _LIBC and _NL_CURRENT. Do not include ; no longer needed. Include "time_r.h" and declare ptime_locale_status only if _LIBC is not defined. (__P): Remove unused macro. (match_string): Bring back glibc version, but use it only if _LIBC is defined. (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too. Remove unnecessary assertion and abort() call. Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc. * m4/strptime.m4: Fix serial number comment. (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF. * modules/strptime (Files): Add m4/tm_gmtoff.m4. (Depends-on): Add time_r. --- m4/strptime.m4 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'm4/strptime.m4') diff --git a/m4/strptime.m4 b/m4/strptime.m4 index 344ede3560..e1236b9339 100644 --- a/m4/strptime.m4 +++ b/m4/strptime.m4 @@ -1,10 +1,12 @@ -# strtol.m4 serial 4 -dnl Copyright (C) 2002, 2003, 2006 Free Software Foundation, Inc. +# strptime.m4 serial 2 +dnl Copyright (C) 2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. AC_DEFUN([gl_FUNC_STRPTIME], [ + AC_REQUIRE([AC_C_RESTRICT]) AC_REPLACE_FUNCS(strptime) + AC_REQUIRE([gl_TM_GMTOFF]) ]) -- cgit v1.2.1