Further modernization of the build backend to reduce `setup.py` usage
Nessuno ha ancora preso questa issue.
- Lingua principale
- Cython
- Stelle
- 3.4k
- Fork
- 329
- Merge medio
- 1g 23h
- PR unite (30g)
- 116
Descrizione
Creating an issue to capture the internal discussions.
Currently both cuda.bindings and cuda.core use setuptools as the build backend and have a mixture of pyproject.toml static declarations and setup.py dynamic logics. We have two choices here:
- Keep
setuptoolsbut further reduce the amount of code insetup.py:- This seems to become possible with recent
setuptools, where Cython extensions can now be declared inpyproject.toml.
- This seems to become possible with recent
- Switch to use
scikit-build-core:- This has the benefit of reusing CUDA discovery mechanism (
FindCUDAToolkit) and other nice build system features provided by CMake (see the relevant discussion in #46). - The potential downside is to maintain a custom
CMakeLists.txtwhich is arguably a burden for non-C++ (=C & Python) oriented developers. Our Cython extensions are very simple to build.- However, this might become necessary once we start integrating some features from
cudax::, e.g. #528.
- However, this might become necessary once we start integrating some features from
- This has the benefit of reusing CUDA discovery mechanism (
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia confrontando le configurazioni attuali di pyproject.toml e setup.py per cuda.bindings e cuda.core, quindi leggi la discussione collegata in #46. Valuta se le versioni recenti di setuptools possono dichiarare le estensioni Cython o se sono necessari scikit-build-core e un CMakeLists.txt, comprese le considerazioni future su cudax:: in #528. Il lavoro è completato quando il progetto concorda una direzione per il backend di build e il relativo ambito.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- cmake, python
- Ambito
- build-system
- Tipo di issue
- Refactoring
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Tranquilla
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 35/100