(name . guix-patches)(address . guix-patches@gnu.org)
Hello Guix!
This patch set strengthens our Emacs build system by enforcing strict
byte compilation of every Guix package using the `emacs-build-system'.
Before, errors during byte compilation would not signal a failure of the
build.
It also adds a custom check phase to make it easy to run any kind of
program or script that might be used as a test runner (commonly
ert-runner, sometimes make, etc.).
I've validated that our Emacs packages (at least those whose name start by
'emacs-') can be successfully built with those changes (240 were built
locally). Most of the patches below were necessary fixes to our Emacs
packages so that they could be successfully byte compiled.
Happy April Fools' Day ;)
Maxim
From 103834761802992380d45e31c5e8c833772aed90 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Thu, 29 Mar 2018 20:52:41 -0400
Subject: [PATCH 01/27] emacs-build-system: Consider all inputs for Elisp
dependencies.
* guix/build/emacs-build-system.scm (emacs-inputs): Remove.
(emacs-inputs-directories): Rename to...
(inputs->directories): this, and adapt for any input.
(emacs-input->el-directory): Rename to...
(inputs->el-directories): this, and adapt for any input.
(set-emacs-load-path): Now use inputs->el-directories and
inputs->el-directories.
---
guix/build/emacs-build-system.scm | 44 +++++++++++++--------------------------
1 file changed, 15 insertions(+), 29 deletions(-)
Toggle diff (70 lines)
diff --git a/guix/build/emacs-build-system.scm b/guix/build/emacs-build-system.scm
index b77984742..ba9ec88e4 100644
--- a/guix/build/emacs-build-system.scm
+++ b/guix/build/emacs-build-system.scm
@@ -76,8 +76,8 @@ archive, a directory, or an Emacs Lisp file."
(define* (set-emacs-load-path #:key inputs #:allow-other-keys)
"Set the EMACSLOADPATH environment variable so that dependencies are found."
- (let* ((input-elisp-dirs (emacs-inputs-el-directories
- (emacs-inputs-directories inputs)))
+ (let* ((input-elisp-dirs (inputs->el-directories
+ (inputs->directories inputs)))
(emacs-load-path-value (string-join
input-elisp-dirs ":" 'suffix)))
(setenv "EMACSLOADPATH" emacs-load-path-value)
@@ -210,39 +210,25 @@ store in '.el' files."
"Check if NAME correspond to the name of an Emacs package."
(string-prefix? "emacs-" name))
-(define (emacs-inputs inputs)
- "Retrieve the list of Emacs packages from INPUTS."
- (filter (match-lambda
- ((label . directory)
- (emacs-package? ((compose package-name->name+version
- strip-store-file-name)
- directory)))
- (_ #f))
- inputs))
+(define (inputs->directories inputs)
+ "Extract the directory part from INPUTS."
+ (match inputs
+ (((names . directories) ...) directories)))
-(define (emacs-inputs-directories inputs)
- "Extract the list of Emacs package directories from INPUTS."
- (let ((inputs (emacs-inputs inputs)))
- (match inputs
- (((names . directories) ...) directories))))
-
-(define (emacs-input->el-directory emacs-input)
- "Return the correct Elisp directory location of EMACS-INPUT or #f if none."
- (let ((legacy-elisp-dir (string-append emacs-input %legacy-install-suffix))
+(define (input->el-directory input-dir)
+ "Return the correct Elisp directory location of INPUT-DIR-DIR or #f."
+ (let ((legacy-elisp-dir (string-append input-dir %legacy-install-suffix))
(guix-elisp-dir (string-append
- emacs-input %install-suffix "/"
- (store-directory->elpa-name-version emacs-input))))
+ input-dir %install-suffix "/"
+ (store-directory->elpa-name-version input-dir))))
(cond
((file-exists? guix-elisp-dir) guix-elisp-dir)
((file-exists? legacy-elisp-dir) legacy-elisp-dir)
- (else (format #t "warning: could not locate elisp directory under `~a'\n"
- emacs-input)
- #f))))
+ (else #f))))
-(define (emacs-inputs-el-directories dirs)
- "Build the list of Emacs Lisp directories from the Emacs package directory
-DIRS."
- (filter-map emacs-input->el-directory dirs))
+(define (inputs->el-directories input-dirs)
+ "Build the list of Emacs Lisp directories from the INPUT-DIRS."
+ (filter-map input->el-directory input-dirs))
(define (package-name-version->elpa-name-version name-ver)
"Convert the Guix package NAME-VER to the corresponding ELPA name-version
--
2.16.1
From 407a80cef16ec9f8afadc78b3f59a0c5e930a0e6 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Mon, 12 Feb 2018 22:11:38 -0500
Subject: [PATCH 03/27] gnu: Adjust ert-runner wrapper to honor EMACSLOADPATH.
* gnu/packages/emacs.scm (ert-runner): Use 'prefix instead of '= for setting
the EMACSLOADPATH environment variable.
---
gnu/packages/emacs.scm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index ce9b1a66a..e9f79ae68 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -6123,7 +6123,7 @@ Emacs.")
,name "-" ,version)))
(install-file "bin/ert-runner" (string-append out "/bin"))
(wrap-program (string-append out "/bin/ert-runner")
- (list "EMACSLOADPATH" ":" '=
+ (list "EMACSLOADPATH" ":" 'prefix
(append
,(match dependencies
(((labels packages) ...)
--
2.16.1
From ebef14d5e028b19cf1d0827207491542b5616975 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 14:08:15 -0400
Subject: [PATCH 05/27] gnu: emacs-pdf-tools: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-pdf-tools)[phases]: Add set-emacs-load-path.
---
gnu/packages/emacs.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Toggle diff (17 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 05ef61f08..aa4d35a5b 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1469,7 +1469,9 @@ filters, new key bindings and faces. It can be enabled by
;; upgrading" that pdf-tools tries to perform.
(emacs-substitute-variables "pdf-tools.el"
("pdf-tools-handle-upgrades" '()))))
- (add-after 'emacs-patch-variables 'emacs-install
+ (add-after 'emacs-patch-variables 'set-emacs-load-path
+ (assoc-ref emacs:%standard-phases 'set-emacs-load-path))
+ (add-after 'add-cwd-to-load-path 'emacs-install
(assoc-ref emacs:%standard-phases 'install))
(add-after 'emacs-install 'emacs-build
(assoc-ref emacs:%standard-phases 'build))
--
2.16.1
From 1b04b1d85ad55dcca4852a02fa1e83802e6d555a Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 14:15:45 -0400
Subject: [PATCH 06/27] gnu: Add emacs-ert-expectations.
* gnu/packages/emacs.scm (emacs-ert-expectations): New variable.
---
gnu/packages/emacs.scm | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
Toggle diff (30 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index aa4d35a5b..cfbdcc9f3 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -2423,6 +2423,23 @@ A minor mode @code{debbugs-browse-mode} let you browse URLs to the GNU Bug
Tracker as well as bug identifiers prepared for @code{bug-reference-mode}.")
(license license:gpl3+)))
+(define-public emacs-ert-expectations
+ (package
+ (name "emacs-ert-expectations")
+ (version "0.2")
+ (source
+ (origin
+ (method url-fetch)
+ (uri "https://www.emacswiki.org/emacs/download/ert-expectations.el")
+ (sha256
+ (base32
+ "0cwy3ilsid90abzzjb7ha2blq9kmv3gfp3icwwfcz6qczgirq6g7"))))
+ (build-system emacs-build-system)
+ (home-page "https://www.emacswiki.org/emacs/download/ert-expectations.el")
+ (synopsis "Simple unit test framework for Emacs")
+ (description "A very simple unit test framework to use with @code{ERT}.")
+ (license license:gpl3+)))
+
(define-public emacs-deferred
(package
(name "emacs-deferred")
--
2.16.1
From 9177d71b30c33903ed194a8281f6a1090f3e82c6 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 16:01:05 -0400
Subject: [PATCH 07/27] gnu: emacs-deferred: Enable tests.
* gnu/packages/emacs.scm (emacs-deferred)[phases]: Add fix-makefile.
[tests?]: Set to #t
[test-command]: Add.
[native-inputs]: Add ert-runner, emacs-ert-expectations and emacs-undercover.
---
gnu/packages/emacs.scm | 19 ++++++++++++++++++-
1 file changed, 18 insertions(+), 1 deletion(-)
Toggle diff (32 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index cfbdcc9f3..648dbfb24 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -2455,7 +2455,24 @@ Tracker as well as bug identifiers prepared for @code{bug-reference-mode}.")
"0xy9zb6wwkgwhcxdnslqk52bq3z24chgk6prqi4ks0qcf2bwyh5h"))
(file-name (string-append name "-" version))))
(build-system emacs-build-system)
- ;; FIXME: Would need 'el-expectations' to actually run tests.
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'check 'fix-makefile
+ (lambda _
+ (substitute* "Makefile"
+ (("\\$\\(CASK\\) exec ") ""))
+ #t)))
+ #:tests? #t
+ ;; FIXME: Normally we'd run the "test" target but for some reason the
+ ;; test-deferred target fails when run in the Guix build environment
+ ;; with the error: (file-error "Searching for program" "No such file or
+ ;; directory" "/bin/sh").
+ #:test-command '("make" "test-concurrent" "test-concurrent-compiled")))
+ (native-inputs
+ `(("ert-runner" ,ert-runner)
+ ("emacs-ert-expectations" ,emacs-ert-expectations)
+ ("emacs-undercover" ,emacs-undercover)))
(synopsis "Simple asynchronous functions for Emacs Lisp")
(description
"The @code{deferred.el} library provides support for asynchronous tasks.
--
2.16.1
From 6c66fcb691b8e247db791dd16ee079543fa244b0 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 16:03:35 -0400
Subject: [PATCH 08/27] gnu: emacs-org-trello: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-org-trello)[native-inputs]: Add emacs-f and
emacs-helm.
---
gnu/packages/emacs.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Toggle diff (17 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 648dbfb24..e52b00393 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -2973,7 +2973,9 @@ started with 20 minutes. All values are customizable.")
`(("emacs-deferred" ,emacs-deferred)
("emacs-request" ,emacs-request)
("emacs-dash" ,emacs-dash)
- ("emacs-s" ,emacs-s)))
+ ("emacs-s" ,emacs-s)
+ ("emacs-f" ,emacs-f)
+ ("emacs-helm" ,emacs-helm)))
(home-page "https://org-trello.github.io")
(synopsis "Emacs minor mode for interacting with Trello")
(description "This package provides an Emacs minor mode to extend
--
2.16.1
From 4f56723c3a94a67bbf3d70b50372d54f4aedce8f Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 16:05:28 -0400
Subject: [PATCH 09/27] gnu: emacs-smartparens: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-smartparens)[propagated-inputs]: Add
emacs-markdown-mode.
---
gnu/packages/emacs.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Toggle diff (17 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index e52b00393..5fd95a636 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -3102,7 +3102,9 @@ single theme but a set of guidelines with numerous implementations.")
(base32
"0q5as813xs8y29i3v2rm97phd6m7xsmmw6hwbvx57gwmi8i1c409"))))
(build-system emacs-build-system)
- (propagated-inputs `(("emacs-dash" ,emacs-dash)))
+ (propagated-inputs
+ `(("emacs-dash" ,emacs-dash)
+ ("emacs-markdown-mode" ,emacs-markdown-mode)))
(home-page "https://github.com/Fuco1/smartparens")
(synopsis "Paredit-like insertion, wrapping and navigation with user
defined pairs")
--
2.16.1
From 22ac5d931c1e1d377c614e86b78aa512e25f9982 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 16:09:38 -0400
Subject: [PATCH 10/27] gnu: emacs-realgud: Adapt phase for the reworked
emacs-build-system.
* gnu/packages/emacs.scm (emacs-realgud)[phases]: Move the fix-autogen-script
after the set-emacs-load-path phase.
---
gnu/packages/emacs.scm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 5fd95a636..4c7bba5b2 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -3283,7 +3283,7 @@ after buffer changes.")
`(#:tests? #t
#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'fix-autogen-script
+ (add-after 'set-emacs-load-path 'fix-autogen-script
(lambda _
(substitute* "autogen.sh"
(("./configure") "sh configure"))))
--
2.16.1
From 2e683c9706f283703de7c7b437a48b093e836616 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 16:11:53 -0400
Subject: [PATCH 11/27] gnu: emacs-request: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-request)[propagated-inputs]: Add emacs-deferred.
---
gnu/packages/emacs.scm | 2 ++
1 file changed, 2 insertions(+)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 4c7bba5b2..377a04153 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -3337,6 +3337,8 @@ parallel.")
(base32
"0wyxqbb35yqf6ci47531lk32d6fppamx9d8826kdz983vm87him7"))))
(build-system emacs-build-system)
+ (propagated-inputs
+ `(("emacs-deferred" ,emacs-deferred)))
(home-page "https://github.com/tkf/emacs-request")
(synopsis "Package for speaking HTTP in Emacs Lisp")
(description "This package provides a HTTP request library with multiple
--
2.16.1
From ca084b686b198a8ba13176a66ffb8e6e0c6bd365 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Mon, 19 Mar 2018 21:13:33 -0400
Subject: [PATCH 12/27] gnu: emacs-idris-mode: Fix hash.
* gnu/packages/emacs.scm (emacs-idris-mode): Fix hash.
---
gnu/packages/emacs.scm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 377a04153..5c97a0f0c 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -6602,7 +6602,7 @@ key. Optionally, a mouse pop-up can be added by binding
version ".tar"))
(sha256
(base32
- "0ld4kfwnyyhlsnj5f6cbn4is4mpxdqalk2aifkw02r00mbr9n294"))))
+ "0qm4gngl6lqvra7kmivz99y3ymrg36nvqh5y9gy6gq0aa0v8az46"))))
(build-system emacs-build-system)
(propagated-inputs
`(("emacs-prop-menu" ,emacs-prop-menu)))
--
2.16.1
From b55edc3c6d17ad45062a551fdc9d26e927b0cf75 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Mon, 19 Mar 2018 21:28:42 -0400
Subject: [PATCH 13/27] gnu: emacs-sx: Fix build issue.
The package would fail building when attempting to create a cache
directory. This has been fixed upstream but not in a tagged release.
* gnu/packages/emacs.scm (emacs-sx): Update to latest git version.
---
gnu/packages/emacs.scm | 42 +++++++++++++++++++++++-------------------
1 file changed, 23 insertions(+), 19 deletions(-)
Toggle diff (56 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 5c97a0f0c..4f6b0f9cd 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1734,26 +1734,30 @@ strings.")
(license license:gpl2+)))
(define-public emacs-sx
- (package
- (name "emacs-sx")
- (version "0.4")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/vermiculus/sx.el/"
- "archive/v" version ".tar.gz"))
- (file-name (string-append name "-" version ".tar.gz"))
- (sha256
- (base32
- "1w0xghfljqg31axcnv8gzlrd8pw25nji6idnrhflq0af9qh1dw03"))))
- (build-system emacs-build-system)
- (propagated-inputs
- `(("emacs-markdown-mode" ,emacs-markdown-mode)))
- (home-page "https://github.com/vermiculus/sx.el/")
- (synopsis "Emacs StackExchange client")
- (description
- "Emacs StackExchange client. Ask and answer questions on
+ (let ((version "20180212")
+ (revision "1")
+ (commit "833435fbf90d1c9e927d165b155f3b1ef39271de"))
+ (package
+ (name "emacs-sx")
+ (version (git-version version revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/vermiculus/sx.el")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1369xaxq1vy3d9yh862ddnhddikdpg2d0wv1ly00pnvdp9v4cqgd"))))
+ (build-system emacs-build-system)
+ (propagated-inputs
+ `(("emacs-markdown-mode" ,emacs-markdown-mode)))
+ (home-page "https://github.com/vermiculus/sx.el")
+ (synopsis "Emacs StackExchange client")
+ (description
+ "Emacs StackExchange client. Ask and answer questions on
Stack Overflow, Super User, and other StackExchange sites.")
- (license license:gpl3+)))
+ (license license:gpl3+))))
(define-public emacs-f
(package
--
2.16.1
From fbc0f30c2df7857f3f853c5051ef6848dac32919 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Mon, 19 Mar 2018 21:55:27 -0400
Subject: [PATCH 14/27] gnu: emacs-polymode: Fix compilation error.
* gnu/packages/emacs.scm (emacs-polymode)
[add-modes-subdir-to-loadpath]: New phase.
---
gnu/packages/emacs.scm | 9 +++++++++
1 file changed, 9 insertions(+)
Toggle diff (22 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 4f6b0f9cd..cdd4904f7 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -6932,6 +6932,15 @@ contexts.
(base32
"057cybkq3cy07n5s332k071sjiky3mziy003lza4rh75mgqkwhmh"))))
(build-system emacs-build-system)
+ (arguments
+ `(#:include (cons* "^modes/.*\\.el$" %default-include)
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'set-emacs-load-path 'add-modes-subdir-to-load-path
+ (lambda _
+ (setenv "EMACSLOADPATH"
+ (string-append (getenv "EMACSLOADPATH")
+ ":" (getcwd) "/modes" ":")))))))
(home-page "https://github.com/vspinu/polymode")
(synopsis "Framework for multiple Emacs modes based on indirect buffers")
(description "Polymode is an Emacs package that offers generic support
--
2.16.1
From 172e42ae07cb5585d83403d3afc7c83c10d8c53f Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sun, 18 Mar 2018 16:37:30 -0400
Subject: [PATCH 15/27] gnu: Add emacs-scel.
* gnu/packages/emacs.scm (emacs-scel): New variable.
---
gnu/packages/emacs.scm | 53 ++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 53 insertions(+)
Toggle diff (66 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index cdd4904f7..420c0526b 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -2643,6 +2643,59 @@ implementation in Emacs. To use it just load this file and bind that function
to a key in your preferred mode.")
(license license:public-domain))))
+(define-public emacs-scel
+ (let ((version "20170629")
+ (revision "1")
+ (commit "aeea3ad4be9306d14c3a734a4ff54fee10ac135b"))
+ (package
+ (name "emacs-scel")
+ (version (git-version version revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/supercollider/scel.git")
+ (commit commit)))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "0jvmzs1lsjyndqshhii2y4mnr3wghai26i3p75453zrpxpg0zvvw"))))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'move-el-files
+ (lambda _
+ (for-each
+ (lambda (f)
+ (rename-file f (basename f)))
+ (find-files "el" "^.*\\.el(\\.in)?$"))
+ #t))
+ (add-after 'move-el-files 'configure-sclang-vars
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((supercollider (assoc-ref inputs "supercollider")))
+ (substitute* "sclang-vars.el.in"
+ (("@PKG_DATA_DIR@")
+ (string-append supercollider "/share/SuperCollider"))
+ ;; See: https://github.com/widp/el-supercollider/issues/1
+ (("Help") "HelpSource")))
+ (rename-file "sclang-vars.el.in" "sclang-vars.el")
+ #t))
+ (add-after 'configure-sclang-vars 'install-extensions
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (ext-dir (string-append
+ out "/share/SuperCollider/Extensions"
+ "/scide_scel")))
+ (delete-file "sc/CMakeLists.txt")
+ (copy-recursively "sc" ext-dir))
+ #t)))))
+ (inputs
+ `(("supercollider" ,supercollider)))
+ (home-page "https://github.com/supercollider/scel")
+ (synopsis "SuperCollider Emacs interface")
+ (description "scel is an Emacs based interface to SuperCollider.")
+ (license license:gpl2+))))
+
(define-public emacs-mit-scheme-doc
(package
(name "emacs-mit-scheme-doc")
--
2.16.1
From 086aa7bcec4cea5c5942f6b86772fa9ac71848c0 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 24 Mar 2018 21:37:41 -0400
Subject: [PATCH 16/27] gnu: Add emacs-kv.
* gnu/packages/emacs.scm (emacs-kv): New variable.
---
gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
Toggle diff (38 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 420c0526b..f8696d301 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -7245,6 +7245,31 @@ scratch buffer, and, by virtue of this extension, do so using the Emacs
formatting rules for that language.")
(license license:bsd-2))))
+(define-public emacs-kv
+ (package
+ (name "emacs-kv")
+ (version "0.0.19")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/nicferrier/emacs-kv.git")
+ (commit "721148475bce38a70e0b678ba8aa923652e8900e")))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "0r0lz2s6gvy04fwnafai668jsf4546h4k6zd6isx5wpk0n33pj5m"))))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:tests? #t
+ #:test-command '("ert-runner" "kv-tests.el")))
+ (native-inputs
+ `(("ert-runner" ,ert-runner)))
+ (home-page "https://github.com/nicferrier/emacs-kv")
+ (synopsis "Key/value data structures library")
+ (description "A collection of tools for dealing with key/value data
+structures such as plists, alists and hash-tables.")
+ (license license:gpl3+)))
+
(define-public emacs-esxml
(package
(name "emacs-esxml")
--
2.16.1
From 6f270606bf6505a845437db5a11cd6e2d636010a Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 24 Mar 2018 23:07:18 -0400
Subject: [PATCH 17/27] gnu: emacs-esxml: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-esxml): Add phases to patch sources.
---
gnu/packages/emacs.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
Toggle diff (39 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index f8696d301..999831c6a 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -7284,6 +7284,32 @@ structures such as plists, alists and hash-tables.")
(base32
"00vv8a75wdklygdyr4km9mc2ismxak69c45jmcny41xl44rp9x8m"))))
(build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ ;; See: https://github.com/tali713/esxml/pull/28.
+ (add-after 'unpack 'fix-css-lite.el
+ (lambda _
+ (substitute* "css-lite.el"
+ ((";;; main interface")
+ (string-append ";;; main interface\n"
+ "(require 'cl-lib)"))
+ (("mapcan")
+ "cl-mapcan")
+ (("',\\(cl-mapcan #'process-css-rule rules\\)")
+ "(cl-mapcan #'process-css-rule ',rules)"))
+ #t))
+ (add-after 'fix-css-lite.el 'fix-esxml-form.el
+ (lambda _
+ (substitute* "esxml-form.el"
+ ((",esxml-form-field-defn")
+ "#'esxml-form-field-defn"))))
+ ;; See: https://github.com/tali713/esxml/issues/25
+ (add-after 'fix-esxml-form.el 'rm-broken-test-file.el
+ (lambda _
+ (delete-file "esxpath.el"))))))
+ (propagated-inputs
+ `(("emacs-kv" ,emacs-kv)))
(home-page "https://github.com/tali713/esxml/")
(synopsis "SXML for EmacsLisp")
(description "This is XML/XHTML done with S-Expressions in EmacsLisp.
--
2.16.1
From b0d12ab881d3827862727f8dd3c5501bc93f3038 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Wed, 28 Mar 2018 20:56:18 -0400
Subject: [PATCH 18/27] gnu: emacs-mu4e-alert: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-mu4e-alert)[propagated-inputs]: Add mu.
---
gnu/packages/emacs.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Toggle diff (24 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 999831c6a..3eb64e4ae 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -89,6 +89,7 @@
#:use-module (gnu packages xml)
#:use-module (gnu packages glib)
#:use-module (gnu packages acl)
+ #:use-module (gnu packages mail)
#:use-module (gnu packages package-management)
#:use-module (gnu packages perl)
#:use-module (gnu packages pdf)
@@ -5023,7 +5024,8 @@ customizable by the user.")
"07qc834qnxn8xi4bw5nawj8g91bmkzw0r0vahkgysp7r9xrf57gj"))))
(build-system emacs-build-system)
(propagated-inputs
- `(("emacs-alert" ,emacs-alert)
+ `(("mu" ,mu) ;for byte compilation
+ ("emacs-alert" ,emacs-alert)
("emacs-s" ,emacs-s)
("emacs-ht" ,emacs-ht)))
(home-page "https://github.com/iqbalansari/mu4e-alert")
--
2.16.1
From 9a3a449121246a2d26a92ee5c19d905768789a10 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Wed, 28 Mar 2018 21:50:15 -0400
Subject: [PATCH 19/27] gnu: emacs-org-contrib: Fix hash and byte compilation.
* gnu/packages/emacs.scm (emacs-org-contrib)[native-inputs]: Add emacs-scel.
---
gnu/packages/emacs.scm | 2 ++
1 file changed, 2 insertions(+)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 3eb64e4ae..a79d15d33 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -4638,6 +4638,8 @@ reproducible research.")
out "/share/emacs/site-lisp/guix.d/org-contrib-" ,version)
(for-each delete-file duplicates))
#t))))))
+ (native-inputs
+ `(("emacs-scel" ,emacs-scel))) ;for byte compilation
(propagated-inputs
`(("emacs-org" ,emacs-org)))
(synopsis "Contributed packages to Org mode")
--
2.16.1
From 9b5c7216ecb00e433a22687d6a54eba2f20ac0eb Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 20:41:48 -0400
Subject: [PATCH 20/27] gnu: emacs-evil-matchit: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-evil-matchit)[propagated-inputs]: Add
emacs-evil.
---
gnu/packages/emacs.scm | 2 ++
1 file changed, 2 insertions(+)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index a79d15d33..afa57e65c 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -7080,6 +7080,8 @@ Feautures:
(base32
"1hm0k53m7d8zv2pk4p93k5mmilsv1mz7y2z6dqf7r6f0zmncs31a"))))
(build-system emacs-build-system)
+ (propagated-inputs
+ `(("evil" ,emacs-evil)))
(home-page "https://github.com/redguardtoo/evil-matchit")
(synopsis "Vim matchit ported into Emacs")
(description
--
2.16.1
From f6642cee6419a1e720070673767b7a30e3d132bb Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 21:18:16 -0400
Subject: [PATCH 21/27] gnu: Add emacs-spark.
* gnu/packages/emacs.scm (emacs-spark): New variable.
---
gnu/packages/emacs.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
Toggle diff (36 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index afa57e65c..b8601f868 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1907,6 +1907,29 @@ Expectations, but it can be used in other contexts.")
definitions for testing with the Ecukes framework.")
(license license:gpl3+)))
+(define-public emacs-spark
+ (let ((version "20160503") ;no proper tag, use date of commit
+ (commit "0bf148c3ede3b31d56fd75f347cdd0b0eae60025")
+ (revision "1"))
+ (package
+ (name "emacs-spark")
+ (version (git-version version revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/alvinfrancis/spark.git")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1ykqr86j17mi95s08d9fp02d7ych1331b04dcqxzxnmpkhwngyj1"))))
+ (build-system emacs-build-system)
+ (home-page "https://github.com/alvinfrancis/spark")
+ (synopsis "Port of cl-spark to Emacs Lisp")
+ (description "This library is a straightforward port of @code{cl-spark}
+to Emacs Lisp.")
+ (license license:expat))))
+
(define-public emacs-es-mode
(package
(name "emacs-es-mode")
--
2.16.1
From 09b506e8ac6a948a7e788f7e621ea3805e497a3e Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 21:18:36 -0400
Subject: [PATCH 22/27] gnu: emacs-es-mode: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-es-mode)[propagated-inputs]: Add emacs-dash
and emacs-spark.
---
gnu/packages/emacs.scm | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Toggle diff (17 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index b8601f868..1362aed31 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1947,7 +1947,9 @@ to Emacs Lisp.")
(propagated-inputs
;; The version of org in Emacs 24.5 is not sufficient, and causes tables
;; to be rendered incorrectly
- `(("emacs-org" ,emacs-org)))
+ `(("emacs-org" ,emacs-org)
+ ("emacs-dash" ,emacs-dash)
+ ("emacs-spark" ,emacs-spark)))
(home-page "https://github.com/dakrone/es-mode")
(synopsis "Major mode for editing Elasticsearch queries")
(description "@code{es-mode} includes highlighting, completion and
--
2.16.1
From af77425293a4fba3cc5c5742c69d531507a8becb Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 21:46:35 -0400
Subject: [PATCH 23/27] gnu: Add emacs-eimp.
* gnu/packages/emacs.scm (emacs-eimp): New variable.
---
gnu/packages/emacs.scm | 38 ++++++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)
Toggle diff (51 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 1362aed31..6bffd10ed 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -6374,6 +6374,44 @@ from within Emacs. Restclient runs queries from a plan-text query sheet,
displays results pretty-printed in XML or JSON with @code{restclient-mode}")
(license license:public-domain))))
+(define-public emacs-eimp
+ (let ((version "1.4.0")
+ (commit "2e7536fe6d8f7faf1bad7a8ae37faba0162c3b4f")
+ (revision "1"))
+ (package
+ (name "emacs-eimp")
+ (version (git-version version revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/nicferrier/eimp.git")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "154d57yafxbcf39r89n5j43c86rp2fki3lw3gwy7ww2g6qkclcra"))))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-mogrify-path
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((imagemagick (assoc-ref inputs "imagemagick")))
+ ;; eimp.el is read-only in git.
+ (invoke "chmod" "+w" "eimp.el")
+ (emacs-substitute-variables "eimp.el"
+ ("eimp-mogrify-program"
+ (string-append imagemagick "/bin/mogrify"))))
+ #t)))))
+ (inputs
+ `(("imagemagick" ,imagemagick))) ;provides the mogrify binary.
+ (home-page "https://github.com/nicferrier/eimp")
+ (synopsis "Interactive image manipulation from within Emacs")
+ (description "This package allows interactive image manipulation from
+within Emacs. It uses the code@{mogrify} utility from ImageMagick to do the
+actual transformations.")
+ (license license:gpl2+))))
+
(define-public emacs-dired-hacks
(let ((commit "eda68006ce73bbf6b9b995bfd70d08bec8cade36")
(revision "1"))
--
2.16.1
From 95cf21463f6ec9141df70aec5403851afdda0e82 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 22:56:29 -0400
Subject: [PATCH 24/27] gnu: emacs-dired-hacks: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-dired-hacks)[propagated-inputs]: Add emacs-eimp.
---
gnu/packages/emacs.scm | 1 +
1 file changed, 1 insertion(+)
Toggle diff (14 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 6bffd10ed..0332e7e9e 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -6431,6 +6431,7 @@ actual transformations.")
(build-system emacs-build-system)
(propagated-inputs
`(("emacs-dash" ,emacs-dash)
+ ("emacs-eimp" ,emacs-eimp)
("emacs-f" ,emacs-f)
("emacs-s" ,emacs-s)))
(home-page "https://github.com/Fuco1/dired-hacks")
--
2.16.1
From 0b3fb16665fe7b2ca4818496857af1426eb766e9 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Fri, 30 Mar 2018 23:16:10 -0400
Subject: [PATCH 25/27] gnu: emacs-cdlatex: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-cdlatex)[propagated-inputs]: Add emacs-auctex.
---
gnu/packages/emacs.scm | 2 ++
1 file changed, 2 insertions(+)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 0332e7e9e..c7e53333a 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -5614,6 +5614,8 @@ conversion for Emacs Lisp.")
(base32
"0pivapphmykc6vhvpx7hdyl55ls37vc4jcrxpvs4yk7jzcmwa9xp"))))
(build-system emacs-build-system)
+ (propagated-inputs
+ `(("emacs-auctex" ,emacs-auctex)))
(home-page "https://github.com/cdominik/cdlatex")
(synopsis "Fast Emacs input methods for LaTeX environments and
math")
--
2.16.1
From c303e1b7a0b0e96bc49521973c4d2187c25f8af1 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 00:22:24 -0400
Subject: [PATCH 26/27] gnu: Add emacs-howm.
* gnu/packages/emacs.scm (emacs-howm): New variable.
---
gnu/packages/emacs.scm | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
Toggle diff (32 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index c7e53333a..803994308 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1182,6 +1182,25 @@ or XEmacs.")
a set of simplified face specifications and a user-supplied color palette")
(license license:gpl3+)))
+(define-public emacs-howm
+ (package
+ (name "emacs-howm")
+ (version "1.4.4")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "http://howm.sourceforge.jp/a/howm-"
+ version ".tar.gz"))
+ (sha256
+ (base32
+ "0ddm91l6z58j7x59fa966j6q1rg4cinyza4r8ibg80hprn5h31qk"))))
+ (build-system emacs-build-system)
+ (home-page "http://howm.osdn.jp/")
+ (synopsis "Note-taking tool for Emacs")
+ (description "Howm is a note-taking tool for Emacs. Like with
+code@{emacs-wiki.el}, it facilitates using hyperlinks and doing full-text
+searches. Unlike code@{emacs-wiki.el}, it can be combined with any format.")
+ (license license:gpl1+)))
+
(define-public emacs-calfw
(package
(name "emacs-calfw")
--
2.16.1
From 915b8088ecd2d1367b0844ed0eacd249e87aec76 Mon Sep 17 00:00:00 2001
From: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Date: Sat, 31 Mar 2018 00:25:23 -0400
Subject: [PATCH 27/27] gnu: emacs-calfw: Fix byte compilation.
* gnu/packages/emacs.scm (emacs-calfw)[propagated-inputs]: Add emacs-howm.
---
gnu/packages/emacs.scm | 2 ++
1 file changed, 2 insertions(+)
Toggle diff (15 lines)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 803994308..ccd997d91 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -1216,6 +1216,8 @@ searches. Unlike code@{emacs-wiki.el}, it can be combined with any format.")
(base32
"17ssg8gx66yp63nhygjq2r6kgl4h45cacmrxsxs9f0lrfcx37k0l"))))
(build-system emacs-build-system)
+ (propagated-inputs
+ `(("emacs-howm" ,emacs-howm)))
(home-page "https://github.com/kiwanami/emacs-calfw/")
(synopsis "Calendar framework for Emacs")
(description
--
2.16.1