Subject: Re: Python with threads
To: None <tech-pkg@NetBSD.ORG>
From: Ty Sarna <>
List: tech-pkg
Date: 04/18/2001 16:12:24
In article <>,
 <> wrote:
> So, I did:
> 1. Remove --without-threads option from Makefile
> 2. make CC="cc `pthread-config --cflags`" \
>       LDFLAGS="`pthread-config --ldflags`" \
>       LIBS="`pthread-config --ldflags --libs`" \
>       LD_LIBRARY_PATH="`pthread-config --ldflags`"
>    in /usr/pkgsrc/lang/python
> then I could get Python with threads.
> Is this the corrct way of building?

It builds that way, but it won't run very well with Pth because it's
non-preemptive. The tests will fail, for example. For some applications
you may be able to get away with this, though. What application do you
need threads for?

Other thread library choices are ptl2, which IIRC built a core-dumping
python last I tried, and unproven-pthreads, which worked the best,
except that os.system() and similar calls are broken, making it hard to
use the resulting interpreter to build extensions or for general-use

This is why threads are disabled by default; there are currently no
reasonable thread library choices for NetBSD. :-(