pypa / packaging-problems

An issue tracker for the problems in packaging
151 stars 35 forks source link

CROSS_COMPILING=/usr/bin/SOME_ARCH from within setup.py #748

Closed silver2row closed 7 months ago

silver2row commented 7 months ago

Problem description

Hello...

I am currently trying to decipher the docs pages online for python3.11 and not quite finding exactly what I intended to find. I found manylinux_x_y.

I am on a Linux machine. I want to cross_compile specific SDKs and other tidbits using setup.py but I am unsure how to advance in this topic. Would performing specific command:argument within setup.py help my venture here?

Seth

P.S. I can already compile on the intended machine but this is not what I desire. I thought cross_compiling within setup.py and/or outside of it would be an easy task. I am mistaken. I am sure there are reasons for this idea. I am okay without knowing everything about the subject but any notion or mention to a place where I can find out more would be nice.

jeanas commented 7 months ago

You may be interested in PEP 720.

setuptools may not be the best build backend for cross compilation; personally I'd use meson-python (with Meson) or scikit-build-core (with CMake).

silver2row commented 7 months ago

@jeanas , thank you. I appreciate you taking time out to help out. setuptools is probably not useful in this regard. No issue...

Seth