statically linking the entire runtime (HPUX Python2.1)

Carsten Gaebler clpy at
Sat Jun 16 04:28:19 EDT 2001

Andrew MacIntyre wrote:
> On Fri, 15 Jun 2001, Carsten Gaebler wrote:
> > I noticed that you can't build the curses module statically. The linker
> > then complains about duplicate definitions of 'tputs' in libncurses and
> > libtermcap. Is there a way to get around this?
> Do you really need to link in libtermcap??  I had been under the
> impression that libncurses contained all necessary functionality.

You're right, the curses module does not need libtermcap. The problem
actually was that I put the following into Modules/Setup:

readline readline.c /usr/lib/libreadline.a /usr/lib/libtermcap.a
_curses _cursesmodule.c /usr/lib/libncurses.a

So I had a conflicting libtermcap from the readline module which does
not need libtermcap either. After deleting that and replacing

LIBS=          -lpthread -ldl  -lutil
LIBM=          -lm


LIBS= /usr/lib/libpthread.a /usr/lib/libdl.a /usr/lib/libutil.a
LIBM= /usr/lib/libm.a

in the Makefile, I now have a 5.3 megs python interpreter that depends
on no more than and :-)
Well, you could probably also say:


but that would be like Monster Truck Madness ... ;-)


More information about the Python-list mailing list