Xavier de Gaye added the comment:

So the problem is that setup.py in build_extensions() does not build the 
extensions that have been already built statically into the native Ubuntu 

The solution is to build first natively from source python3.5 and set the PATH 
environment variable so that the newly built interpreter is fisrt on the PATH, 
before the one distributed by Ubuntu. And then to run the cross-build.

I think that should be the standard procedure for cross-compilation:
    * Configure the python source, for example update Modules/Setup.
    * Build python natively out of the source tree [1].
    * Set the new interpreter first on the PATH.
    * Cross-build python out of the same source tree, in another directory.

Unless someone has a better idea to fix this problem, I will propose a patch so 
that extension modules that are removed by build_extensions(), are not removed 
anymore silently.

[1] Out of the source tree:
For example, assuming the source tree is at 'src' and the current working 
directory is its parent, to build python in the 'build' directory without 
modifying any file in the 'src' directory:
    $ mkdir build
    $ cd build
    $ $(cd ../src && pwd)/configure arg1 arg2 ... && make


Python tracker <rep...@bugs.python.org>
Python-bugs-list mailing list

Reply via email to