[SciPy-Dev] Cross Compiling SciPy?
Hickey, Joseph P. (GRC-LSS0)[ZIN TECHNOLOGIES INC]
joseph.p.hickey at nasa.gov
Fri Jul 15 10:36:02 EDT 2016
Hello all -- apologies if similar question(s) have been asked before,
but I didn't see anything in the archives.
I'm trying to compile NumPy + SciPy for an embedded target -- PowerPC
target CPU, x86-64 host machine. The build system I'm using is based on
Yocto/OpenEmbedded, basically a fairly standard cross compile setup.
I'm using tagged versions from the git repositories, specifically
v1.10.4 of NumPy and v0.17.1 for SciPy, and Python 2.7 as provided by
the upstream "Poky" distribution. So far, NumPy has been relatively
painless, the "setup.py" script seems to obey the BUILD_SYS/HOST_SYS
variables and successfully builds for the target architecture.
SciPy, on the other hand, is more problematic. The provided "setup.py"
script was not even getting started because it attempts this:
from numpy.distutils.core import setup
But the "setup.py" script is actually running on the host machine in
this case, so it is importing the setup from the host installation, NOT
the target's numpy installation. If I install numpy on the host machine
as well, this import now works, but it creates a mixture of binaries --
the build fails later on when it attempts to link binaries built using
the native gcc with other binaries built using the cross compiler. I've
also tried the previous release (v0.16.1 tag) with similar results.
Has anyone successfully cross compiled SciPy that could provide some
guidance here? Is there anything special I need to do with the NumPy
cross installation such that the SciPy build can find it?
Thanks in advance
-Joe
More information about the SciPy-Dev
mailing list