Help: Python2.3 & Python2.4 on RHEL4 x86_64

Christopher Taylor chtaylo3 at
Wed Oct 18 19:33:23 CEST 2006

RHEL comes with Python2.3 installed.  A program I need to install
requires Python2.4

So I got Python2.4 from source and compiled it up.  I configured it
with --prefix=/usr  --exec-prefix=/usr and --enable-unicode=ucs4 .  I
then make'd it and then make altinstall so that it didn't overwrite
the /usr/bin/Python link to /usr/bin/Python2.3  .

Well, for some reason, the arch dependent files did NOT get placed
properly in /usr/lib64/Python2.4, they instead went to

Also, when I tried to load pysqlite:
$ Python2.4
>>> from pysqlite2 import test

I get the following traceback:

Traceback (most recent call last):
 File "", line 24, in ?
   import glob, os, re, sys
 File "/usr/lib64/python2.3/", line 4, in ?
   import fnmatch
 File "/usr/lib64/python2.3/", line 13, in ?
   import re
 File "/usr/lib64/python2.3/", line 5, in ?
   from sre import *
 File "/usr/lib64/python2.3/", line 97, in ?
   import sre_compile
 File "/usr/lib64/python2.3/", line 17, in ?
   assert _sre.MAGIC == MAGIC, "SRE module mismatch"
AssertionError: SRE module mismatch

This basically means to me that Python2.4 is loading from
/usr/lib64/Python2.3 insead of /usr/lib/Python2.4  (even thought I
wanted to install the related files in /usr/lib64/Python2.4)

Can someome please help!

Christopher Taylor

More information about the Python-list mailing list