[Tkinter-discuss] How can I tell Tkinter where to look for Tcl/Tk?

Igor Novikov igor.e.novikov at gmail.com
Thu Apr 22 17:13:01 CEST 2010

_tkinter.so is a native extension and linked against system libtcl.so and
libtk.so. Therefore to use latest Tcl/Tk
versions in distributable application you need compiling a bundle for your
application and recompile _tkinter.so

It's just a theory. We have no ported yet sK1 application on MacOS X
platform so I can just supposing this.
But the same issues were under Linux platform right after Tcl/Tk 8.5
release. Fortunately, under Linux
package repositories allow managing different version of Tcl/Tk libraries.


Igor Novikov
sK1 Project

On Thu, Apr 22, 2010 at 4:33 PM, Guido Carballo-Guerrero <charras at me.com>wrote:

> Hello, I have a Mac, running OS X 10.6.3, and have Python 2.6.4 install. I
> already install ttk, got it from:
> http://pypi.python.org/pypi/pyttk
> But when I try to use ttk, it with me the following error:
> Traceback (most recent call last):
>  File "/Users/Charras/Documents/CS/Python/programs/Tkinter/ttk/prueba1.py",
> line 6, in <module>
>    style = ttk.Style()
>  File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/ttk.py",
> line 392, in __init__
>    _load_tile(master)
>  File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/ttk.py",
> line 60, in _load_tile
>    master.tk.eval('package require tile') # TclError may be raised here
> TclError: can't find package tile
> I read somewhere that this mean that I had an old Tcl/Tk version, and I
> check it, and yes, that was the case:
> >>> import Tkinter as Tkt
> >>> Tkt.TkVersion
> 8.4000000000000004
> So I download and install version 8.5 from activestate.com. Now I have
> TCL/TK 8.5 install in my machine, inside of
>  "/Library/Frameworks/Tcl.framework/Versions/8.5". and
> "/Library/Frameworks/Tk.framework/Versions/8.5"., but I guess that if even
> after doing this, Tkinter still sees 8.4 is 'cause I need to tell it to go
> and load this new version and read from there, but I don't know how to do
> that.
> Can somebody guide me on how to do it?
> Regards
> Guido
> _______________________________________________
> Tkinter-discuss mailing list
> Tkinter-discuss at python.org
> http://mail.python.org/mailman/listinfo/tkinter-discuss
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tkinter-discuss/attachments/20100422/acf517d4/attachment.html>

More information about the Tkinter-discuss mailing list