summary refs log tree commit diff
path: root/pkgs/build-support/emacs/trivial.nix
blob: 396c971b2f016e5d78a943f885ed7e6dce4c5144 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# trivial builder for Emacs packages

{ lib, stdenv, texinfo, ... }@envargs:

with lib;

args:

import ./generic.nix envargs ({
  buildPhase = ''
    runHook preBuild

    emacs -L . --batch -f batch-byte-compile *.el

    runHook postBuild
  '';

  installPhase = ''
    runHook preInstall

    LISPDIR=$out/share/emacs/site-lisp
    install -d $LISPDIR
    install *.el *.elc $LISPDIR

    runHook postInstall
  '';
}

// args)