This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH v2 1/2] Y2038: make __mktime_internal compatible with __time64_t
On Sun, 17 Mar 2019, Lukasz Majewski wrote:
> Do you require following code in include/time.h for timelocal:
>
> #if defined __USE_MISC
> # if defined(__REDIRECT)
> extern int __REDIRECT (timelocal, (struct tm *__tp),
> __mktime64) __THROW);
> # else
> # define timelocal __mktime64
> # endif
> #endif
include/time.h is an *internal* header, so should not need to test __USE_*
or use __REDIRECT.
Something like that would be appropriate in the *installed* header
(time/time.h), under whatever __USE_* condition is set by _TIME_BITS=64,
but only at the later point where we're ready to add support for
_TIME_BITS=64 to the public headers and corresponding new public symbol
versions for the new ABIs.
By using something like that in the installed header you avoid any need to
define the name __timelocal64 anywhere.
--
Joseph S. Myers
joseph@codesourcery.com