question about tkinter

R

robert schaefer

Hello,

This is my first posting to this list so please be gentle -

I am new to python and am using it on red-hat linux (I am new to that too).
I am responsible for installing open source packages (including python) onto a distributed system of linux boxes.

My question is, on python version 2.6.2 tkinter refuses to install.
Without tkinter, I cannot use Idle.

I looked at the install/configure script and hacked it a bit, but every fix only caused new problems.
There are serious issues with that script for finding necessary libraries.

We have a Sun-OS box with python version 2.5.x (I don't know the means of installation) that
tkinter installed correctly, and Idle works fine.

My question is - has anyone else noticed the problem of tkinter and red-hat linux?
Has this been corrected in python 2.6.4 (or 2.6.5)?

thanks,
bob s.


-----------------------------------
robert schaefer
Atmospheric Sciences Group
MIT Haystack Observatory
Westford, MA 01886

email: (e-mail address removed)
voice: 781-981-5767
www: http://www.haystack.mit.edu
 
P

Peter Otten

robert said:
This is my first posting to this list so please be gentle -

I am new to python and am using it on red-hat linux (I am new to that
too). I am responsible for installing open source packages (including
python) onto a distributed system of linux boxes.

My question is, on python version 2.6.2 tkinter refuses to install.

Does it say "I'm sorry Bob, I'm afraid I can't do this"?
Without tkinter, I cannot use Idle.

I looked at the install/configure script and hacked it a bit, but every
fix only caused new problems.
There are serious issues with that script for finding necessary
libraries.

If there are serious problems you have to give some details.

However, if in the past a newbie had problems with Tkinter support on linux
the most frequent problem was that the Tcl/Tk development libraries weren't
installed. I don't know how those are called on Red Hat, maybe something
like

tcl*-dev.rpm

Did you install these before running the configure script?

Peter
 
R

robert schaefer

Peter,

Most of my life has been dealing with recalcitrant HAL's in one guise or another.
These days, I think HAL has permanently taken up residence in Toyota's engine and brakes.
"Stop the car Dave? Have you changed my oil or even washed me lately?"
Some serious "sneak paths" are going on.

Anyway -

tkinter is in two parts:
1. a python wrapper
2. c code

Both are present in the 2.6.2 python download.
It appears to be a "I can't find the library" path problem not a file existence problem.

1. gcc can't find the libraries that tkinter c code links to ( I could fix that)
2. the python installer can't find all the library paths to all the pieces
- I started fixing this, then determined it would be easier to rewrite from scratch than patch.
That is, the given method of building paths in the script are way off from reality, not just an
add this one path and everything will now work kind of magic.
I felt that the "official" python people would have an easier time of this - so gave up.

bob

Does it say "I'm sorry Bob, I'm afraid I can't do this"?


If there are serious problems you have to give some details.

However, if in the past a newbie had problems with Tkinter support on linux
the most frequent problem was that the Tcl/Tk development libraries weren't
installed. I don't know how those are called on Red Hat, maybe something
like

tcl*-dev.rpm

Did you install these before running the configure script?

Peter

-----------------------------------
robert schaefer
Atmospheric Sciences Group
MIT Haystack Observatory
Westford, MA 01886

email: (e-mail address removed)
voice: 781-981-5767
www: http://www.haystack.mit.edu
 
P

Peter Otten

robert said:
tkinter is in two parts:
1. a python wrapper
2. c code

Both are present in the 2.6.2 python download.
It appears to be a "I can't find the library" path problem not a file
existence problem.

1. gcc can't find the libraries that tkinter c code links to ( I could fix
that) 2. the python installer can't find all the library paths to all the
pieces - I started fixing this, then determined it would be easier to
rewrite from scratch than patch. That is, the given method of building
paths in the script are way off from reality, not just an add this one
path and everything will now work kind of magic. I felt that the
"official" python people would have an easier time of this - so gave up.

Just to exclude the simple problems (unfortunately I can't help you with the
hard ones): Are the tcl development packages installed on your system?

Peter
 
R

robert schaefer

No, And there's a reason (perhaps not a great one - but I'm got some constraints).

I am not the system administrator and the tcl installer wants to be
installed as root. I tried it.

The rationale for not doing this is that the installation packages that I am administrator for,
are all installed in non-root directories. by non-root people.
If I have to install any package as root, then that becomes
"different". The machines are all linux and intended to be swappable/exchangeable and installed by
anyone without root access. This simplifies maintenance when a large number of boxes are involved.

Are there any tcl/tk packages that permit re-direction of installation to non-root directories?

This problem is just an ongoing irritation, python works fine without tkinter, I just can't get idle
to work without it.

Related to that I tailored Ipython to work with gtk (ipython's default was tkinter) - tailoring was by a command
- is there any way to command idle to use gtk?


Just to exclude the simple problems (unfortunately I can't help you with the
hard ones): Are the tcl development packages installed on your system?

Peter

-----------------------------------
robert schaefer
Atmospheric Sciences Group
MIT Haystack Observatory
Westford, MA 01886

email: (e-mail address removed)
voice: 781-981-5767
www: http://www.haystack.mit.edu
 
T

Terry Reedy

No, And there's a reason (perhaps not a great one - but I'm got some constraints).
Related to that I tailored Ipython to work with gtk (ipython's default was tkinter) - tailoring was by a command
- is there any way to command idle to use gtk?

I am pretty sure not, the gui is hard-coded with tkinter.
 
F

furlan

Peter,

Most of my life has been dealing with recalcitrant HAL's in one guise or
another. These days, I think HAL has permanently taken up residence in
Toyota's engine and brakes. "Stop the car Dave? Have you changed my oil
or even washed me lately?" Some serious "sneak paths" are going on.

<snip>

Don't know if this will help and I had in a file in my Solutions folder
from 2008 the following:

If Tkinter does not seem to be loaded run:

sudo yum -y install python-tools

which will install Tkinter and dependencies.

HTH

ciao,
f
 

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

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top