Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
project('purelib-and-platlib', 'c')

py = import('python').find_installation(pure: false)

npy_include_path = run_command(py, ['-c', 'import os; import numpy; print(os.path.abspath(numpy.get_include()))'],
).stdout().strip()

npy_include = include_directories(npy_include_path)

py.extension_module(
'fast_histogram._histogram_core',
'fast_histogram/_histogram_core.c',
limited_api: '3.9',
include_directories: [npy_include],
install: true,
)
28 changes: 24 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
[build-system]
requires = ["setuptools",
"setuptools_scm",
"numpy>=2.0.0rc1"]
build-backend = 'setuptools.build_meta'
build-backend = 'mesonpy'
requires = ['meson-python']

[tool.cibuildwheel.linux]
skip = "pp310* pp311* pp312*"
Expand All @@ -26,3 +24,25 @@ environment = { CC="clang" }
[tool.isort]
profile = "black"
line_length = 100


[project]
name = "fast-histogram"
description = "Fast simple 1D and 2D histograms"
readme = "README.rst"
requires-python = ">=3.9"
dependencies = [ "numpy",]
version = "1.0.0"

[[project.authors]]
name = "Thomas Robitaille"
email = "[email protected]"

[project.license]
text = "BSD"

[project.urls]
Homepage = "https://github.com/astrofrog/fast-histogram"

[project.optional-dependencies]
test = [ "pytest", "hypothesis[numpy]",]
Loading