# Note that in maintenance branches, all build dependencies should # have an upper bound equal to the most recent already-released version # of the dependency. This to prevent that a future backwards-incompatible # release will break the source build of a SciPy release. # Do accept micro (bug-fix) releases. So for example, if pybind11 2.4.3 is # the most recent version on PyPI: # # "pybind11>=2.4.3,<2.5.0", [build-system] build-backend = 'mesonpy' requires = [ "meson-python>=0.9.0", # we need more fixes in meson-python, so no upper bound now "Cython>=0.29.32,<3.0", "pybind11>=2.4.3,<2.11.0", "pythran>=0.9.12,<0.13.0", # `wheel` is needed for non-isolated builds, given that `meson-python` # doesn't list it as a runtime requirement (at least in 0.5.0) "wheel<0.38.0", # NumPy dependencies - to update these, sync from # https://github.com/scipy/oldest-supported-numpy/, and then # update minimum version to match our install_requires min version # ---------------------------------------------------------------- # numpy 1.19 was the first minor release to provide aarch64 wheels, but # wheels require fixes contained in numpy 1.19.2 "numpy==1.19.2; python_version=='3.8' and platform_machine=='aarch64' and platform_python_implementation != 'PyPy'", # aarch64 for py39 is covered by default requirement below # arm64 on Darwin supports Python 3.8 and above requires numpy>=1.21.0 # (first version with arm64 wheels available) "numpy==1.21.0; python_version=='3.8' and platform_machine=='arm64' and platform_system=='Darwin'", "numpy==1.21.0; python_version=='3.9' and platform_machine=='arm64' and platform_system=='Darwin'", # loongarch64 requires numpy>=1.22.0 "numpy==1.22.0; platform_machine=='loongarch64'", # On Windows we need to avoid 1.21.6, 1.22.0 and 1.22.1 because they were # built with vc142. 1.22.3 is the first version that has 32-bit Windows # wheels *and* was built with vc141. So use that: "numpy==1.22.3; python_version=='3.10' and platform_system=='Windows' and platform_python_implementation != 'PyPy'", # default numpy requirements "numpy==1.18.5; python_version=='3.8' and (platform_machine!='arm64' or platform_system!='Darwin') and platform_machine!='aarch64' and platform_machine!='loongarch64' and platform_python_implementation != 'PyPy'", "numpy==1.19.3; python_version=='3.9' and (platform_machine!='arm64' or platform_system!='Darwin') and platform_machine!='loongarch64' and platform_python_implementation != 'PyPy'", # Note that 1.21.3 was the first version with a complete set of 3.10 wheels, # however macOS was broken and it's safe C API/ABI-wise to build against 1.21.6 # (see oldest-supported-numpy issues gh-28 and gh-45) "numpy==1.21.6; python_version=='3.10' and (platform_system!='Windows' and platform_machine!='loongarch64') and platform_python_implementation != 'PyPy'", "numpy==1.23.2; python_version=='3.11' and platform_python_implementation != 'PyPy'", # For Python versions which aren't yet officially supported, # we specify an unpinned NumPy which allows source distributions # to be used and allows wheels to be used as soon as they # become available. "numpy; python_version>='3.12'", "numpy; python_version>='3.8' and platform_python_implementation=='PyPy'", ] [project] name = "SciPy" # TODO: add `license-files` once PEP 639 is accepted (see meson-python#88) # at that point, no longer include them in `py3.install_sources()` license = {file = "LICENSE.txt"} description = "Fundamental algorithms for scientific computing in Python" maintainers = [ {name = "SciPy Developers", email = "scipy-dev@python.org"}, ] # Note: Python and NumPy upper version bounds should be set correctly in # release branches, see: # https://scipy.github.io/devdocs/dev/core-dev/index.html#version-ranges-for-numpy-and-other-dependencies requires-python = ">=3.8" dependencies = [ # TODO: update to "pin-compatible" once possible, see # https://github.com/FFY00/meson-python/issues/29 "numpy>=1.18.5,<1.26.0", ] readme = "README.rst" 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.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Topic :: Software Development :: Libraries", "Topic :: Scientific/Engineering", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX :: Linux", "Operating System :: POSIX", "Operating System :: Unix", "Operating System :: MacOS", ] dynamic = ['version'] [project.optional-dependencies] test = [ "pytest", "pytest-cov", "pytest-xdist", "asv", "mpmath", "gmpy2", "threadpoolctl", "scikit-umfpack", ] doc = [ "sphinx!=4.1.0", "pydata-sphinx-theme==0.9.0", "sphinx-panels>=0.5.2", "matplotlib>2", "numpydoc", "sphinx-tabs", ] dev = [ "mypy", "typing_extensions", "pycodestyle", "flake8", ] [project.urls] homepage = "https://scipy.org/" documentation = "https://docs.scipy.org/doc/scipy/" source = "https://github.com/scipy/scipy" download = "https://github.com/scipy/scipy/releases" tracker = "https://github.com/scipy/scipy/issues" [tool.doit] dodoFile = "do.py" [tool.cibuildwheel] skip = "cp36-* cp37-* pp* *_ppc64le *_i686 *_s390x *-musllinux*" build-verbosity = "3" # gmpy2 and scikit-umfpack are usually added for testing. However, there are # currently wheels missing that make the test script fail. test-requires = ["pytest", "pytest-cov", "pytest-xdist", "asv", "mpmath", "threadpoolctl", "pooch"] test-command = "bash {project}/tools/wheels/cibw_test_command.sh {project}" [tool.cibuildwheel.linux] manylinux-x86_64-image = "manylinux2014" manylinux-aarch64-image = "manylinux2014" before-build = "bash {project}/tools/wheels/cibw_before_build_linux.sh {project}" [tool.cibuildwheel.macos] before-build = "bash {project}/tools/wheels/cibw_before_build_macos.sh {project}" test-skip = "*_arm64 *_universal2:arm64" [tool.cibuildwheel.windows] before-build = "bash {project}/tools/wheels/cibw_before_build_win.sh {project}" repair-wheel-command = "bash ./tools/wheels/repair_windows.sh {wheel} {dest_dir}" [[tool.cibuildwheel.overrides]] select = "*-win32" [[tool.cibuildwheel.overrides]] select = "*-win_amd64" # can use pkg-config detection for win_amd64 because the installed rtools # provide a working pkg-config. # An alternative is to set CMAKE_PREFIX_PATH="c:/opt/openblas/if_32/32" # Don't use double backslash for path separators, they don't get passed # to the build correctly environment = { PKG_CONFIG_PATH="c:/opt/openblas/if_32/64/lib/pkgconfig" } [[tool.cibuildwheel.overrides]] select = "*-manylinux_aarch64" before-test = "" test-requires = ["pytest", "threadpoolctl"] test-command = "bash {project}/tools/wheels/cibw_test_command_manylinux_aarch64.sh {project}"