[PATCH] gnu: emacs-ess: Update to 18.10.2-0.24da603.

  • Done
  • quality assurance status badge
Details
3 participants
  • Ludovic Courtès
  • Nicolas Goaziou
  • Tim Howes
Owner
unassigned
Submitted by
Tim Howes
Severity
normal
T
T
Tim Howes wrote on 5 Sep 2020 01:50
[PATCH] gnu: emacs-ess: Update to 20200903.1516.
(address . guix-patches@gnu.org)
20200904235023.11193-1-timhowes@lavabit.com
* gnu/packages/statistics.scm (emacs-ess): Update to 20200903.1516.
[version]: Use latest commit, assign version based on commit date.
[source]: Fix snippet for removing julia-mode. Remove snippet to modify
roxy-preview-Rd-test. Add snippet to modify r-help-mode test. Add
snippet to fix install target to install files to correct directories.
[arguments]: Add flag to specify INFODIR. Remove patch modifying SHELL.
---
This updates emacs-ess to the current version on github and resolves
bugs #43093 and #42259.

gnu/packages/statistics.scm | 43 ++++++++++++++++---------------------
1 file changed, 19 insertions(+), 24 deletions(-)

Toggle diff (85 lines)
diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm
index c1cefa8c41..aa14e2887f 100644
--- a/gnu/packages/statistics.scm
+++ b/gnu/packages/statistics.scm
@@ -5805,29 +5805,24 @@ Java package that provides routines for various statistical distributions.")
(define-public emacs-ess
(package
(name "emacs-ess")
- (version "18.10.2")
+ ;; Use version number based on commit date and time (UTC), similar to melpa.
+ (version "20200903.1516")
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/emacs-ess/ESS")
- (commit (string-append "v" version))))
+ (commit "09c1adecf8406d85426d14e5efe2aaba6c59f224")))
(sha256
(base32
- "1yq41l2bicwjrc0b731iic20cpcnz6ppigri1jn621qv2qv22vy3"))
+ "0hl8nhf8w3rfpfqb2bfzcbh4lpsk51p83w2j5fc2knd4da4sb1s5"))
(file-name (git-file-name name version))
(modules '((guix build utils)))
(snippet
'(begin
;; Stop ESS from trying to bundle an external julia-mode.el.
(substitute* "lisp/Makefile"
- (("^ess-julia.elc: julia-mode.elc") "")
- (("^all: julia-mode.el")
- "all:"))
- ;; Include *.el files in install target.
- (substitute* "lisp/Makefile"
- (("\t\\$\\(INSTALL) \\$\\(ELC\\) \\$\\(LISPDIR\\)" elc)
- (string-append "\t$(INSTALL) $(ELS) ess-autoloads.el "
- "$(LISPDIR)\n" elc)))
+ ((" \\$\\(JULIAS)") "")
+ (("\ttest.*julia-mode.*\\.el") ""))
;; Only build docs in info format.
(substitute* "doc/Makefile"
(("all : info text")
@@ -5836,12 +5831,16 @@ Java package that provides routines for various statistical distributions.")
"install: install-info"))
;; Stop install-info from trying to update the info directory.
(substitute* "doc/Makefile"
- ((".*\\$\\(INFODIR\\)/dir.*") ""))
- ;; Fix roxygen preview test.
- (substitute* "test/ess-r-tests.el"
- (("Add together two numbers.\n")
- "Add together two numbers. ")
- (("##' add\\(10, 1\\)") "add(10, 1)"))
+ ((".*/dir.*") ""))
+ ;; Fix r-help-mode test.
+ (substitute* "test/ess-test-r.el"
+ (("\\(equal ess-help-object \"plot.default\")") "t"))
+ ;; Install to correct directories.
+ (substitute* "Makefile"
+ (("mkdir -p \\$\\(ESSDESTDIR)")
+ "$(MAKE) -C lisp install; $(MAKE) -C doc install")
+ (("\\$\\(INSTALL) -R \\./\\* \\$\\(ESSDESTDIR)/")
+ "$(MAKE) -C etc install"))
#t))))
(build-system gnu-build-system)
(arguments
@@ -5850,16 +5849,12 @@ Java package that provides routines for various statistical distributions.")
(string-append "ETCDIR=" %output
,base-directory "/etc")
(string-append "LISPDIR=" %output
- ,base-directory))
+ ,base-directory)
+ (string-append "INFODIR=" %output
+ "/share/info"))
#:phases
(modify-phases %standard-phases
(delete 'configure)
- (add-before 'build 'more-shebang-patching
- (lambda* (#:key inputs #:allow-other-keys)
- (substitute* "Makeconf"
- (("SHELL = /bin/sh")
- (string-append "SHELL = " (which "sh"))))
- #t))
(replace 'check
(lambda _
(invoke "make" "test")))))))
--
2.28.0
N
N
Nicolas Goaziou wrote on 5 Sep 2020 15:35
(name . Tim Howes via Guix-patches via)(address . guix-patches@gnu.org)
877dt8tkhj.fsf@nicolasgoaziou.fr
Hello,

Tim Howes via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (8 lines)
> * gnu/packages/statistics.scm (emacs-ess): Update to 20200903.1516.
> [version]: Use latest commit, assign version based on commit date.
> [source]: Fix snippet for removing julia-mode. Remove snippet to modify
> roxy-preview-Rd-test. Add snippet to modify r-help-mode test. Add
> snippet to fix install target to install files to correct directories.
> [arguments]: Add flag to specify INFODIR. Remove patch modifying
> SHELL.

Thank you.

Toggle quote (18 lines)
> This updates emacs-ess to the current version on github and resolves
> bugs #43093 and #42259.
>
> gnu/packages/statistics.scm | 43 ++++++++++++++++---------------------
> 1 file changed, 19 insertions(+), 24 deletions(-)
>
> diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm
> index c1cefa8c41..aa14e2887f 100644
> --- a/gnu/packages/statistics.scm
> +++ b/gnu/packages/statistics.scm
> @@ -5805,29 +5805,24 @@ Java package that provides routines for various statistical distributions.")
> (define-public emacs-ess
> (package
> (name "emacs-ess")
> - (version "18.10.2")
> + ;; Use version number based on commit date and time (UTC), similar to melpa.
> + (version "20200903.1516")

I don't think this numbering is great because it makes it difficult to
switch to the official one once it is increased. Usually, we add
a revision number to the version, see, e.g., emacs-ansi.

Otherwise, LGTM.

Regards,
--
Nicolas Goaziou
T
T
Tim Howes wrote on 5 Sep 2020 19:58
(address . 43208@debbugs.gnu.org)
6c878feb-8a41-b22f-366d-01678dbe5676@lavabit.com
Toggle quote (4 lines)
> I don't think this numbering is great because it makes it difficult to
> switch to the official one once it is increased. Usually, we add
> a revision number to the version, see, e.g., emacs-ansi.

That makes sense. It looks like there's actually a planned 20.09
release, so maybe I'll call this revision 0 of 20.09.

T
T
Tim Howes wrote on 5 Sep 2020 23:45
[PATCH] gnu: emacs-ess: Update to 20.09.
(address . 43208@debbugs.gnu.org)
20200905214524.17263-1-timhowes@lavabit.com
* gnu/packages/statistics.scm (emacs-ess): Update to 20.09.
[version]: Use version-revision-commit for version numbering.
[source]: Fix snippet for removing julia-mode. Remove snippet to modify
roxy-preview-Rd-test. Add snippet to modify r-help-mode test. Add
snippet to fix install target to install files to correct directories.
[arguments]: Add flag to specify INFODIR. Remove patch modifying SHELL.
---
This fixes the version numbering to consider this revision 0 of version
20.09, similar to how it's done for other emacs packages in guix.

gnu/packages/statistics.scm | 47 +++++++++++++++++--------------------
1 file changed, 22 insertions(+), 25 deletions(-)

Toggle diff (95 lines)
diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm
index c1cefa8c41..c705c71460 100644
--- a/gnu/packages/statistics.scm
+++ b/gnu/packages/statistics.scm
@@ -5803,31 +5803,28 @@ Java package that provides routines for various statistical distributions.")
(license license:gpl2+)))
(define-public emacs-ess
+ (let ((commit "82cd308ae54a6b918bbceb235e6bf02f53e48e19")
+ (version "20.09")
+ (revision "0"))
(package
(name "emacs-ess")
- (version "18.10.2")
+ (version (git-version version revision commit))
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/emacs-ess/ESS")
- (commit (string-append "v" version))))
+ (commit commit)))
(sha256
(base32
- "1yq41l2bicwjrc0b731iic20cpcnz6ppigri1jn621qv2qv22vy3"))
+ "0zw6j8jzrdmy41g6313js7c0xlmc2wmiazx4d4wm6hdvykn8q39k"))
(file-name (git-file-name name version))
(modules '((guix build utils)))
(snippet
'(begin
;; Stop ESS from trying to bundle an external julia-mode.el.
(substitute* "lisp/Makefile"
- (("^ess-julia.elc: julia-mode.elc") "")
- (("^all: julia-mode.el")
- "all:"))
- ;; Include *.el files in install target.
- (substitute* "lisp/Makefile"
- (("\t\\$\\(INSTALL) \\$\\(ELC\\) \\$\\(LISPDIR\\)" elc)
- (string-append "\t$(INSTALL) $(ELS) ess-autoloads.el "
- "$(LISPDIR)\n" elc)))
+ ((" \\$\\(JULIAS)") "")
+ (("\ttest.*julia-mode.*\\.el") ""))
;; Only build docs in info format.
(substitute* "doc/Makefile"
(("all : info text")
@@ -5836,12 +5833,16 @@ Java package that provides routines for various statistical distributions.")
"install: install-info"))
;; Stop install-info from trying to update the info directory.
(substitute* "doc/Makefile"
- ((".*\\$\\(INFODIR\\)/dir.*") ""))
- ;; Fix roxygen preview test.
- (substitute* "test/ess-r-tests.el"
- (("Add together two numbers.\n")
- "Add together two numbers. ")
- (("##' add\\(10, 1\\)") "add(10, 1)"))
+ ((".*/dir.*") ""))
+ ;; Fix r-help-mode test.
+ (substitute* "test/ess-test-r.el"
+ (("\\(equal ess-help-object \"plot.default\")") "t"))
+ ;; Install to correct directories.
+ (substitute* "Makefile"
+ (("mkdir -p \\$\\(ESSDESTDIR)")
+ "$(MAKE) -C lisp install; $(MAKE) -C doc install")
+ (("\\$\\(INSTALL) -R \\./\\* \\$\\(ESSDESTDIR)/")
+ "$(MAKE) -C etc install"))
#t))))
(build-system gnu-build-system)
(arguments
@@ -5850,16 +5851,12 @@ Java package that provides routines for various statistical distributions.")
(string-append "ETCDIR=" %output
,base-directory "/etc")
(string-append "LISPDIR=" %output
- ,base-directory))
+ ,base-directory)
+ (string-append "INFODIR=" %output
+ "/share/info"))
#:phases
(modify-phases %standard-phases
(delete 'configure)
- (add-before 'build 'more-shebang-patching
- (lambda* (#:key inputs #:allow-other-keys)
- (substitute* "Makeconf"
- (("SHELL = /bin/sh")
- (string-append "SHELL = " (which "sh"))))
- #t))
(replace 'check
(lambda _
(invoke "make" "test")))))))
@@ -5877,4 +5874,4 @@ Java package that provides routines for various statistical distributions.")
(description "Emacs Speaks Statistics (ESS) is an add-on package for GNU
Emacs. It is designed to support editing of scripts and interaction with
various statistical analysis programs such as R, Julia, and JAGS.")
- (license license:gpl2+)))
+ (license license:gpl2+))))
--
2.28.0
T
T
Tim Howes wrote on 6 Sep 2020 02:57
(address . 43208@debbugs.gnu.org)
d9d83e86-4636-583d-6c0a-5b495681c8b4@lavabit.com
retitle 43208 [PATCH] gnu: emacs-ess: Update to 20.09.
thanks
T
T
Tim Howes wrote on 6 Sep 2020 03:00
(address . control@debbugs.gnu.org)
0f9e8a6f-716a-721d-967b-4ee8a8205bdd@lavabit.com
retitle 43208 [PATCH] gnu: emacs-ess: Update to 20.09.
thanks
N
N
Nicolas Goaziou wrote on 6 Sep 2020 10:02
(name . Tim Howes via Guix-patches via)(address . guix-patches@gnu.org)
87pn6zs57k.fsf@nicolasgoaziou.fr
Hello,

Tim Howes via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (10 lines)
> * gnu/packages/statistics.scm (emacs-ess): Update to 20.09.
> [version]: Use version-revision-commit for version numbering.
> [source]: Fix snippet for removing julia-mode. Remove snippet to modify
> roxy-preview-Rd-test. Add snippet to modify r-help-mode test. Add
> snippet to fix install target to install files to correct directories.
> [arguments]: Add flag to specify INFODIR. Remove patch modifying SHELL.
> ---
> This fixes the version numbering to consider this revision 0 of version
> 20.09, similar to how it's done for other emacs packages in guix.

Thank you.

However, the base version should be 18.10.2, not 20.09, which is not
released yet.

BTW, when trying to build the package, I get the following failure:

INFO Scraping files for ess-autoloads.el...
.../lisp/ess-autoloads.el locked by nixbld@localh... (pid 103): (s, q, p, ?)?
Cannot resolve lock conflict in batch mode
make[1]: *** [Makefile:62: ess-autoloads.el] Error 255

Can you build the package successfully?

Regards,
--
Nicolas Goaziou
T
T
Tim Howes wrote on 8 Sep 2020 21:22
(name . Nicolas Goaziou)(address . mail@nicolasgoaziou.fr)(address . 43208@debbugs.gnu.org)
47d58bad-6a89-d342-4a16-72c2c5500d6b@lavabit.com
Toggle quote (9 lines)
> BTW, when trying to build the package, I get the following failure:
>
> INFO Scraping files for ess-autoloads.el...
> .../lisp/ess-autoloads.el locked by nixbld@localh... (pid 103): (s, q, p, ?)?
> Cannot resolve lock conflict in batch mode
> make[1]: *** [Makefile:62: ess-autoloads.el] Error 255
>
> Can you build the package successfully?

It builds successfully sometimes, but fails sporadically due to this
file locking issue. It seems like, the way the Makefile is set up, it's
trying to build the ess-autoloads target multiple times in parallel,
which is causing it to fail if two processes are trying to write to the
file at the same time. I'll take a look later to see if I can prevent
the problem.

Thanks,
Tim
L
L
Ludovic Courtès wrote on 24 Sep 2020 17:20
(name . Tim Howes)(address . timhowes@lavabit.com)
87tuvn6w1o.fsf@gnu.org
Hi Tim & Nicolas,

Any update on this?

Thanks,
Ludo’.

Tim Howes <timhowes@lavabit.com> skribis:

Toggle quote (16 lines)
>> BTW, when trying to build the package, I get the following failure:
>> INFO Scraping files for ess-autoloads.el...
>> .../lisp/ess-autoloads.el locked by nixbld@localh... (pid 103): (s, q, p, ?)?
>> Cannot resolve lock conflict in batch mode
>> make[1]: *** [Makefile:62: ess-autoloads.el] Error 255
>> Can you build the package successfully?
>
> It builds successfully sometimes, but fails sporadically due to this
> file locking issue. It seems like, the way the Makefile is set up,
> it's trying to build the ess-autoloads target multiple times in
> parallel, which is causing it to fail if two processes are trying to
> write to the file at the same time. I'll take a look later to see if I
> can prevent the problem.
>
> Thanks,
> Tim
T
T
Tim Howes wrote on 26 Sep 2020 11:40
[PATCH v3] gnu: emacs-ess: Update to 18.10.2-0.24da603.
(address . 43208@debbugs.gnu.org)
20200926094038.52041-1-timhowes@lavabit.com
* gnu/packages/statistics.scm (emacs-ess): Update to 18.10.2-0.24da603.
[version]: Use version-revision-commit for version numbering.
[source]: Fix snippet for removing julia-mode. Remove snippet to modify
roxy-preview-Rd-test. Add snippet to modify r-help-mode test. Add
snippet to fix install target to install files to correct directories.
Correct Makefile so that ess-autoloads.el is not built twice.
[arguments]: Add flag to specify INFODIR. Remove patch modifying SHELL.
[license]: License is now GPLv3+.
---

I corrected part of the Makefile that was causing ess-autoloads.el to be
built twice, which I think was causing the file locking issue. This
should now build reliably. I also selected a slightly older commit of
ESS to avoid this bug:

gnu/packages/statistics.scm | 51 +++++++++++++++++++------------------
1 file changed, 26 insertions(+), 25 deletions(-)

Toggle diff (99 lines)
diff --git a/gnu/packages/statistics.scm b/gnu/packages/statistics.scm
index 03a63e6ba1..b78ed4e6f5 100644
--- a/gnu/packages/statistics.scm
+++ b/gnu/packages/statistics.scm
@@ -5784,31 +5784,28 @@ Java package that provides routines for various statistical distributions.")
(license license:gpl2+)))
(define-public emacs-ess
+ (let ((commit "24da603184ce39246611dd5b8602e769d7ebd5bf")
+ (version "18.10.2")
+ (revision "0"))
(package
(name "emacs-ess")
- (version "18.10.2")
+ (version (git-version version revision commit))
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/emacs-ess/ESS")
- (commit (string-append "v" version))))
+ (commit commit)))
(sha256
(base32
- "1yq41l2bicwjrc0b731iic20cpcnz6ppigri1jn621qv2qv22vy3"))
+ "0j98lv07nzwzd54d4dgcfz01wy5gj48m0mnirxzh5r45ik2myh1r"))
(file-name (git-file-name name version))
(modules '((guix build utils)))
(snippet
'(begin
;; Stop ESS from trying to bundle an external julia-mode.el.
(substitute* "lisp/Makefile"
- (("^ess-julia.elc: julia-mode.elc") "")
- (("^all: julia-mode.el")
- "all:"))
- ;; Include *.el files in install target.
- (substitute* "lisp/Makefile"
- (("\t\\$\\(INSTALL) \\$\\(ELC\\) \\$\\(LISPDIR\\)" elc)
- (string-append "\t$(INSTALL) $(ELS) ess-autoloads.el "
- "$(LISPDIR)\n" elc)))
+ ((" \\$\\(JULIAS)") "")
+ (("\ttest.*julia-mode.*\\.el") ""))
;; Only build docs in info format.
(substitute* "doc/Makefile"
(("all : info text")
@@ -5817,12 +5814,20 @@ Java package that provides routines for various statistical distributions.")
"install: install-info"))
;; Stop install-info from trying to update the info directory.
(substitute* "doc/Makefile"
- ((".*\\$\\(INFODIR\\)/dir.*") ""))
- ;; Fix roxygen preview test.
- (substitute* "test/ess-r-tests.el"
- (("Add together two numbers.\n")
- "Add together two numbers. ")
- (("##' add\\(10, 1\\)") "add(10, 1)"))
+ ((".*/dir.*") ""))
+ ;; Fix r-help-mode test.
+ (substitute* "test/ess-test-r.el"
+ (("\\(equal ess-help-object \"plot.default\")") "t"))
+ ;; Avoid generating ess-autoloads.el twice.
+ (substitute* "Makefile"
+ (("all: lisp doc etc autoloads")
+ "all: lisp doc etc"))
+ ;; Install to correct directories.
+ (substitute* "Makefile"
+ (("mkdir -p \\$\\(ESSDESTDIR)")
+ "$(MAKE) -C lisp install; $(MAKE) -C doc install")
+ (("\\$\\(INSTALL) -R \\./\\* \\$\\(ESSDESTDIR)/")
+ "$(MAKE) -C etc install"))
#t))))
(build-system gnu-build-system)
(arguments
@@ -5831,16 +5836,12 @@ Java package that provides routines for various statistical distributions.")
(string-append "ETCDIR=" %output
,base-directory "/etc")
(string-append "LISPDIR=" %output
- ,base-directory))
+ ,base-directory)
+ (string-append "INFODIR=" %output
+ "/share/info"))
#:phases
(modify-phases %standard-phases
(delete 'configure)
- (add-before 'build 'more-shebang-patching
- (lambda* (#:key inputs #:allow-other-keys)
- (substitute* "Makeconf"
- (("SHELL = /bin/sh")
- (string-append "SHELL = " (which "sh"))))
- #t))
(replace 'check
(lambda _
(invoke "make" "test")))))))
@@ -5858,4 +5859,4 @@ Java package that provides routines for various statistical distributions.")
(description "Emacs Speaks Statistics (ESS) is an add-on package for GNU
Emacs. It is designed to support editing of scripts and interaction with
various statistical analysis programs such as R, Julia, and JAGS.")
- (license license:gpl2+)))
+ (license license:gpl3+))))
--
2.28.0
T
T
Tim Howes wrote on 26 Sep 2020 11:42
Re: [bug#43208] [PATCH] gnu: emacs-ess: Update to 20.09.
(address . control@debbugs.gnu.org)
0c107c98-fcd4-8262-0494-406ae47c16ed@lavabit.com
retitle 43208 [PATCH] gnu: emacs-ess: Update to 18.10.2-0.24da603.
thanks
N
N
Nicolas Goaziou wrote on 26 Sep 2020 13:02
Re: [PATCH v3] gnu: emacs-ess: Update to 18.10.2-0.24da603.
(name . Tim Howes)(address . timhowes@lavabit.com)
87k0wg6bsg.fsf@nicolasgoaziou.fr
Hello,

Tim Howes <timhowes@lavabit.com> writes:

Toggle quote (3 lines)
> * gnu/packages/statistics.scm (emacs-ess): Update to
> 18.10.2-0.24da603.

I added a small comment explaining why we provide an unstable version,
and applied your patch. Thank you.

Regards,
--
Nicolas Goaziou
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 43208@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 43208
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch