5016fdb269
Previously, meta wasn't being passed through at all, because it's removed from args without being used anywhere. This made it so that rcirc-menu wasn't being marked as broken even though it was supposed to be. This patch copies the meta handling from melpaBuild, including the default home page (adapted for ELPA).
41 lines
716 B
Nix
41 lines
716 B
Nix
# builder for Emacs packages built for packages.el
|
|
|
|
{ lib, stdenv, emacs, texinfo }:
|
|
|
|
with lib;
|
|
|
|
{ pname
|
|
, version
|
|
, src
|
|
, meta ? {}
|
|
, ...
|
|
}@args:
|
|
|
|
let
|
|
|
|
defaultMeta = {
|
|
homepage = args.src.meta.homepage or "https://elpa.gnu.org/packages/${pname}.html";
|
|
};
|
|
|
|
in
|
|
|
|
import ./generic.nix { inherit lib stdenv emacs texinfo; } ({
|
|
|
|
phases = "installPhase fixupPhase distPhase";
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
emacs --batch -Q -l ${./elpa2nix.el} \
|
|
-f elpa2nix-install-package \
|
|
"${src}" "$out/share/emacs/site-lisp/elpa"
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = defaultMeta // meta;
|
|
}
|
|
|
|
// removeAttrs args [ "files" "fileSpecs"
|
|
"meta"
|
|
])
|