[Tutor] building the readline module

Danny Yoo dyoo@hkn.eecs.berkeley.edu
Mon, 19 Aug 2002 10:16:36 -0700 (PDT)


On Mon, 19 Aug 2002, Prahlad Vaidyanathan wrote:

>     I've been trying to build Python 2.2 with the readline module, in
> order to enable tab-completion, and other such nifty stuff in the
> interactive session, but I have so far been unsuccessful.
>
>     I rummaged through the docs, and then did this.
>
>     - ran the configure script (without arguments)
>     - edited Modules/Setup, and uncommented the "readline" line

Actually, you shouldn't need to do the uncommenting anymore in
'Modules/Setup'.  Recent versions of Python will, in most cases,
autodetect modules for you when Python is being compiled.


>     But, make dies, saying that the linker (GNU ld) cannot find
> "-ltermcap". So, I looked for a libtermcap.a file, and, surely enough,
> it wasn't there.
>
>     So, I pulled out my Mandrake 8.0 CD, and decided to install the
> relevant RPMS.viz.
>
>     - readline
>     - readline-devel
>     - libtermcap2
>
>     But still, I can't seem to find the libtermcap.a file, and, as
> expected, "make" barfs at the same place. I don't know which package I
> should install, which has libtermcap.a (assuming that is where the
> problem lies), so I decided to ask here, and see if anyone knew what I
> am doing wrong.


You may need one more package:

###
[dyoo@tesuque dyoo]$ rpm -qf /usr/lib/libtermcap.a
libtermcap-devel-2.0.8-28
###

But this is on a Redhat 7.3 system though, so the package name might be
slightly different on a Linux Mandrake system. If you install the
'libtermcap-devel' package, that should bring 'libtermcap.a' over to your
system.


Good luck to you!