[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
07/33: gnu: emacs-telega: Adjust to changes in emacs-build-system.
From: |
guix-commits |
Subject: |
07/33: gnu: emacs-telega: Adjust to changes in emacs-build-system. |
Date: |
Sat, 1 May 2021 14:37:48 -0400 (EDT) |
leoprikler pushed a commit to branch master
in repository guix.
commit 132560821cbfd19a2c64ba7b2182d64c99f8dbfa
Author: Leo Prikler <leo.prikler@student.tugraz.at>
AuthorDate: Sat Apr 17 19:06:22 2021 +0200
gnu: emacs-telega: Adjust to changes in emacs-build-system.
* gnu/packages/emacs-telega.scm (emacs-telega)[#:phases]: Reorder.
<telega-paths-patch>: Rename to...
<patch-sources>: ... this. Also don't patch paths to subdirs.
Remove the snippet, that would push contrib to the load path.
<server-suite-patch>: Rename to...
<patch-test-suite>: ... this.
<emacs-install>: Also install etc.
<emacs-bytecomp-contrib, telega-install-contrib, telega-install-data>:
Removed
phases.
---
gnu/packages/emacs-xyz.scm | 62 +++++++++++-----------------------------------
1 file changed, 15 insertions(+), 47 deletions(-)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 521a9c7..97ed989 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -25328,7 +25328,9 @@ other @code{helm-type-file} sources such as
@code{helm-locate}.")
(("python3 run_tests.py")
""))
#t))
- (add-after 'check 'telega-paths-patch
+ (add-after 'unpack 'expand-load-path
+ (assoc-ref emacs:%standard-phases 'expand-load-path))
+ (add-after 'unpack 'patch-sources
(lambda* (#:key inputs #:allow-other-keys)
;; Hard-code paths to `ffplay` and `ffmpeg`.
(let ((ffplay-bin (string-append (assoc-ref inputs "ffmpeg")
@@ -25344,24 +25346,15 @@ other @code{helm-type-file} sources such as
@code{helm-locate}.")
(string-append
"(and (file-executable-p \"" ffmpeg-bin "\")"
"\"" ffmpeg-bin "\")"))))
- ;; Modify telega-util to reflect unique dir name in
- ;; `telega-install-data' phase.
- (substitute* "telega-util.el"
- (("\\(concat \"etc/\" filename\\) telega--lib-directory")
- "(concat \"telega-data/\" filename)
- (locate-dominating-file telega--lib-directory
- \"telega-data\")"))
- ;; Modify telega.el to reflect unique dir name in
- ;; `telega-install-contrib' phase.
+ ;; This would push the "contrib" sources to the load path,
+ ;; but as contrib is not installed alongside telega, it does
+ ;; nothing.
(substitute* "telega.el"
- (("\\(push \\(expand-file-name \"contrib\"
telega--lib-directory\\) load-path\\)")
- "(push (expand-file-name \"telega-contrib\"
- (locate-dominating-file telega--lib-directory
- \"telega-contrib\")) load-path)"))
+ (("\\(push .* load-path\\)") ""))
#t))
;; The server test suite has a hardcoded path.
;; Reset this behavior to use the proper path.
- (add-after 'unpack 'server-suite-patch
+ (add-after 'unpack 'patch-test-suite
(lambda _
(substitute* "server/run_tests.py"
(("~/.telega/telega-server")
@@ -25373,39 +25366,14 @@ other @code{helm-type-file} sources such as
@code{helm-locate}.")
(invoke "python3" "server/run_tests.py")
#t))
(delete 'configure)
- ;; Build emacs-side using `emacs-build-system'
- (add-after 'compress-documentation 'emacs-add-source-to-load-path
- (assoc-ref emacs:%standard-phases 'add-source-to-load-path))
- ;; Manually invoke bytecompilation for the contrib
- ;; subdirectory.
- (add-after 'emacs-add-source-to-load-path 'emacs-bytecomp-contrib
- (lambda _
- (substitute* "Makefile"
- (("byte-recompile-directory \".\"")
- "byte-recompile-directory \"contrib\""))
- (invoke "make" "compile")
- #t))
- (add-after 'emacs-bytecomp-contrib 'emacs-install
- (assoc-ref emacs:%standard-phases 'install))
- ;; This step installs subdir /etc, which contains images, sounds and
- ;; various other data, next to the site-lisp dir.
- (add-after 'emacs-install 'telega-install-data
- (lambda* (#:key outputs #:allow-other-keys)
- (copy-recursively
- "etc"
- (string-append (assoc-ref outputs "out")
- "/share/emacs/telega-data/"))
- #t))
- (add-after 'emacs-install 'telega-install-contrib
- (lambda* (#:key outputs #:allow-other-keys)
- (copy-recursively
- "contrib"
- (string-append (assoc-ref outputs "out")
- "/share/emacs/telega-contrib"))
- #t))
- (add-after 'telega-install-contrib 'emacs-build
+ (add-after 'expand-load-path 'emacs-install
+ (lambda args
+ (apply (assoc-ref emacs:%standard-phases 'install)
+ #:include `("etc" ,@emacs:%default-include)
+ args)))
+ (add-after 'emacs-install 'emacs-build
(assoc-ref emacs:%standard-phases 'build))
- (add-after 'telega-install-contrib 'emacs-make-autoloads
+ (add-after 'emacs-install 'emacs-make-autoloads
(assoc-ref emacs:%standard-phases 'make-autoloads)))))
(inputs
`(("ffmpeg" ,ffmpeg))) ; mp4/gif support.
- 09/33: gnu: emacs-emacsql: Adjust to changes in emacs-build-system., (continued)
- 09/33: gnu: emacs-emacsql: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 16/33: gnu: emacs-org-contrib: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 22/33: gnu: emacs-realgud: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 19/33: gnu: emacs-vterm: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 20/33: gnu: notmuch: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 25/33: gnu: emacs-guix: Update to 0.5.2-4.8ce6d21., guix-commits, 2021/05/01
- 23/33: gnu: emacs-geiser: Update to 0.13., guix-commits, 2021/05/01
- 29/33: gnu: emacs-dvc: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 33/33: gnu: emacs-julia-snail: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 10/33: gnu: emacs-howm: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 07/33: gnu: emacs-telega: Adjust to changes in emacs-build-system.,
guix-commits <=
- 14/33: gnu: emacs-sly-stepper: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 24/33: gnu: Add emacs-geiser-guile., guix-commits, 2021/05/01
- 11/33: gnu: emacs-ert-runner: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 21/33: gnu: emacs-pyim: Update to 3.6., guix-commits, 2021/05/01
- 18/33: gnu: emacs-scel: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 32/33: gnu: emacs-haskell-mode: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01
- 26/33: gnu: emacs-flycheck-guile: Add missing input., guix-commits, 2021/05/01
- 27/33: gnu: guile-studio: Add missing input., guix-commits, 2021/05/01
- 31/33: gnu: emacs-wget: Port to emacs-build-system., guix-commits, 2021/05/01
- 28/33: gnu: geiser-gauche: Adjust to changes in emacs-build-system., guix-commits, 2021/05/01