Problem building Python 2.3.4 on RedHat Enterprise; tcl not found

  • Thread starter Russell E. Owen
  • Start date
R

Russell E. Owen

I'm trying to build Python 2.3.4 from source on a RedHat Enterprise
machine for installation in a net-wide accessible directory /net/python.
I tried all of the following variants of ./configure (the first was
required for Python 2.3.3 on RedHat 9):
../configure --prefix=/net/python --enable-unicode=ucs4
../configure --prefix=/net/python
../configure --prefix=/net/python --enable-unicode=ucs2

All of these result in the ominous message (even the last form, which
really surprised me):
checking for UCS-4 tcl... no

Having gone through the make in one case and gotten no _tkinter, I'm
expecting the same results for the other two cases.

Any hints? At this point I'm spinning my wheels. I'm not even sure if
tcl is built with UCS-4 or UCS-2 on RedHat Enterprise.

My fallback will be to build my own tcl/tk. Blasted RedHat. Python 2.3.3
was working just fine under RedHat 9, and I'd have been happy to keep
using it, but Tkinter is acting flaky after the OS upgrade --
tkColorChooser.askcolor is broken (returning strings that Python has no
idea what to do with).

-- Russell
 
W

wes weston

Russell said:
I'm trying to build Python 2.3.4 from source on a RedHat Enterprise
machine for installation in a net-wide accessible directory /net/python.
I tried all of the following variants of ./configure (the first was
required for Python 2.3.3 on RedHat 9):
./configure --prefix=/net/python --enable-unicode=ucs4
./configure --prefix=/net/python
./configure --prefix=/net/python --enable-unicode=ucs2

All of these result in the ominous message (even the last form, which
really surprised me):
checking for UCS-4 tcl... no

Having gone through the make in one case and gotten no _tkinter, I'm
expecting the same results for the other two cases.

Any hints? At this point I'm spinning my wheels. I'm not even sure if
tcl is built with UCS-4 or UCS-2 on RedHat Enterprise.

My fallback will be to build my own tcl/tk. Blasted RedHat. Python 2.3.3
was working just fine under RedHat 9, and I'd have been happy to keep
using it, but Tkinter is acting flaky after the OS upgrade --
tkColorChooser.askcolor is broken (returning strings that Python has no
idea what to do with).

-- Russell

Russell,
There is some help here:

http://www.talkaboutprogramming.com/group/comp.lang.python/messages/290343.html

Appendix A was what I needed to get things working on RH9.

wes
 
R

Russell E. Owen

"Russell E. Owen said:
I'm trying to build Python 2.3.4 from source on a RedHat Enterprise
machine for installation in a net-wide accessible directory /net/python.
I tried all of the following variants of ./configure (the first was
required for Python 2.3.3 on RedHat 9):
./configure --prefix=/net/python --enable-unicode=ucs4
./configure --prefix=/net/python
./configure --prefix=/net/python --enable-unicode=ucs2

All of these result in the ominous message (even the last form, which
really surprised me):
checking for UCS-4 tcl... no

The problems continue...

I decided to try building my own tcl and tk in /net/python. That seemed
to go perfectly, /net/python/wish8.4 works and stuff is where I expected
it to be, e.g.:
% ls /net/python/lib
libtcl8.4.so libtclstub8.4.a libtk8.4.so libtkstub8.4.a python2.3
tcl8.4 tclConfig.sh tk8.4 tkConfig.sh

I then edited Python-2.3.4/Modules/Setup:

_tkinter _tkinter.c tkappinit.c -DWITH_APPINIT \
# *** Uncomment and edit to reflect where your Tcl/Tk libraries are:
-L/net/python/lib \
# *** Uncomment and edit to reflect where your Tcl/Tk headers are:
-I/net/python/include \
# *** Uncomment and edit to reflect where your X11 header files are:
-I/usr/X11R6/include \
# *** Or uncomment this for Solaris:
# -I/usr/openwin/include \
# *** Uncomment and edit for Tix extension only:
# -DWITH_TIX -ltix8.1.8.2 \
# *** Uncomment and edit for BLT extension only:
# -DWITH_BLT -I/usr/local/blt/blt8.0-unoff/include -lBLT8.0 \
# *** Uncomment and edit for PIL (TkImaging) extension only:
# (See http://www.pythonware.com/products/pil/ for more info)
# -DWITH_PIL -I../Extensions/Imaging/libImaging tkImaging.c \
# *** Uncomment and edit for TOGL extension only:
# -DWITH_TOGL togl.c \
# *** Uncomment and edit to reflect your Tcl/Tk versions:
-ltk8.4 -ltcl8.4 \
# *** Uncomment and edit to reflect where your X11 libraries are:
-L/usr/X11R6/lib \
# *** Or uncomment this for Solaris:
# -L/usr/openwin/lib \
# *** Uncomment these for TOGL extension only:
# -lGL -lGLU -lXext -lXmu \
# *** Uncomment for AIX:
# -lld \
# *** Always uncomment this; X11 libraries to link with:
-lX11

But it's no go. I've tried it numerous ways, with make clean, with
freshly unpacked source code, with
../configure --prefix=/net/python --enable-unicode=ucs4
and with
../configure --prefix=/net/python

and it fails to build with:

Modules/posixmodule.c:6018: the use of `tempnam' is dangerous, better
use `mkstemp'
case $MAKEFLAGS in \
*-s*) CC='gcc -pthread' LDSHARED='gcc -pthread -shared' OPT='-DNDEBUG
-g -O3 -Wall -Wstrict-prototypes' ./python -E ./setup.py -q build;; \
*) CC='gcc -pthread' LDSHARED='gcc -pthread -shared' OPT='-DNDEBUG -g
-O3 -Wall -Wstrict-prototypes' ./python -E ./setup.py build;; \
esac
../python: error while loading shared libraries: libtk8.4.so: cannot open
shared object file: No such file or directory
make: *** [sharedmods] Error 127

Earlier on it does show _tkinter being built:
....
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -O3 -Wall
-Wstrict-prototypes -I. -I./Include -DPy_BUILD_CORE -DWITH_APPINIT
-I/net/python/include -I/usr/X11R6/include -c ./Modules/_tkinter.c -o
Modules/_tkinter.o
....

Any ideas?

-- Russell
 

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,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top