forked from numpy/numpy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pyproject.toml
210 lines (180 loc) · 7.27 KB
/
pyproject.toml
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
[build-system]
build-backend = "mesonpy"
backend-path = ['./vendored-meson/meson-python']
requires = [
"Cython>=3.0",
# All dependencies of the vendored meson-python (except for meson, because
# we've got that vendored too - that's the point of this exercise).
'pyproject-metadata >= 0.7.1',
'tomli >= 1.0.0; python_version < "3.11"',
'setuptools >= 60.0; python_version >= "3.12"',
'colorama; os_name == "nt"',
# Note that `ninja` and (on Linux) `patchelf` are added dynamically by
# meson-python if those tools are not already present on the system. No
# need to worry about those unless one does a non-isolated build - in that
# case they must already be installed on the system.
]
[project]
name = "numpy"
version = "2.0.0.dev0"
# TODO: add `license-files` once PEP 639 is accepted (see meson-python#88)
license = {file = "LICENSE.txt"}
description = "Fundamental package for array computing in Python"
authors = [{name = "Travis E. Oliphant et al."}]
maintainers = [
{name = "NumPy Developers", email="[email protected]"},
]
requires-python = ">=3.9"
readme = "README.md"
classifiers = [
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Science/Research',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Programming Language :: C',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: 3 :: Only',
'Programming Language :: Python :: Implementation :: CPython',
'Topic :: Software Development',
'Topic :: Scientific/Engineering',
'Typing :: Typed',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Operating System :: Unix',
'Operating System :: MacOS',
]
[project.scripts]
f2py = 'numpy.f2py.f2py2e:main'
[project.entry-points.array_api]
numpy = 'numpy.array_api'
[project.entry-points.pyinstaller40]
hook-dirs = 'numpy:_pyinstaller_hooks_dir'
[project.urls]
homepage = "https://numpy.org"
documentation = "https://numpy.org/doc/"
source = "https://github.com/numpy/numpy"
download = "https://pypi.org/project/numpy/#files"
tracker = "https://github.com/numpy/numpy/issues"
[tool.towncrier]
# Do no set this since it is hard to import numpy inside the source directory
# the name is hardcoded. Use "--version 1.18.0" to set the version
single_file = false
filename = "doc/source/release/{version}-notes.rst"
directory = "doc/release/upcoming_changes/"
issue_format = "`gh-{issue} <https://github.com/numpy/numpy/pull/{issue}>`__"
template = "doc/release/upcoming_changes/template.rst"
underlines = "~="
all_bullets = false
[[tool.towncrier.type]]
directory = "highlight"
name = "Highlights"
showcontent = true
[[tool.towncrier.type]]
directory = "new_function"
name = "New functions"
showcontent = true
[[tool.towncrier.type]]
directory = "python_removal"
name = "NumPy 2.0 Python API removals"
showcontent = true
[[tool.towncrier.type]]
directory = "deprecation"
name = "Deprecations"
showcontent = true
[[tool.towncrier.type]]
directory = "future"
name = "Future Changes"
showcontent = true
[[tool.towncrier.type]]
directory = "expired"
name = "Expired deprecations"
showcontent = true
[[tool.towncrier.type]]
directory = "compatibility"
name = "Compatibility notes"
showcontent = true
[[tool.towncrier.type]]
directory = "c_api"
name = "C API changes"
showcontent = true
[[tool.towncrier.type]]
directory = "c_api_removal"
name = "NumPy 2.0 C API removals"
showcontent = true
[[tool.towncrier.type]]
directory = "new_feature"
name = "New Features"
showcontent = true
[[tool.towncrier.type]]
directory = "improvement"
name = "Improvements"
showcontent = true
[[tool.towncrier.type]]
directory = "performance"
name = "Performance improvements and changes"
showcontent = true
[[tool.towncrier.type]]
directory = "change"
name = "Changes"
showcontent = true
[tool.cibuildwheel]
# Note: the below skip command doesn't do much currently, the platforms to
# build wheels for in CI are controlled in `.github/workflows/wheels.yml` and
# `tools/ci/cirrus_wheels.yml`.
skip = "cp36-* cp37-* cp-38* pp37-* *-manylinux_i686 *_ppc64le *_s390x *-musllinux_aarch64 *-win32"
build-verbosity = "3"
before-build = "bash {project}/tools/wheels/cibw_before_build.sh {project}"
# meson has a hard dependency on ninja, and we need meson to build
# c-extensions in tests. There is a ninja PyPI package used in
# build_requirements.txt for macOS, windows, linux but it cannot be in
# test_requirements.txt since pyodide, which uses test_requirements.txt, does
# not have it.
before-test = "pip install ninja && pip install -r {project}/test_requirements.txt"
test-command = "bash {project}/tools/wheels/cibw_test_command.sh {project}"
[tool.cibuildwheel.linux]
manylinux-x86_64-image = "manylinux2014"
manylinux-aarch64-image = "manylinux2014"
musllinux-x86_64-image = "musllinux_1_1"
environment = { CFLAGS="-fno-strict-aliasing -DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS="-Wl,--strip-debug", CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", NPY_USE_BLAS_ILP64="1", RUNNER_OS="Linux"}
[tool.cibuildwheel.macos]
# For universal2 wheels, we will need to fuse them manually
# instead of going through cibuildwheel
# This is because cibuildwheel tries to make a fat wheel
# https://github.com/multi-build/multibuild/blame/devel/README.rst#L541-L565
# for more info
archs = "x86_64 arm64"
test-skip = "*_universal2:arm64"
# MACOS linker doesn't support stripping symbols
environment = {CFLAGS="-fno-strict-aliasing -DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", NPY_USE_BLAS_ILP64="1", CC="clang", CXX = "clang++", RUNNER_OS="macOS"}
[tool.cibuildwheel.windows]
archs = ['AMD64']
environment = {NPY_USE_BLAS_ILP64="1", CFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", CXXFLAGS="-DBLAS_SYMBOL_SUFFIX=64_ -DHAVE_BLAS_ILP64", LDFLAGS="", PKG_CONFIG_PATH="C:/opt/64/lib/pkgconfig"}
config-settings = "setup-args=--vsenv"
repair-wheel-command = "bash ./tools/wheels/repair_windows.sh {wheel} {dest_dir}"
#[[tool.cibuildwheel.overrides]]
# Note: 32-bit Python wheel builds are skipped right now; probably needs
# --native-file to build due to `arch != pyarch` check in Meson's `python` dependency
# Note: uses 32-bit rather than 64-bit OpenBLAS
#select = "*-win32"
#environment = CFLAGS="-m32", LDFLAGS="-m32", PKG_CONFIG_PATH="/opt/32/lib/pkgconfig"}
[tool.spin]
package = 'numpy'
[tool.spin.meson]
cli = 'vendored-meson/meson/meson.py'
[tool.spin.commands]
"Build" = [
".spin/cmds.py:build",
".spin/cmds.py:test",
".spin/cmds.py:mypy",
]
"Environments" = [
".spin/cmds.py:run", ".spin/cmds.py:ipython",
".spin/cmds.py:python", ".spin/cmds.py:gdb"
]
"Documentation" = [".spin/cmds.py:docs"]
"Metrics" = [".spin/cmds.py:bench"]