Skip to content

Commit

Permalink
Change build backend from Hatch to Meson
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewfallan committed Dec 28, 2024
1 parent 365b638 commit ad49782
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 105 deletions.
14 changes: 14 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
project('seismic-rna', 'c', version: '0.22.2')
python = import('python').find_installation(pure: false)

# Install Python package files.
py_install_dir = python.get_install_dir()
install_subdir('src/seismicrna',
install_dir: py_install_dir)

# Build and install C extension module.
python.extension_module('relate',
sources: ['src/seismicrna/relate/cx/relate.c'],
subdir: 'seismicrna/relate/cx',
install: true)

23 changes: 6 additions & 17 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
build-backend = "mesonpy"
requires = ["meson-python>=0.15.0"]

[project]
name = "seismic-rna"
Expand Down Expand Up @@ -35,24 +35,13 @@ dependencies = [
]
dynamic = ["version"]

[tool.hatch.build.targets.sdist]
exclude = [
"/.github",
"/docs",
]

[tool.hatch.build.targets.wheel]
packages = ["src/seismicrna"]
extensions = [
{module = "seismicrna.relate.cx.relate", sources = ["src/seismicrna/relate/cx/relate.c"]}
]

[tool.hatch.version]
path = "src/seismicrna/core/version.py"

[project.scripts]
seismic = "seismicrna.main:cli"

[project.urls]
"Homepage" = "https://github.com/rouskinlab/seismic-rna"
"Bug Tracker" = "https://github.com/rouskinlab/seismic-rna/issues"

[tool.mesonpy]
build-dir = "build"

19 changes: 0 additions & 19 deletions src/seismicrna/relate/cx/compile.sh

This file was deleted.

34 changes: 0 additions & 34 deletions src/seismicrna/relate/cx/example.py

This file was deleted.

35 changes: 0 additions & 35 deletions src/seismicrna/relate/cx/setup.py

This file was deleted.

0 comments on commit ad49782

Please sign in to comment.