compiling Python 2.7.1 with readline module fails on Debian (Virtualbox)

Benedict Verheyen benedict.verheyen at gmail.com
Thu Dec 23 04:04:13 EST 2010


On 22/12/2010 18:47, Stefan Sonnenberg-Carstens wrote:
> Am 22.12.2010 09:33, schrieb Benedict Verheyen:
<snip>
>>
> Did you try
> 
> apt-get install build-essential
> apt-get build-dep python2.7
> 
> before trying to compile ?
> 
> Anyway, the config.log file is always of special interest.
> Btw, which Debian release are you running ?
> If the system is set up correctly it should not be necessary to change env vars to get it built.
> 
> 

I use Debian stable so "apt-get build-dep python2.7" doesn't work.
I removed all installed Python 2.7.1 files and so on and tried to build/install from scratch.
Now i can't get Python to find the readline library.
What is the normal procedure to make sure the readline library is found?

I downloaded readline 6.1, build it and installed it to $HOME/local
$HOME/local/lib contains libreadline.so.

I did the following to try to enable detection of the libreadline:

- export LD_LIBRARY_PATH=$HOME/local/lib:$LD_LIBRARY_PATH
- vi Modules/Setup and uncomment the line that specifies the readline module.
  Added -L$HOME/local/lib
- Tried ./configure with env CPPFLAGS="-I$HOME/local/include" LDFLAGS="-L$HOME/local/lib"
- Edit setup.py, to add_dirs to $HOME/local/include and $HOME/local/lib
- Tried to export CPPFLAGS and LDFLAGS

Nothing seems to work.
What am i doing wrong?

Cheers,
Benedict




More information about the Python-list mailing list