diff options
author | nijtmans <nijtmans> | 2010-04-20 08:17:20 (GMT) |
---|---|---|
committer | nijtmans <nijtmans> | 2010-04-20 08:17:20 (GMT) |
commit | 64c4b08a44ece02ac3c52d893e73c98b5e8f6cc5 (patch) | |
tree | b14b56efeb6e96f005aa0454f988f6b043fc40ab | |
parent | f76376d447ad977082d1744f9e90040047b5d08e (diff) | |
download | tk-64c4b08a44ece02ac3c52d893e73c98b5e8f6cc5.zip tk-64c4b08a44ece02ac3c52d893e73c98b5e8f6cc5.tar.gz tk-64c4b08a44ece02ac3c52d893e73c98b5e8f6cc5.tar.bz2 |
Make sure that tkWinPort.h is always included
before tcl.h, otherwise the fallback for TCHAR
might go off before the inclusion of <tchar.h>
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | compat/stdlib.h | 6 | ||||
-rw-r--r-- | compat/unistd.h | 4 | ||||
-rw-r--r-- | generic/tkIntXlibDecls.h | 18 | ||||
-rw-r--r-- | generic/tkPort.h | 15 | ||||
-rw-r--r-- | win/tkWinPort.h | 14 |
6 files changed, 38 insertions, 27 deletions
@@ -1,3 +1,11 @@ +2010-04-20 Jan Nijtmans <nijtmans@users.sf.net> + + * generic/tkPort.h Make sure that tkWinPort.h is always included + * generic/tkIntXlibDecls.h before tcl.h, otherwise the fallback for TCHAR + * win/tkWinPort.h might go off before the inclusion of <tchar.h> + * compat/stdlib.h Include <tcl.h> only when not already done. + * compat/unistd.h + 2010-04-19 Jan Nijtmans <nijtmans@users.sf.net> * win/tkWinDialog.c Fix [Bug 2987995]: Tk_GetOpenFile returns garbage diff --git a/compat/stdlib.h b/compat/stdlib.h index 546e5ed..ea66007 100644 --- a/compat/stdlib.h +++ b/compat/stdlib.h @@ -13,13 +13,15 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: stdlib.h,v 1.4 2008/05/02 10:28:18 dkf Exp $ + * RCS: @(#) $Id: stdlib.h,v 1.5 2010/04/20 08:17:26 nijtmans Exp $ */ #ifndef _STDLIB #define _STDLIB -#include <tcl.h> +#ifndef _TCL +# include <tcl.h> +#endif extern void abort(void); extern double atof(const char *string); diff --git a/compat/unistd.h b/compat/unistd.h index cb9f8c3..396e17c 100644 --- a/compat/unistd.h +++ b/compat/unistd.h @@ -10,7 +10,7 @@ * no representations about the suitability of this software for any purpose. * It is provided "as is" without express or implied warranty. * - * RCS: @(#) $Id: unistd.h,v 1.3 2008/05/02 10:28:18 dkf Exp $ + * RCS: @(#) $Id: unistd.h,v 1.4 2010/04/20 08:17:26 nijtmans Exp $ */ #ifndef _UNISTD @@ -18,7 +18,7 @@ #include <sys/types.h> #ifndef _TCL -# include "tcl.h" +# include <tcl.h> #endif #ifndef NULL diff --git a/generic/tkIntXlibDecls.h b/generic/tkIntXlibDecls.h index 5ff2314..9d34993 100644 --- a/generic/tkIntXlibDecls.h +++ b/generic/tkIntXlibDecls.h @@ -9,12 +9,22 @@ * Copyright (c) 1998-1999 by Scriptics Corporation. * All rights reserved. * - * RCS: @(#) $Id: tkIntXlibDecls.h,v 1.29 2010/02/05 10:56:43 nijtmans Exp $ + * RCS: @(#) $Id: tkIntXlibDecls.h,v 1.30 2010/04/20 08:17:22 nijtmans Exp $ */ #ifndef _TKINTXLIBDECLS #define _TKINTXLIBDECLS +/* + * WARNING: This file is automatically generated by the tools/genStubs.tcl + * script. Any modifications to the function declarations below should be made + * in the generic/tkInt.decls script. + */ + +#ifndef _TCL +# include <tcl.h> +#endif + #include "X11/Xutil.h" #ifdef BUILD_tk @@ -22,12 +32,6 @@ #define TCL_STORAGE_CLASS DLLEXPORT #endif -/* - * WARNING: This file is automatically generated by the tools/genStubs.tcl - * script. Any modifications to the function declarations below should be made - * in the generic/tkInt.decls script. - */ - /* !BEGIN!: Do not edit below this line. */ /* diff --git a/generic/tkPort.h b/generic/tkPort.h index 17d0def..f19fb34 100644 --- a/generic/tkPort.h +++ b/generic/tkPort.h @@ -10,22 +10,19 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkPort.h,v 1.6 2004/04/24 06:00:18 das Exp $ + * RCS: @(#) $Id: tkPort.h,v 1.7 2010/04/20 08:17:20 nijtmans Exp $ */ #ifndef _TKPORT #define _TKPORT -#ifndef _TK -#include "tk.h" +#if defined(_WIN32) +# include "tkWinPort.h" #endif -#ifndef _TCL -#include "tcl.h" +#ifndef _TK +# include "tk.h" #endif - -#if defined(__WIN32__) || defined(_WIN32) -# include "tkWinPort.h" -#else +#if !defined(_WIN32) # if defined(MAC_OSX_TK) # include "tkMacOSXPort.h" # else diff --git a/win/tkWinPort.h b/win/tkWinPort.h index f9a9021..4146914 100644 --- a/win/tkWinPort.h +++ b/win/tkWinPort.h @@ -10,18 +10,12 @@ * 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.15 2010/04/13 13:46:01 nijtmans Exp $ + * RCS: @(#) $Id: tkWinPort.h,v 1.16 2010/04/20 08:17:33 nijtmans Exp $ */ #ifndef _WINPORT #define _WINPORT -#include <X11/Xlib.h> -#include <X11/cursorfont.h> -#include <X11/keysym.h> -#include <X11/Xatom.h> -#include <X11/Xutil.h> - /* *--------------------------------------------------------------------------- * The following sets of #includes and #ifdefs are required to get Tcl to @@ -69,6 +63,12 @@ # endif #endif +#include <X11/Xlib.h> +#include <X11/cursorfont.h> +#include <X11/keysym.h> +#include <X11/Xatom.h> +#include <X11/Xutil.h> + #ifdef __CYGWIN__ # ifndef _vsnprintf # define _vsnprintf vsnprintf |