Commit Graph

12 Commits

Author SHA1 Message Date
Maxim Cournoyer afc6b1c0b6
build: emacs-utils: Add an option to select scoping for batch eval.
In Emacs 27, --eval now evaluates using lexical scoping.  This change adds an
option to select dynamic scoping, by using a workaround proposed in
<https://bugs.gnu.org/39823>.

* guix/build/emacs-utils.scm (emacs-batch-eval): Add a DYNAMIC? keyword
argument.  Wrap the EXPR with a call to EVAL that makes use of the argument
to select the scoping mode.
(emacs-generate-autoloads): Use it.
2020-03-22 21:17:38 -04:00
Maxim Cournoyer 9659459f06
emacs-build-system: Byte compile the autoload files.
* guix/build/emacs-build-system.scm (enable-autoloads-compilation)
(validate-compiled-autoloads): Add procedures.
(%standard-phases): Register the new procedures.
* gnu/packages/aux-files/emacs/guix-emacs.el (guix-emacs-find-autoloads):
Remove duplicates in the list of autoload files found.
* guix/build/emacs-utils.scm (expr->string): Add procedure.
(emacs-batch-eval, emacs-batch-edit-file): Use it.
2020-02-27 16:59:07 -05:00
Leo Prikler 9ce3f7f6dc
guix: emacs-utils: Add emacs-batch-disable-compilation.
* guix/build/emacs-utils.scm (emacs-batch-disable-compilation):
New procedure.

Signed-off-by: Brett Gilio <brettg@gnu.org>
2019-12-27 16:54:52 -06:00
Marius Bakke 12bd588346
Merge branch 'master' into core-updates 2018-05-06 15:56:24 +02:00
Maxim Cournoyer c1b4ad2e6e
build: emacs-utils: Fail when byte compilation fails.
Byte compilation failures were ignored prior to this change.

* guix/build/emacs-utils.scm (emacs-byte-compile-directory): Fail when there
are compilation errors.

Signed-off-by: Arun Isaac <arunisaac@systemreboot.net>
2018-05-03 21:48:59 +05:30
Mark H Weaver c52872bfc4
Merge branch 'master' into core-updates 2018-04-21 05:02:52 -04:00
Maxim Cournoyer 8a8fa82e72
build-system: emacs: Replace system* with invoke.
* guix/build/emacs-utils.scm: Use (guix build utils) for invoke.
(emacs-batch-eval, emacs-batch-edit-file): Replace system* with invoke.
* guix/build/emacs-build-system.scm (make-autoloads): No need to return #t
explicitly since emacs-generate-autoloads now uses invoke.

Signed-off-by: Arun Isaac <arunisaac@systemreboot.net>
2018-04-20 00:49:53 +05:30
Mark H Weaver 7837450076
build: emacs-utils: Use invoke instead of system*.
* guix/build/emacs-utils.scm (emacs-batch-eval)
(emacs-batch-edit-file): Use invoke.
2018-03-16 05:02:38 -04:00
Maxim Cournoyer b7dee6a0b8
emacs-build-system: Add set-emacs-load-path phase.
This generalizes the mechanism by which the Emacs dependencies are made visible,
so that any build phase can make use of them.

* guix/build/emacs-build-system.scm (%legacy-install-suffix): New variable.
(%install-suffix): Redefine in terms of %legacy-install-suffix.
(set-emacs-load-path): Add new phase used for dependency resolution.
(build): Remove ad-hoc dependency discovery mechanism.
(emacs-input->el-directory): Add new procedure.
(emacs-inputs-el-directories): Use it.
(package-name-version->elpa-name-version): Fix typo.
(%standard-phases): Include the new `set-emacs-load-path' phase. Refactor to
make the ordering of the phases clearer.
* guix/build/emacs-utils.scm (emacs-byte-compile-directory): Remove the
optional `dependency-dirs' argument, which is now obsoleted by the
`set-emacs-load-path' phase.

Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2018-02-05 16:54:27 +01:00
Federico Beffa 1d44b4e544 build: emacs-utils: Add 'emacs-byte-compile-directory'.
* guix/build/emacs-utils.scm (emacs-byte-compile-directory): New procedure.
2015-07-08 10:53:05 +02:00
Alex Kost 0b08600ca5 build: emacs-utils: Add 'emacs-generate-autoloads'.
* guix/build/emacs-utils.scm (emacs-generate-autoloads): New procedure.
2014-12-02 22:09:23 +03:00
Mark H Weaver 75f3b1a12d Add (guix build emacs-utils).
* guix/build/emacs-utils.scm: New file.
* Makefile.am (MODULES): Add it.
* .dir-locals.el: Add indentation rules.
2014-08-14 23:53:04 -04:00