-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
105 lines (90 loc) · 3.52 KB
/
pyproject.toml
File metadata and controls
105 lines (90 loc) · 3.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
[build-system]
requires = [
"scikit-build-core>=0.9",
"pybind11>=2.11",
"numpy",
"setuptools_scm[toml]>=8",
]
build-backend = "scikit_build_core.build"
[project]
name = "cpp_hf"
dynamic = ["version"]
description = "Hartree–Fock (k-grid) with FFTW + Eigen via pybind11"
readme = "Readme.md"
requires-python = ">=3.8"
authors = [{ name = "Tobias Wolf", email = "public@wolft.xyz" }]
license = { file = "LICENSE" }
keywords = ["hartree-fock", "fftw", "eigen", "pybind11", "condensed-matter", "physics"]
classifiers = [
"License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: C++",
"Operating System :: MacOS",
"Operating System :: POSIX :: Linux",
"Topic :: Scientific/Engineering :: Physics",
]
[project.urls]
Homepage = "https://github.com/skilledwolf/cpp_hf"
Issues = "https://github.com/skilledwolf/cpp_hf/issues"
[tool.scikit-build.metadata.version]
provider = "scikit_build_core.metadata.setuptools_scm"
[tool.setuptools_scm]
# Strip leading 'v' from tags like v1.2.3 automatically
version_scheme = "guess-next-dev"
local_scheme = "node-and-date"
fallback_version = "0.0"
#[tool.scikit-build]
# No pure-Python packages shipped; wheel only contains the extension module
[tool.scikit-build.cmake.define]
HF_USE_OPENMP = true
HF_USE_FFTW_THREADS = true
HF_FETCH_FFTW = false
# Use a modern C++ level but keep portability; mdspan fallback handles older libstdc++/libc++
CMAKE_CXX_STANDARD = 23
CMAKE_CXX_STANDARD_REQUIRED = true
CMAKE_CXX_EXTENSIONS = false
# Broad macOS default; override per CI job if desired
CMAKE_OSX_DEPLOYMENT_TARGET = { env = "MACOSX_DEPLOYMENT_TARGET", default = "14.0" }
[tool.cibuildwheel]
build = "cp311-* cp312-*"
skip = "pp* *-musllinux_*"
# Copy tests into cibuildwheel's temp dir and run against the installed wheel
test-requires = ["numpy"]
test-sources = ["ci/smoke_test.py"]
test-command = "python ci/smoke_test.py"
[tool.cibuildwheel.linux]
before-all = "bash ci/linux_before_all.sh"
manylinux-x86_64-image = "manylinux_2_28"
manylinux-aarch64-image = "manylinux_2_28"
repair-wheel-command = """
LD_LIBRARY_PATH=/project/.cache/fftw-3.3.10-$(uname -m)/lib:$LD_LIBRARY_PATH \
auditwheel repair -w {dest_dir} {wheel}
"""
[tool.cibuildwheel.macos]
archs = ["native"]
# One script handles both archs: arm64 builds FFTW from source, x86_64 uses brew fftw
before-all = "bash ci/macos_arm_fftw.sh"
repair-wheel-command = """
delocate-wheel -L cpp_hf/.dylibs --require-archs {delocate_archs} -w {dest_dir} -v {wheel}
"""
# Teach CMake/pkg-config where our cached FFTW installs live
[tool.cibuildwheel.linux.environment]
PKG_CONFIG_PATH = "/project/.cache/fftw-3.3.10-x86_64/lib/pkgconfig:/project/.cache/fftw-3.3.10-aarch64/lib/pkgconfig:$PKG_CONFIG_PATH"
CMAKE_PREFIX_PATH = "/project/.cache/fftw-3.3.10-x86_64:/project/.cache/fftw-3.3.10-aarch64:$CMAKE_PREFIX_PATH"
LIBRARY_PATH = "/project/.cache/fftw-3.3.10-x86_64/lib:/project/.cache/fftw-3.3.10-aarch64/lib:$LIBRARY_PATH"
CPATH = "/project/.cache/fftw-3.3.10-x86_64/include:/project/.cache/fftw-3.3.10-aarch64/include:$CPATH"
BOOST_INCLUDEDIR = "/project/.cache/boost-1.89.0/include"
[tool.scikit-build.wheel]
# Ensure license and notices are embedded in the wheel metadata
license-files = [
"LICENSE",
"THIRD_PARTY_NOTICES.md",
]
[tool.scikit-build.sdist]
# Ensure third-party notices are included in the source distribution
include = [
"LICENSE",
"THIRD_PARTY_NOTICES.md",
]