gnu: emacs-ess: Improve package style.

* gnu/packages/statistics.scm (emacs-ess)[origin]: Remove trailing #T from
snippet.  Use G-expressions.
[arguments]: Use G-expressions.
[inputs]: Remove labels.

Change-Id: Iaaf6371577e00c2cc1da0192e5f9f9102b4e76b0
This commit is contained in:
Nicolas Goaziou 2024-01-04 15:12:10 +01:00
parent c61532c4b4
commit 650b9021a1
No known key found for this signature in database
GPG Key ID: DA00B4F048E92F2D

View File

@ -6774,77 +6774,77 @@ Java package that provides routines for various statistical distributions.")
(file-name (git-file-name name version)) (file-name (git-file-name name version))
(modules '((guix build utils))) (modules '((guix build utils)))
(snippet (snippet
'(begin #~(begin
;; Stop ESS from trying to bundle an external julia-mode.el. ;; Stop ESS from trying to bundle an external julia-mode.el.
(substitute* "lisp/Makefile" (substitute* "lisp/Makefile"
((" \\$\\(JULIAS)") "") ((" \\$\\(JULIAS)") "")
(("\ttest.*julia-mode.*\\.el") "")) (("\ttest.*julia-mode.*\\.el") ""))
;; Only build docs in info format. ;; Only build docs in info format.
(substitute* "doc/Makefile" (substitute* "doc/Makefile"
(("all : info text") (("all : info text")
"all : info") "all : info")
(("install: install-info install-other-docs") (("install: install-info install-other-docs")
"install: install-info")) "install: install-info"))
;; Stop install-info from trying to update the info directory. ;; Stop install-info from trying to update the info directory.
(substitute* "doc/Makefile" (substitute* "doc/Makefile"
((".*/dir.*") "")) ((".*/dir.*") ""))
;; Fix r-help-mode test. ;; Fix r-help-mode test.
(substitute* "test/ess-test-r.el" (substitute* "test/ess-test-r.el"
(("\\(equal ess-help-object \"plot.default\")") "t")) (("\\(equal ess-help-object \"plot.default\")") "t"))
;; Avoid generating ess-autoloads.el twice. ;; Avoid generating ess-autoloads.el twice.
(substitute* "Makefile" (substitute* "Makefile"
(("all: lisp doc etc autoloads") (("all: lisp doc etc autoloads")
"all: lisp doc etc")) "all: lisp doc etc"))
;; Install to correct directories. ;; Install to correct directories.
(substitute* "Makefile" (substitute* "Makefile"
(("mkdir -p \\$\\(ESSDESTDIR)") (("mkdir -p \\$\\(ESSDESTDIR)")
"$(MAKE) -C lisp install; $(MAKE) -C doc install") "$(MAKE) -C lisp install; $(MAKE) -C doc install")
(("\\$\\(INSTALL) -R \\./\\* \\$\\(ESSDESTDIR)/") (("\\$\\(INSTALL) -R \\./\\* \\$\\(ESSDESTDIR)/")
"$(MAKE) -C etc install")) "$(MAKE) -C etc install"))))))
#t))))
(build-system gnu-build-system) (build-system gnu-build-system)
(arguments (arguments
(let ((base-directory "/share/emacs/site-lisp")) (let ((base-directory "/share/emacs/site-lisp"))
`(#:make-flags (list (string-append "PREFIX=" %output) (list
(string-append "ETCDIR=" %output #:make-flags
,base-directory "/etc") #~(list (string-append "PREFIX=" #$output)
(string-append "LISPDIR=" %output (string-append "ETCDIR=" #$output #$base-directory "/etc")
,base-directory) (string-append "LISPDIR=" #$output #$base-directory)
(string-append "INFODIR=" %output (string-append "INFODIR=" #$output "/share/info"))
"/share/info")) #:phases
#:phases #~(modify-phases %standard-phases
(modify-phases %standard-phases (delete 'configure)
(delete 'configure) (add-before 'check 'skip-failing-tests
(add-before 'check 'skip-failing-tests ;; XXX: Skip 10 failing tests (out of 187).
;; XXX: Skip 10 failing tests (out of 187). (lambda _
(lambda _ (let-syntax
(let-syntax ((disable-tests
((disable-tests (syntax-rules ()
(syntax-rules () ((_ file ())
((_ file ()) (syntax-error "test names list must not be empty"))
(syntax-error "test names list must not be empty")) ((_ file (test-name ...))
((_ file (test-name ...)) (substitute* file
(substitute* file (((string-append "^\\(ert-deftest " test-name ".*")
(((string-append "^\\(ert-deftest " test-name ".*") all) all)
(string-append all "(skip-unless nil)\n")) ...))))) (string-append all "(skip-unless nil)\n"))
(disable-tests (list "test/ess-test-inf.el" "test/ess-test-r.el") ...)))))
("ess--derive-connection-path" (disable-tests (list "test/ess-test-inf.el"
"ess-eval-line-test" "test/ess-test-r.el")
"ess-eval-region-test" ("ess--derive-connection-path"
"ess-mock-remote-process" "ess-eval-line-test"
"ess-r-load-ESSR-github-fetch-no" "ess-eval-region-test"
"ess-r-load-ESSR-github-fetch-yes" "ess-mock-remote-process"
"ess-r-eval-ns-env-roxy-tracebug-test" "ess-r-load-ESSR-github-fetch-no"
"ess-r-eval-sink-freeze-test" "ess-r-load-ESSR-github-fetch-yes"
"ess-set-working-directory-test" "ess-r-eval-ns-env-roxy-tracebug-test"
"ess-test-r-startup-directory"))))) "ess-r-eval-sink-freeze-test"
(replace 'check "ess-set-working-directory-test"
(lambda _ (invoke "make" "test"))))))) "ess-test-r-startup-directory")))))
(replace 'check
(lambda _ (invoke "make" "test")))))))
(native-inputs (native-inputs
(list perl r-roxygen2 texinfo)) (list perl r-roxygen2 texinfo))
(inputs (inputs
`(("emacs" ,emacs-minimal) (list emacs-minimal r-minimal))
("r-minimal" ,r-minimal)))
(propagated-inputs (propagated-inputs
(list emacs-julia-mode)) (list emacs-julia-mode))
(home-page "https://ess.r-project.org/") (home-page "https://ess.r-project.org/")