diff options
author | Jason Tishler <jason@tishler.net> | 2002-12-31 20:30:46 (GMT) |
---|---|---|
committer | Jason Tishler <jason@tishler.net> | 2002-12-31 20:30:46 (GMT) |
commit | bbe8961698de3a4e3e17512b6e88e9d7fcd52d4e (patch) | |
tree | 23db603f8eb14d8818ef01e03a38705c0cc5ed56 /Modules | |
parent | 8f1f8f13e4046bdb1eb0e4d7d54fe9b345e78ac0 (diff) | |
download | cpython-bbe8961698de3a4e3e17512b6e88e9d7fcd52d4e.zip cpython-bbe8961698de3a4e3e17512b6e88e9d7fcd52d4e.tar.gz cpython-bbe8961698de3a4e3e17512b6e88e9d7fcd52d4e.tar.bz2 |
Patch #660485: Cygwin _tkinter Tcl/Tk 8.3 patch
The attached patch enables Cygwin Python to
build cleanly against the latest Cygwin Tcl/Tk
which is based on Tcl/Tk 8.3. It also prevents
building against the real X headers, if installed.
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_tkinter.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Modules/_tkinter.c b/Modules/_tkinter.c index 0c3d088..212bbad 100644 --- a/Modules/_tkinter.c +++ b/Modules/_tkinter.c @@ -57,9 +57,10 @@ Copyright (C) 1994 Steen Lumholt. #include <tk.h> #endif -/* For Tcl 8.2 and 8.3, CONST* is not defined. */ +/* For Tcl 8.2 and 8.3, CONST* is not defined (except on Cygwin). */ #ifndef CONST84_RETURN #define CONST84_RETURN +#undef CONST #define CONST #endif @@ -752,7 +753,7 @@ statichere PyTypeObject PyTclObject_Type = { 0, /*tp_hash*/ 0, /*tp_call*/ (reprfunc)PyTclObject_str, /*tp_str*/ - PyObject_GenericGetAttr,/*tp_getattro*/ + 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT, /*tp_flags*/ @@ -2838,6 +2839,7 @@ init_tkinter(void) PyDict_SetItemString(d, "TkttType", (PyObject *)&Tktt_Type); PyTclObject_Type.ob_type = &PyType_Type; + PyTclObject_Type.tp_getattro = &PyObject_GenericGetAttr; PyDict_SetItemString(d, "Tcl_Obj", (PyObject *)&PyTclObject_Type); #ifdef TK_AQUA |