This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Add wcsftime()


Attached is a patch which contains changes and additions to implement
the wcsftime() function.
 
The approach taken was to edit strftime in such a way that it can be
compiled either to make strftime or wcsftime.  A large test program
was added to strftime.c which can test the particular version under
test.  This was run under RHEL5 with its native snprintf and swprintf
library functions to verify unchanged operation of strftime(), and the
new wcsftime().  (The work was done a few months ago when Newlib did
not have the required supporting swprintf() to use.  The test program
does not get built into the library, of course, requiring
_REGRESSION_TEST to be defined for the code to be used.)
 
In the process of making strftime() to be able to be double-compiled,
a few minor speed improvements came about from using snprintf
exclusively (it had been mostly used before) that allowed a couple
of recursions to be removed.
 
When I regenerated libc/time/Makefile.in, it seems to have deleted
several ac_ct... lines, along with a couple other changes that don't
seem
to relate to the changes made to Makefile.am.  I'm not sure why.
Perhaps
Jeff/Corinna should do their own re-gen to be sure that something isn't
off--although it builds fine for me with it under Cygwin.
 
Craig

Attachment: wcsftime.patch
Description: wcsftime.patch


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]