Subject: x11/pygtk Broken ?
To: None <tech-pkg@NetBSD.org>
From: adam <adam@monkeybyte.org>
List: tech-pkg
Date: 01/08/2004 12:52:50
ive had this problem before with pygtk, when you have python with threads enabled(or maybe others)
the configure script does a check for the python version:
[....]
checking for python... /usr/pkg/bin/python2p2
checking if Python version >= 1.5.2... configure: error: too old
*** Error code 1
[....]
around line 6372 of the configure script is a test:
[....]
import sys, string
minver = '1.5.2'
pyver = string.split(sys.version)[0] # first word is version string
# split strings by '.' and convert to numeric
minver = map(string.atoi, string.split(minver, '.'))
pyver = map(string.atoi, string.split(pyver, '.'))
# we can now do comparisons on the two lists:
if pyver >= minver:
sys.exit(0)
else:
sys.exit(1)"
if $PYTHON -c "$prog" 1>&5 2>&5
then
echo "$as_me:6383: result: okay" >&5
[....]
ok so it fails when I try to build, this is why:
import sys, string
minver = '1.5.2'
>>> import sys, string
>>> minver = '1.5.2'
>>> pyver = string.split(sys.version)[0]
>>> minver = map(string.atoi, string.split(minver, '.'))
>>> pyver = map(string.atoi, string.split(pyver, '.'))
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/pkg/lib/python2p2/string.py", line 225, in atoi
return _int(s, base)
ValueError: invalid literal for int(): 2p2
>>> pyver
'2p2.3'
Simple fix patch is to replace 2p2 with 2.2 in the configure script. I think that's what I
did once when I had it installed. I forget, if some one could patch this some how that would be
great, or anyother ideas on how to install it with 2p2 would be great cause maybe im missing
something simple.
Thanks laters