diff options
| -rw-r--r-- | dev-python/scipy/Manifest | 2 | ||||
| -rw-r--r-- | dev-python/scipy/scipy-1.16.0.ebuild | 169 |
2 files changed, 171 insertions, 0 deletions
diff --git a/dev-python/scipy/Manifest b/dev-python/scipy/Manifest index 8ea59ebdfc0f..e3cbd85ab355 100644 --- a/dev-python/scipy/Manifest +++ b/dev-python/scipy/Manifest @@ -1,6 +1,8 @@ DIST scipy-1.15.2.tar.gz 59417316 BLAKE2B 7ae748a58b6a7fb2674dc6627c3d6f4f28694283bf19ca9973fcf5796ccb0e2e35bb7cd8fbfbefa21cb832b771e563f478bc09ded61d989ea47625e7ac35e1bd SHA512 e772aa040622ef457478e08eb41471af33784cafc2022f091a30563f6abed067cdbae424a5ae86f9dab8c1adc67276794b67cb7cb7c7963ca55a38529df63834 DIST scipy-1.15.3.tar.gz 59419214 BLAKE2B 526e6182e4991e52fea69452b7894b203d31089ee1f8640ef1bff8f1fa57c31a7179a1ab82325689f3b0a7b907c34adb64b80e640780c99e166f6999adbb1524 SHA512 009de94a64c9361b261788ef3577d636a20ca23ff5c8f12f5e19a4ba4d6177ef7ade0cf1a5ee740bd1c6d740193d70b314d1abd83ab65fcb5d5cf2d2ba06bfb1 +DIST scipy-1.16.0.tar.gz 30581216 BLAKE2B faab7755584acfb6f2aa6a9e36a1fef840212d9b2478002313b94fd3762317be3d705e09d10960146bfbed5274cab80bd2170ce5bc3368b5ab860e8b5fe2f346 SHA512 6a88cc1b2f3e4cc7c4d867238965521e41b0394614a5ffcc7179b379dad20c0889a7ce4195ef676e78d7aa8d6f83f88f1380da8b225b59c4b6b87a9e6579efb7 DIST scipy-1.16.0rc1.tar.gz 30582387 BLAKE2B cc356de35aa7a821c3e363997ab014765df800ab8229c34b04d42088221391199b0726ff3d6cc09b5698aa1970d451a4f79993bb684f2f62d3c38a2a28e34149 SHA512 31c9fe5da1de08ebd7773040c2ac6de5d1d62daf4e52d95b78eacba93e0fcfcc91e97b672796d3084d2b48dc6718ba7e8b08daa91407b88449df727db349bf3f DIST scipy-1.16.0rc2.tar.gz 30582415 BLAKE2B ae9e6884367a1c82fa499eadc84e58589787eb1b933a809644ec9de73f22319eed0ad60557471f2897e09b16ecb12ee240ae01192a3337dda0149997f928bf7a SHA512 d1f55424d76cc84cfaf8f97960cb85fe943345003eb85cdb3a0db65bc3cceffd046f3cc9208712423cea2aeafd48985b3098044c5c34a357b713b4b47300c153 DIST scipy-html-1.15.2.zip 68568078 BLAKE2B 270f1d89bbcb707616f7af0e1bd90909c1f33d647cf55e42dbf27128ecd90f619f0d579d8897eb04851b6327df1682236c5fd9c4c948b1fd99b083145681a202 SHA512 48e09d3678547775c6c86b82cdb4ef5e7eed7722c6ba8d53170384c3a9380b2bb29fc467b5ee66ae2ec1a621930c8bf20adfc8db3a75546a6ba8e9906df03426 DIST scipy-html-1.15.3.zip 68590525 BLAKE2B f6473e273843e3eb2aa791be1b885a11ac2b77accdf00ea2d7bc78dc59228dede66259ff4d2ac616ceeb3152a80a8036226622240d963a8bce51dc0143b6aea4 SHA512 df59c2a53dc9c8a64631a2c9906762de046b9beefd759e0810afdcbb00e4da8800e83902d49fa81d791bccb0ed190e00f0ea4948b855e97ad9b5d7a0984d4eec +DIST scipy-html-1.16.0.zip 71540070 BLAKE2B eca4f76e6e3f4747e8e6a1c432c7b9fd52638ae37e00f50733b3eb7bc9f165f507478a8331b3420f158a5f316ba72c0925bf8933b9392638f1d346871fb5dd0a SHA512 839cf7511d7dce320da2966c45ff62056f93b35687e6fd42f2b0725dd4389f50a8ce69d125043de2632861b0bf5187af591558f9019e3543825255edd2372c12 diff --git a/dev-python/scipy/scipy-1.16.0.ebuild b/dev-python/scipy/scipy-1.16.0.ebuild new file mode 100644 index 000000000000..6b9f83c04b3b --- /dev/null +++ b/dev-python/scipy/scipy-1.16.0.ebuild @@ -0,0 +1,169 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +FORTRAN_NEEDED=fortran +DISTUTILS_EXT=1 +DISTUTILS_USE_PEP517=meson-python +PYTHON_COMPAT=( pypy3_11 python3_{11..13} ) +PYTHON_REQ_USE="threads(+)" + +inherit flag-o-matic fortran-2 distutils-r1 + +DESCRIPTION="Scientific algorithms library for Python" +HOMEPAGE=" + https://scipy.org/ + https://github.com/scipy/scipy/ + https://pypi.org/project/scipy/ +" + +if [[ ${PV} == *9999* ]] ; then + inherit git-r3 + + # Need submodules, so git for now. + EGIT_REPO_URI="https://github.com/scipy/scipy" + EGIT_BRANCH="maintenance/$(ver_cut 1-2).x" + EGIT_SUBMODULES=( '*' ) +else + inherit pypi + + # Upstream is often behind with doc updates + DOC_PV=${PV} + + SRC_URI+=" + doc? ( + https://docs.scipy.org/doc/${PN}-${DOC_PV}/${PN}-html-${DOC_PV}.zip + )" + + if [[ ${PV} != *rc* ]] ; then + KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" + fi +fi + +LICENSE="BSD LGPL-2" +SLOT="0" +IUSE="doc +fortran test-rust" + +# pythran is needed in both BDEPEND (for /usr/bin/pythran) and in DEPEND +# to actually compile code generated by pythran (headers and such needed). +# +# umfpack is technically optional but it's preferred to have it available. +DEPEND=" + dev-libs/boost:= + >=dev-python/numpy-1.23.5:=[lapack,${PYTHON_USEDEP}] + ~media-libs/qhull-2020.2:= + sci-libs/arpack:= + sci-libs/umfpack + virtual/cblas + >=virtual/lapack-3.8 +" +RDEPEND=" + ${DEPEND} + dev-python/pillow[${PYTHON_USEDEP}] +" +DEPEND+=" + fortran? ( + >=dev-python/pythran-0.16.0[${PYTHON_USEDEP}] + ) +" +BDEPEND=" + dev-lang/swig + >=dev-python/cython-3.0.8[${PYTHON_USEDEP}] + >=dev-python/meson-python-0.15.0[${PYTHON_USEDEP}] + >=dev-python/pybind11-2.13.2[${PYTHON_USEDEP}] + >=dev-build/meson-1.1.0 + !kernel_Darwin? ( dev-util/patchelf ) + virtual/pkgconfig + doc? ( app-arch/unzip ) + fortran? ( + >=dev-python/pythran-0.16.0[${PYTHON_USEDEP}] + ) + test? ( + >=dev-python/hypothesis-6.30[${PYTHON_USEDEP}] + ) + test-rust? ( + dev-python/pooch[${PYTHON_USEDEP}] + ) +" + +EPYTEST_XDIST=1 +distutils_enable_tests pytest + +src_unpack() { + default + + if use doc; then + unzip -qo "${DISTDIR}"/${PN}-html-${DOC_PV}.zip -d html || die + fi +} + +python_configure_all() { + DISTUTILS_ARGS=( + -Dblas=blas + -Dlapack=lapack + -Duse-pythran=$(usex fortran true false) + # note: recheck on version bumps, upstream is planning + # to allow more + '-Duse-system-libraries=boost.math,qhull' + ) + + # https://bugs.gentoo.org/932721 + has_version '>=dev-python/numpy-2.0.0' && filter-lto +} + +python_test() { + cd "${BUILD_DIR}/install$(python_get_sitedir)" || die + + local EPYTEST_DESELECT=( + # Network + scipy/datasets/tests/test_data.py::TestDatasets::test_existence_all + scipy/datasets/tests/test_data.py::TestDatasets::test_ascent + scipy/datasets/tests/test_data.py::TestDatasets::test_face + scipy/datasets/tests/test_data.py::TestDatasets::test_electrocardiogram + + # Crashes with assertion, not a regression + # https://github.com/scipy/scipy/issues/19321 + scipy/signal/tests/test_signaltools.py::test_lfilter_bad_object + + # Awfully slow tests + scipy/interpolate/tests/test_bsplines.py::TestBatch::test_batch + scipy/linalg/tests/test_basic.py::TestLstsq::test_random_complex_exact + scipy/sparse/linalg/_eigen/tests/test_svds.py::test_small_sigma_sparse + + # TODO: minor precision errors + 'scipy/linalg/tests/test_batch.py::TestBatch::test_solve[float32-bdim2]' + 'scipy/linalg/tests/test_batch.py::TestBatch::test_lu_solve[float32-bdim2]' + + # Crashes, probably too big + 'scipy/interpolate/tests/test_fitpack2.py::TestRectBivariateSpline::test_spline_large_2d_maxit' + ) + local EPYTEST_IGNORE=() + + if ! has_version -b "dev-python/pooch[${PYTHON_USEDEP}]" ; then + EPYTEST_IGNORE+=( + scipy/datasets/tests/test_data.py + ) + fi + + case ${EPYTHON} in + pypy3*) + EPYTEST_DESELECT+=( + # TODO + scipy/special/tests/test_data.py::test_boost + scipy/_lib/tests/test_ccallback.py::test_callbacks + ) + ;; + esac + + local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 + # avoid other stuff being multithreaded when using xdist + local -x PYTHON_CPU_COUNT=1 + epytest scipy +} + +python_install_all() { + use doc && local HTML_DOCS=( "${WORKDIR}"/html/. ) + + distutils-r1_python_install_all +} |
