From f1967dd68885ea68330b828f59aa95506596b209 Mon Sep 17 00:00:00 2001 From: Andreas Enge Date: Thu, 20 Feb 2025 11:34:38 +0100 Subject: [PATCH] gnu: gap: Enable the caratinterface package. * gnu/packages/algebra.scm (gap){prepare-package-source}: New phase to unpack the caratinterface source. {remove-packages}: Do not remove caratinterface. Change-Id: Id94fc276ee1a31df9acd81f8757e26d7b3e38366 --- gnu/packages/algebra.scm | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/gnu/packages/algebra.scm b/gnu/packages/algebra.scm index 845495612205a208c6229f009b167c60bcefa4e8..a8ad770c92469043adeaa84a14f98fd7f8c9eafa 100644 --- a/gnu/packages/algebra.scm +++ b/gnu/packages/algebra.scm @@ -1341,9 +1341,7 @@ xtensor provides: (method url-fetch) (uri (string-append "https://files.gap-system.org/gap-" (version-major+minor version) - "/tar.gz/gap-" - version - ".tar.gz")) + "/tar.gz/gap-" version ".tar.gz")) (sha256 (base32 "11v4a3cpjpf6pc0hd6x1wlglq9jzakq4naggp671psvgq9r54pw4")) (modules '((guix build utils) (ice-9 ftw) (srfi srfi-1))) @@ -1371,6 +1369,12 @@ xtensor provides: (list (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib")) #:phases (modify-phases %standard-phases + (add-after 'unpack 'prepare-package-source + (lambda _ + (with-directory-excursion "pkg" + ;; Unpack package tarball, so that shebangs can be modified. + (with-directory-excursion "caratinterface" + (invoke "tar" "xvf" "carat.tgz"))))) ;; The following phases are added after 'build, apparently in ;; reverse order. So we carry out 'build, then 'build-doc, then ;; 'remove-packages, then 'build-packages. @@ -1386,8 +1390,7 @@ xtensor provides: (lambda _ (with-directory-excursion "pkg" (for-each delete-file-recursively - '("caratinterface" ; ./configure: /bin/sh: bad interpreter: No such file or directory - "normalizinterface" ; tries to download normaliz even when it is available + '("normalizinterface" ; tries to download normaliz even when it is available "semigroups" ; bundled dependencies "xgap" ; make: /bin/sh: No such file or directory ))))) @@ -1400,11 +1403,6 @@ xtensor provides: ;; it requires the gap binary. (lambda _ (with-directory-excursion "doc" - ;; We do not build all packages, which breaks - ;; cross-references in the documentation. Since - ;; gap-4.14.0, this causes an error. -; (substitute* "make_doc" -; (("QuitGap\\(false\\);") "QuitGap(true);")) (invoke "./make_doc")))) (add-after 'install 'install-packages (lambda* (#:key outputs #:allow-other-keys) @@ -1420,7 +1418,7 @@ emphasis on computational group theory. It provides a programming language, a library of thousands of functions implementing algebraic algorithms written in the GAP language as well as large data libraries of algebraic objects.") - ;; gap itself is gpl2+, but some packages have different licenses. + ;; gap itself is gpl2+, but some packages have different licenses, ;; effectively forcing the combined work to be licensed as gpl3+. (license license:gpl3+)))