build: migrate extension build to scikit-build-core#230
Conversation
6f41d0c to
97a2594
Compare
|
This is a lot to take in.
|
|
Thanks for calling this out. I agree this is a fairly large change, but with good reason although I can split it up so it can be reviewed easier. My reasoning for the scikit-build-core vs. “vanilla” Python tooling direction is that GenomeKit’s build is not just Python packaging. The main complexity is building the native C++ extension while preserving the existing compiler flags, linker behavior, NumPy include handling, zlib linkage, and other platform specific behaviors. Using only setuptools would likely still require custom scikit-build-core still uses the standard Python packaging entry points: It also matches the direction suggested in issue #177, where scikit-build-core was called out as a good fit for existing CMake projects. That said, I agree this would be easier to review as smaller PRs. What do you think about the following split:
The backend switch itself probably needs the CMake extension target and I bundled the work because it creates one complete migration path that can be tested end to end, but I’m fine with breaking it into smaller reviewable PRs if that is the preferred approach just let me know if this is acceptable. Let me know if the split above is acceptable and I'll make the changes. |
Summary
pyproject.toml, and remove the obsoletesetup.py/MANIFEST.inpathTests
python -m build --sdist --wheeltar -tf dist/*.tar.gz | rg '(^|/)src/py_init.cpp$|(^|/)src/genome_kit.cpp$|(^|/)src/genome_kit.h$|(^|/)CMakeLists.txt$|(^|/)LICENSE$|(^|/)COPYRIGHT.txt$'unzip -l dist/*.whl | rg 'genome_kit/_cxx|genomekit-7.4.4.dist-info/(METADATA|licenses/LICENSE|licenses/COPYRIGHT.txt)'python -m pip install --force-reinstall dist/*.whlcd /tmp && python -c "import genome_kit, genome_kit._cxx; print(genome_kit.__version__)"CI=1 python -m unittest discover(500 tests, 50 skipped, 1 expected failure)python -m compileall -q genome_kit testsgit diff --checkNotes
main.Closes #177