diff options
| author | Andreas Enge <andreas@enge.fr> | 2026-01-26 22:44:05 +0100 |
|---|---|---|
| committer | Andreas Enge <andreas@enge.fr> | 2026-02-15 20:31:58 +0100 |
| commit | 3105008fdac4bb97005c72e50002d7327e81e8dd (patch) | |
| tree | d5fa460944cc94be5b4e2c51ed398a0ed1430bf9 | |
| parent | 1cd8b5ef4dd39a764f95663a18b83f1a26dd16d3 (diff) | |
gnu: sage: Build with meson instead of setuptools.
* gnu/packages/sagemath.scm (sage)[native-inputs]: Replace
python-setuptools by meson-python. Add python-sphinx.
[arguments]<#:phases>{patch-source}: Patch out checks for maxima from ecl.
It is not found by meson, but will be found by sage due to our patching
of src/sage/env.py.
[setup]: Do not chdir into src, so that the higher level pyproject.toml
is used for the build with meson.
Change-Id: Id3f8fbc4e9097f31a5e56ee8a49d2d2772620cf5
| -rw-r--r-- | gnu/packages/sagemath.scm | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/gnu/packages/sagemath.scm b/gnu/packages/sagemath.scm index 327434dd9df..b932b046cb1 100644 --- a/gnu/packages/sagemath.scm +++ b/gnu/packages/sagemath.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2019, 2025 Andreas Enge <andreas@enge.fr> +;;; Copyright © 2019, 2025, 2026 Andreas Enge <andreas@enge.fr> ;;; Copyright © 2024, 2025 Vinicius Monego <monego@posteo.net> ;;; Copyright © 2025 Ricardo Wurmus <rekado@elephly.net> ;;; @@ -35,6 +35,7 @@ #:use-module (gnu packages base) #:use-module (gnu packages bdw-gc) #:use-module (gnu packages boost) + #:use-module (gnu packages build-tools) #:use-module (gnu packages check) #:use-module (gnu packages compression) #:use-module (gnu packages fontutils) @@ -51,7 +52,8 @@ #:use-module (gnu packages python) #:use-module (gnu packages python-build) #:use-module (gnu packages python-science) - #:use-module (gnu packages python-xyz)) + #:use-module (gnu packages python-xyz) + #:use-module (gnu packages sphinx)) (define-public brial (package @@ -377,12 +379,13 @@ database.") (build-system pyproject-build-system) (native-inputs (list autoconf automake m4 pkg-config ; for ./bootstrap + meson-python python-cython python-cysignals python-memory-allocator python-pkgconfig python-jinja2 - python-setuptools + python-sphinx python-wheel)) (propagated-inputs (list ;; required to make the sage script start @@ -471,6 +474,10 @@ database.") (sed #$(this-package-input "sed")) (graphs #$(this-package-input "graphs")) (polytopes-db #$(this-package-input "polytopes-db"))) + ;; Patch out meson checks for things that will work since we + ;; patch env.py below. + (substitute* "src/sage/libs/meson.build" + (("maxima_check.returncode\\(\\) == 0") "true")) (substitute* (find-files "build/bin") (("sage-bootstrap-python") "python")) (substitute* "src/sage/env.py" @@ -519,8 +526,7 @@ database.") (lambda _ (setenv "SAGE_NUM_THREADS" (number->string (parallel-job-count))) - (invoke "./bootstrap") - (chdir "src"))) + (invoke "./bootstrap"))) (delete 'sanity-check)))) ; does not reflect reality (home-page "https://www.sagemath.org/") (synopsis "SageMath computer algebra system") |
