Re: Python on UnixWare

Guido.van.Rossum@cwi.nl
Tue, 26 Jul 1994 14:05:29 +0200

> I have the following problem when building Python on Novell's
> UnixWare 1.1.1, and I hope someone out there can help me.
> (UnixWare is Novell's SVR4.2 Unix).
>
> When I do:
> CC=/usr/bin/cc ; export CC
> ./configure -v --with-svr4
>
> It decides that it doesn't like the "socket" library, because
> of the following undefined symbols:
...

> I edited the Modules/Makefile, and changed the line:
>
> LIBS = -ldl -lsnl
-lnsl
>
> to
>
> LIBS = -ldl -lsocket -lsnl
-lnsl
>
> After this change, the final link works, and "python" then
> goes on to pass the "make test".
>
> Question: This can't be the right way to fix this problem.
> Is there a better fix (i.e. to "configure")?

Hmm... The problem seems to be that on Novell (of which I know
nothing) you can't use -lsocket unless you also use -lnsl. I have
tested this part of the configure script on Solaris 2.2 where it works
OK. The autoconf macros only support testing one library at a time so
it would be rather difficult to devise a test that works for Novell.
There's also the "-linet" library which I don't know nothing about but
which I presume is needed on some other platform.

You could probably avoid editing the Makefile by saying

LIBS="-lsocket -lnsl"; export LIBS

before running the configure script.

> P.S. I am using the Novell SDK, compiling as "root",
> If I use the "bsd compatibility" mode, it bombs when compiling:
> Modules/posixmodule.c
> When I use gcc (vers. 2.4.5), I have the same socket linking problem.

I'm afraid I can't help you here...

--Guido van Rossum, CWI, Amsterdam <Guido.van.Rossum@cwi.nl>
<URL:http://www.cwi.nl/cwi/people/Guido.van.Rossum.html>