nnorwitz at gmail.com
Mon Nov 7 21:49:21 CET 2005
We've been having some issues and discussions at work about cross
compiling. There are various people that have tried (are) cross
compiling python. Right now the support kinda sucks due to a couple
First, distutils is required to build all the modules. This means
that python must be built twice. Once for the target machine and once
for the host machine. The host machine is really not desired since
it's only purpose is to run distutils. I don't know the history of
why distutils is used. I haven't had much of an issue with it since
I've never needed to cross compile. What are the issues with not
requiring python to be built on the host machine (ie, not using
Second, in configure we try to run little programs (AC_TRY_RUN) to
determine what to set. I don't know of any good alternative but to
force those to be defined manually for cross-compiled environments.
Any suggestions here? I'm thinking we can skip the the AC_TRY_RUNs
if host != target and we pickup the answers to those from a user
I'm *not* suggesting that normal builds see any change in behaviour.
Nothing will change for most developers. ie, ./configure ; make ;
./python will continue to work the same. I only want to make it
possible to cross compile python by building it only on the target
PS. I would be interested to hear from others who are doing cross
compiling and know more about it than me.
More information about the Python-Dev