Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/winsup
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2008-05-10 22:57:10 +0400
committerCorinna Vinschen <corinna@vinschen.de>2008-05-10 22:57:10 +0400
commit1563f79fa86aa3c5d9eae96e7e662a314c37928c (patch)
tree3a9c0993746854569e645fd4ed00ff016496dda0 /winsup
parent12b830981ec7ce2f78c5f70d9227ae3294cba54d (diff)
* Makefile.in (DLL_OFILES): Remove _def_time.o.
* libc/_def_time.c: Remove. Move definitions of _DefaultTimeLocale and _CurrentTimeLocale ... * libc/strptime.cc: ... here.
Diffstat (limited to 'winsup')
-rw-r--r--winsup/cygwin/ChangeLog7
-rw-r--r--winsup/cygwin/Makefile.in2
-rw-r--r--winsup/cygwin/libc/_def_time.c42
-rw-r--r--winsup/cygwin/libc/strptime.cc29
4 files changed, 35 insertions, 45 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 97e1b767a..fcde1c4ff 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,10 @@
+2008-05-10 Corinna Vinschen <corinna@vinschen.de>
+
+ * Makefile.in (DLL_OFILES): Remove _def_time.o.
+ * libc/_def_time.c: Remove. Move definitions of _DefaultTimeLocale
+ and _CurrentTimeLocale ...
+ * libc/strptime.cc: ... here.
+
2008-05-08 Corinna Vinschen <corinna@vinschen.de>
* include/sys/localedef.h: Remove.
diff --git a/winsup/cygwin/Makefile.in b/winsup/cygwin/Makefile.in
index 51b0eb38e..8e888d139 100644
--- a/winsup/cygwin/Makefile.in
+++ b/winsup/cygwin/Makefile.in
@@ -126,7 +126,7 @@ MT_SAFE_OBJECTS:=
# Please maintain this list in sorted order, with maximum files per 86 col line
#
DLL_OFILES:=assert.o autoload.o bsdlib.o ctype.o cxx.o cygheap.o cygthread.o \
- cygtls.o dcrt0.o debug.o _def_time.o devices.o dir.o dlfcn.o dll_init.o \
+ cygtls.o dcrt0.o debug.o devices.o dir.o dlfcn.o dll_init.o \
dtable.o environ.o errno.o exceptions.o exec.o external.o fcntl.o \
fhandler.o fhandler_clipboard.o fhandler_console.o fhandler_disk_file.o \
fhandler_dsp.o fhandler_fifo.o fhandler_floppy.o fhandler_mailslot.o \
diff --git a/winsup/cygwin/libc/_def_time.c b/winsup/cygwin/libc/_def_time.c
deleted file mode 100644
index 40dc16102..000000000
--- a/winsup/cygwin/libc/_def_time.c
+++ /dev/null
@@ -1,42 +0,0 @@
-/* $NetBSD: _def_time.c,v 1.9 2007/03/28 19:05:53 manu Exp $ */
-
-/*
- * Written by J.T. Conklin <jtc@NetBSD.org>.
- * Public domain.
- */
-
-#include <sys/cdefs.h>
-#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: _def_time.c,v 1.9 2007/03/28 19:05:53 manu Exp $");
-#endif /* LIBC_SCCS and not lint */
-
-#include <sys/localedef.h>
-#include <locale.h>
-
-_TimeLocale _DefaultTimeLocale =
-{
- {
- "Sun","Mon","Tue","Wed","Thu","Fri","Sat",
- },
- {
- "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday",
- "Friday", "Saturday"
- },
- {
- "Jan", "Feb", "Mar", "Apr", "May", "Jun",
- "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"
- },
- {
- "January", "February", "March", "April", "May", "June", "July",
- "August", "September", "October", "November", "December"
- },
- {
- "AM", "PM"
- },
- "%a %b %e %H:%M:%S %Y",
- "%m/%d/%y",
- "%H:%M:%S",
- "%I:%M:%S %p"
-};
-
-_TimeLocale *_CurrentTimeLocale = &_DefaultTimeLocale;
diff --git a/winsup/cygwin/libc/strptime.cc b/winsup/cygwin/libc/strptime.cc
index 3bed5ea87..e2f710ae9 100644
--- a/winsup/cygwin/libc/strptime.cc
+++ b/winsup/cygwin/libc/strptime.cc
@@ -63,8 +63,33 @@ typedef struct {
const char *t_fmt_ampm;
} _TimeLocale;
-extern _TimeLocale *_CurrentTimeLocale;
-extern _TimeLocale _DefaultTimeLocale;
+_TimeLocale _DefaultTimeLocale =
+{
+ {
+ "Sun","Mon","Tue","Wed","Thu","Fri","Sat",
+ },
+ {
+ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday",
+ "Friday", "Saturday"
+ },
+ {
+ "Jan", "Feb", "Mar", "Apr", "May", "Jun",
+ "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"
+ },
+ {
+ "January", "February", "March", "April", "May", "June", "July",
+ "August", "September", "October", "November", "December"
+ },
+ {
+ "AM", "PM"
+ },
+ "%a %b %e %H:%M:%S %Y",
+ "%m/%d/%y",
+ "%H:%M:%S",
+ "%I:%M:%S %p"
+};
+
+_TimeLocale *_CurrentTimeLocale = &_DefaultTimeLocale;
#endif
#define _ctloc(x) (_CurrentTimeLocale->x)