+#endif // wxNEED_WX_TIME_H
+
+#ifndef wxCtime
+WXDLLEXPORT wxChar *wxCtime(const time_t *timep)
+{
+ static wxChar buf[128];
+
+ wxStrncpy( buf, wxConvertMB2WX( ctime( timep ) ), sizeof( buf ) );
+ buf[ sizeof( buf ) - 1 ] = _T('\0');
+
+ return buf;
+}
+#endif // wxCtime
+
+#endif // wxUSE_WCHAR_T
+
+// ----------------------------------------------------------------------------
+// functions which we may need even if !wxUSE_WCHAR_T
+// ----------------------------------------------------------------------------
+
+#ifndef wxStrtok
+
+WXDLLEXPORT wxChar * wxStrtok(wxChar *psz, const wxChar *delim, wxChar **save_ptr)
+{
+ if (!psz)
+ {
+ psz = *save_ptr;
+ if ( !psz )
+ return NULL;
+ }
+
+ psz += wxStrspn(psz, delim);
+ if (!*psz)
+ {
+ *save_ptr = (wxChar *)NULL;
+ return (wxChar *)NULL;
+ }
+
+ wxChar *ret = psz;
+ psz = wxStrpbrk(psz, delim);
+ if (!psz)
+ {
+ *save_ptr = (wxChar*)NULL;
+ }
+ else
+ {
+ *psz = wxT('\0');
+ *save_ptr = psz + 1;
+ }
+
+ return ret;
+}
+
+#endif // wxStrtok
+
+// ----------------------------------------------------------------------------
+// missing C RTL functions
+// ----------------------------------------------------------------------------
+
+#if (defined(__MWERKS__) && !defined(__MACH__) && (__MSL__ < 0x00008000)) || \
+ defined(__WXWINCE__)
+char *strdup(const char *s)
+{
+ char *dest = (char*) malloc( strlen( s ) + 1 ) ;
+ if ( dest )
+ strcpy( dest , s ) ;
+ return dest ;
+}
+#endif
+
+#if (defined(__MWERKS__) && !defined(__MACH__)) || (defined(__WXWINCE__) && _WIN32_WCE <= 211)
+
+int isascii( int c )
+{
+ return ( c >= 0 && c < 128 );
+}
+#endif
+
+#if defined(__WXWINCE__) && (_WIN32_WCE <= 211)
+#if (_WIN32_WCE < 300)
+void *calloc( size_t num, size_t size )
+{
+ void** ptr = (void **)malloc(num * size);
+ memset( ptr, 0, num * size);
+ return ptr;
+}