Use a locally built Tk for Python?



Hi,

I have multiple Pythons locally installed so that I can test against
different versions. (On a 64-bit Debian stable system.)

All of them use the system's Tcl/Tk installation. However, I want to
make some of them use a locally build Tcl/Tk that has a small
customization.

There doesn't seem to be any --with-tk or --with-tcl options for
configure that would allow me to say where my local Tcl/Tk is.

So I ran ./configure --prefix=/home/mark/opt/py32tkmod

And then I tried editing Modules/Setup: I just uncommented and edited
the _tkinter line as follows:

_tkinter _tkinter.c tkappinit.c -DWITH_APPINIT \
-L/home/mark/opt/tcltk85/lib \
-I/home/mark/opt/tcltk85/include \
-I/usr/X11R6/include \
-ltk8.5 -ltcl8.5 \
-L/usr/X11R6/lib \
-lX11

But when I run ~/opt/py32tkmod/bin/python3 tkinter-test.pyw the system
tk is being used not my customized one.

Can anyone advise?

Thanks!
.



Relevant Pages

  • Re: ActiveState Python v2.5 doesnt come with Tkinter or Tk installed.
    ... Now I would like to take up Tkinter. ... I'm using Active State Python ... For MacOS X this should not happen because Tcl/Tk is already available. ... But the best Python for MacOS X is the binary installer from python.org ...
    (comp.lang.python)
  • Re: ActiveState Python v2.5 doesnt come with Tkinter or Tk installed.
    ... Now I would like to take up Tkinter. ... I'm using Active State Python ... For MacOS X this should not happen because Tcl/Tk is already available. ... But the best Python for MacOS X is the binary installer from python.org ...
    (comp.lang.python)
  • Re: Looking for help getting tkinter to work.
    ... Cannot get tkinter to work after compiling & installing Tcl/Tk. ... "Python build finished, but the necessary bits to build these modules ...
    (comp.lang.python)
  • Tkinter problem
    ... Python 2.4 and tcl/tk 8.4. ... > from Tkinter import * ...
    (comp.lang.python)
  • Re: Tkinter problem on Mac OS X
    ... Scripts that import Tkinter run fine on Windows, but on Mac OS X there ... The File and Edit menus are completely replaced. ... Is there a way to prevent Tkinter clobbering our app's menus? ... I am pretty sure it's the underlying Tcl/Tk that's causing you grief. ...
    (comp.lang.python)