compiling standard python modules

Gerhard Häring g.haering at ___skynamics.com.invalid
Thu Aug 2 16:18:41 CEST 2001


Janno Kusman wrote:

> Hi!
> 
> I'm trying to compile python to embed platform running NetBSD on MIPS 
> based CPU. I have managed to compile python executable and it seems to 
> work.
> 
> I can't figure out how to compile standard modules like time and math. 
> Compiling is done under Windows using Cygwin based tools so I can't use 
> compiled python to run setup.py. I tryied to run setup.py using windows 
> python, but it figures out platform and compilers wrong.
> 
> I would preciate if someone could guide me how to compile standard 
> modules manually - how python finds and uses modules, maybe it's 
> possible to compile modules into python executable?


Yup. Compiling them statically into the python executable is IMO the way 
to go. Look into the Setup file in the Modules directory, activate all 
the modules you want (also look for *static* and *shared* in this file, 
I don't have a Python source tree here atm), then recompile Python.

Gerhard
-- 
Gerhard Häring
skynamics AG
g.haering at skynamics.com
http://www.skynamics.com




More information about the Python-list mailing list