summaryrefslogtreecommitdiffstats
path: root/win/tkWinPort.h
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-01-22 14:17:53 (GMT)
committernijtmans <nijtmans>2010-01-22 14:17:53 (GMT)
commit3998cf77ee9513d59f553516618187a6bccb697f (patch)
tree000910596afd8ed4fc7d62d3df7ec8d8b277d252 /win/tkWinPort.h
parent027efdef074cb8c116b5f9c888ad445ea692f654 (diff)
downloadtk-3998cf77ee9513d59f553516618187a6bccb697f.zip
tk-3998cf77ee9513d59f553516618187a6bccb697f.tar.gz
tk-3998cf77ee9513d59f553516618187a6bccb697f.tar.bz2
fix more gcc warnings: missing initializer
Eliminate use of __argc and __argv for CYGWIN Make cygwin configuration error into a warning: CYGWIN compilation works although there still are test failures.
Diffstat (limited to 'win/tkWinPort.h')
-rw-r--r--win/tkWinPort.h28
1 files changed, 16 insertions, 12 deletions
diff --git a/win/tkWinPort.h b/win/tkWinPort.h
index 8069f46..3a99c43 100644
--- a/win/tkWinPort.h
+++ b/win/tkWinPort.h
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkWinPort.h,v 1.12 2008/08/28 18:13:36 dgp Exp $
+ * RCS: @(#) $Id: tkWinPort.h,v 1.13 2010/01/22 14:17:53 nijtmans Exp $
*/
#ifndef _WINPORT
@@ -30,7 +30,12 @@
#include <string.h>
#include <limits.h>
#include <fcntl.h>
-#include <io.h>
+#ifdef __CYGWIN__
+# include <unistd.h>
+# include <wchar.h>
+#else
+# include <io.h>
+#endif
/*
* Need to block out this include for building extensions with MetroWerks
@@ -52,7 +57,15 @@
# define hypot _hypot
#endif /* _MSC_VER */
-#ifndef __GNUC__
+#ifdef __CYGWIN__
+# ifdef _UNICODE
+# define _tcsrchr wcsrchr
+# else
+# define _tcsrchr strrchr
+
+# endif
+#else
+# define wcscasecmp _wcsicmp
# define strncasecmp strnicmp
# define strcasecmp stricmp
#endif
@@ -117,13 +130,4 @@
#define TkpCreateNativeBitmap(display, source) None
#define TkpGetNativeAppBitmap(display, name, w, h) None
-/*
- * Define timezone for gettimeofday.
- */
-
-struct timezone {
- int tz_minuteswest;
- int tz_dsttime;
-};
-
#endif /* _WINPORT */