Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Oct 2001 08:25:15 -0500
From:      Mike Meyer <mwm@mired.org>
To:        Ulf.Kister@t-online.de (Ulf Kister)
Cc:        questions@freebsd.org
Subject:   Re: python 2.1.1 with AND without threads
Message-ID:  <15317.28603.296849.864129@guru.mired.org>
In-Reply-To: <55888007@toto.iv>

next in thread | previous in thread | raw e-mail | index | archive | help
Ulf Kister <Ulf.Kister@t-online.de> types:
> since I am planning to simultaneously use zope (which requires python
> to be built with threads) and mod_python-2.7.6 (which requires python
> to be built without threads) I was wondering if there is a simple way
> to have both.

Sure. Just build them and install them in two different places. No
problem. Actually, build it one way, rename the binary, then build it
another.

I know, that doesn't solve your problem.

> I use python-2.1.1, zope-2.4.2 (both from ports collection) and would
> like to use mod_python-2.7.6.

First question - if you're running zope, why would you want
mod_python? Zope comes with a very nice server that makes plugging in
python code straightforward, and provides excellent performance.

> Being not familiar with Makefiles I took a closer look at 
> /usr/ports/Mk/bsd.python.mk but did'nt see the clue yet.

It looks like the port builds the CGI/apache version. That's a good
reason not to use the port.

> Does anyone have a hint for solving this dilemma?

First suggestion - look on the <URL: http://modules.apache.org/ > for
the PyApache module, and see if it will do what you want. It works
fine with threaded python.

Second suggestion. Build Python sans threads. Build Apache with the
python module and interpreter statically linked into it, instead of
dynamically linked into it. Now build Python with threads for Zope to
use. Or vice versa. Or build both versions in two different locations,
and set the LD_LIBRARY_PATH appropriately for the two binaries.

If there aren't two binaries, but just one - I don't think it can be
done without rewriting python so all the external symbols have
different names for one version. You might ask on the Python help
list, or on freebsd-hackers.

	<mike
--
Mike Meyer <mwm@mired.org>			http://www.mired.org/home/mwm/
Q: How do you make the gods laugh?		A: Tell them your plans.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?15317.28603.296849.864129>