From 5dbc7d0f7b2d655b5c6305850f77b6aca0dcf28f Mon Sep 17 00:00:00 2001 From: Ghislain Vaillant Date: Mon, 24 Aug 2026 15:23:29 +0200 Subject: hep: Add recola2. * guix-science/packages/hep.scm (recola2): New variable. --- guix-science/packages/hep.scm | 82 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) diff --git a/guix-science/packages/hep.scm b/guix-science/packages/hep.scm index 3140aff..aa8c990 100644 --- a/guix-science/packages/hep.scm +++ b/guix-science/packages/hep.scm @@ -1163,6 +1163,88 @@ numerical computation of EW and QCD amplitudes in the Standard Model at next-to-leading order.") (license license:gpl3))) +(define-public recola2 + (package + (name "recola2") + (version "2.3.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/recola/recola2.git") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1xp0k1mc4c74k3hxb13s9qzdddwzmz3pazr5k8nmyixzdq1gii0j")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list "-Dwith_smtests:BOOL=ON" + (string-append "-Dcollier_DIR:PATH=" + #$(this-package-input "collier") "/lib/cmake") + (string-append "-DMDL_SEARCH_PATH:PATH=" + #$(this-package-input "recola2-modelfile-sm") + "/lib/cmake")) + #:imported-modules (append %cmake-build-system-modules + %pyproject-build-system-modules) + #:modules '((guix build cmake-build-system) + ((guix build pyproject-build-system) + #:prefix py:) + (guix build utils)) + #:phases + #~(modify-phases %standard-phases + ;; Requires install first. + (delete 'check) + + (add-after 'install 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "make" "check")))) + + (add-before 'check 'add-installed-pythonpath + (lambda* (#:key inputs outputs #:allow-other-keys) + (py:add-installed-pythonpath inputs outputs)))))) + (inputs (list collier recola2-modelfile-sm)) + (native-inputs (list gfortran python-wrapper)) + (home-page "https://recola.gitlab.io/") + (synopsis "Recursive Computation of 1-Loop Amplitudes (version 2)") + (description + "Recola2 is a Fortran95 computer program for the automated generation and +numerical evaluation of amplitudes in general quantum field theories at one-loop +order. It is the successor of Recola and extends it by additional features.") + (license license:gpl3))) + +(define-public recola2-modelfile-sm + (let ((commit "83cc243dbce331e41905bd0d95e232f62263d380") + (revision "0") + (version "2.2.3")) + (package + (name "recola2-modelfile-sm") + (version (git-version version revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/recola/models/sm.git") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0i4pc54b0y5lpaylxvkrbrp4d3aaxd1fd7wx5ycf145zgl64df7n")))) + (build-system cmake-build-system) + (arguments + (list + #:tests? #f ;no tests + #:configure-flags + #~(list (string-append "-DCOLLIER_LIB_PATH:PATH=" + #$(this-package-input "collier") "/lib/cmake")))) + (inputs (list collier)) + (native-inputs (list gfortran)) + (home-page "https://recola.gitlab.io/modelfiles/sm.html") + (synopsis "Standard model for Recola2") + (description "Standard model for Recola2.") + (license license:gpl3)))) + (define-public sherpa (package (name "sherpa") -- cgit v1.2.3