diff -cb /prog/tz/tzcode/asctime.c ./asctime.c *** /prog/tz/tzcode/asctime.c Mon Dec 15 15:36:35 2003 --- ./asctime.c Mon Apr 12 21:30:10 2004 *************** *** 1,3 **** --- 1,4 ---- + #include "pgtz.h" /* ** This file is in the public domain, so clarified as of ** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). diff -cb /prog/tz/tzcode/difftime.c ./difftime.c *** /prog/tz/tzcode/difftime.c Mon Dec 15 15:36:35 2003 --- ./difftime.c Mon Apr 12 21:30:13 2004 *************** *** 1,3 **** --- 1,4 ---- + #include "pgtz.h" /* ** This file is in the public domain, so clarified as of ** June 5, 1996 by Arthur David Olson (arthur_david_olson@nih.gov). diff -cb /prog/tz/tzcode/localtime.c ./localtime.c *** /prog/tz/tzcode/localtime.c Mon Dec 15 15:36:35 2003 --- ./localtime.c Mon Apr 12 21:29:47 2004 *************** *** 1,3 **** --- 1,8 ---- + #include "pgtz.h" + #undef open + #define timezone pg_timezone + #define USG_COMPAT + extern time_t pg_timezone; /* ** This file is in the public domain, so clarified as of ** 1996-06-05 by Arthur David Olson (arthur_david_olson@nih.gov). diff -cb /prog/tz/tzcode/zic.c ./zic.c *** /prog/tz/tzcode/zic.c Mon Dec 15 15:36:35 2003 --- ./zic.c Mon Apr 12 21:29:34 2004 *************** *** 1,4 **** --- 1,11 ---- static char elsieid[] = "@(#)zic.c 7.115"; + #include "pgtz.h" + #undef unlink + #undef TZDIR + #define TZDIR "data" + #ifdef WIN32 + #include + #endif #include "private.h" #include "locale.h" *************** *** 7,17 **** --- 14,26 ---- #if HAVE_SYS_STAT_H #include "sys/stat.h" #endif + #ifndef WIN32 #ifdef S_IRUSR #define MKDIR_UMASK (S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) #else #define MKDIR_UMASK 0755 #endif + #endif /* ** On some ancient hosts, predicates like `isspace(C)' are defined *************** *** 2234,2236 **** --- 2243,2258 ---- /* ** UNIX was a registered trademark of The Open Group in 2003. */ + + + #ifdef WIN32 + /* + * To run on win32 + */ + int link(const char *oldpath, const char *newpath) { + if (!CopyFileEx(oldpath, newpath, NULL, NULL, FALSE, 0)) { + return -1; + } + return 0; + } + #endif