Compilation of _tkinter, tcl/tk bindings

M

mg

Hello,

First, I installed Python on a traditionnal default linux-x86 platform
(tk.h is located in /usr/include) and I did not meet any problem. I can
write the following instruction without error in my python interpreter:

../configure --prefix=/usr/local/python
make
make install
/usr/local/python/bin/python
Second, I tried to install python on IBM-Aix5.1 with tk bindings too.
Because of tcl/tk doesn't exist on my default platform, I have installed
tcl8.4.11 in /usr/local/tcl8.4.11. Now, I ran the compilation of Python
and tried to import Tkinter :

../configure --prefix=/usr/local/python
make
make install
/usr/local/python/bin/pythonTraceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/local/python/lib/python2.5/lib-tk/Tkinter.py", line 38, in ?
import _tkinter # If this fails your Python may not be configured for Tk
ImportError: No module named _tkinter
In fact, when Python is compiled, the shared library _tkinter.so should
be compiled (Tkinter.py is just a Python script which import
_tkinter.so) if tk is detected on the platform.

So, my questions are :
- Must I install tcl/tk in the default directories give by the
distribution to compile python and Tkinter (_tkinter) ?
- or can I specify the tcl/tk installation to compile Python and Tkinter
(_tkinter) ?

Regards,
Mathieu.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top