emacsPackagesNg: 2018-07-15 update

All package sets are simultaneously updated to accommodate changes to
package-build. Due to new restrictions in package-build, all packages using
`melpaBuild` must now provide a recipe file, even those packages which are not
included in upstream MELPA.
This commit is contained in:
Thomas Tuegel 2018-07-15 20:52:41 -05:00
parent dae9cf6106
commit d3cea48608
No known key found for this signature in database
GPG key ID: 22CBF5249D4B4D59
14 changed files with 58051 additions and 28201 deletions

File diff suppressed because it is too large Load diff

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "filesets+.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/filesets-plus+";
sha256 = "1wn99cb53ykds87lg9mrlfpalrmjj177nwskrnp9wglyqs65lk4g";
name = "filesets-plus";

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "font-lock+.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/font-lock+";
sha256 = "1wn99cb53ykds87lg9mrlfpalrmjj177nwskrnp9wglyqs65lk4g";
name = "font-lock-plus";

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "header2.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/header2";
sha256 = "1dg25krx3wxma2l5vb2ji7rpfp17qbrl62jyjpa52cjfsvyp6v06";
name = "header2";

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "hexrgb.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/hexrgb";
sha256 = "0mzqslrrf7sc262syj3ja7b7rnbg80dwf2p9bzxdrzx6b8vvsx06";
name = "hexrgb";

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "lib-requires.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/lib-requires";
sha256 = "1g22jh56z8rnq0h80wj10gs38yig1rk9xmk3kmhmm5mm6b14iwdx";
name = "lib-requires";

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,10 +1,12 @@
{ callPackage }: {
org = callPackage ({ elpaBuild, fetchurl, lib }: elpaBuild {
{ callPackage }:
{
org = callPackage ({ elpaBuild, fetchurl, lib }:
elpaBuild {
pname = "org";
version = "20180416";
version = "20180716";
src = fetchurl {
url = "https://orgmode.org/elpa/org-20180416.tar";
sha256 = "05rbkrs93zd9kvldwvypb8fwwaysajy5n7b2k9c8xm2cx2nayv8m";
url = "http://orgmode.org/elpa/org-20180716.tar";
sha256 = "0gr57nfdncnxrxxzw87ni5i6zjh1mdxl9h8pw96msh1c47xhpk2d";
};
packageRequires = [];
meta = {
@ -12,12 +14,13 @@
license = lib.licenses.free;
};
}) {};
org-plus-contrib = callPackage ({ elpaBuild, fetchurl, lib }: elpaBuild {
org-plus-contrib = callPackage ({ elpaBuild, fetchurl, lib }:
elpaBuild {
pname = "org-plus-contrib";
version = "20180416";
version = "20180716";
src = fetchurl {
url = "https://orgmode.org/elpa/org-plus-contrib-20180416.tar";
sha256 = "1f5zdfsa1fcf66hk3w57wh5385069yg0b86h57jgkcbmxkcmj6ij";
url = "http://orgmode.org/elpa/org-plus-contrib-20180716.tar";
sha256 = "0j4r3bcy96kcaab7cv2a5qd0mv8ddkr1qlihijk79l9nhsh2y4hm";
};
packageRequires = [];
meta = {

View file

@ -10,7 +10,7 @@ melpaBuild {
name = "thingatpt+.el";
};
recipeFile = fetchurl {
recipe = fetchurl {
url = "https://raw.githubusercontent.com/milkypostman/melpa/a5d15f875b0080b12ce45cf696c581f6bbf061ba/recipes/thingatpt+";
sha256 = "0w031lzjl5phvzsmbbxn2fpziwkmdyxsn08h6b9lxbss1prhx7aa";
name = "thingatpt-plus";

View file

@ -1,35 +1,19 @@
# builder for Emacs packages built for packages.el
# using MELPA package-build.el
{ lib, stdenv, fetchurl, emacs, texinfo }:
{ lib, stdenv, fetchurl, fetchFromGitHub, emacs, texinfo }:
with lib;
{ pname
, version
, recipeFile ? null
, files ? null
, fileSpecs ? [ "*.el" "*.el.in" "dir"
"*.info" "*.texi" "*.texinfo"
"doc/dir" "doc/*.info" "doc/*.texi" "doc/*.texinfo"
]
, recipe
, meta ? {}
, ...
}@args:
let
packageBuild = fetchurl {
url = https://raw.githubusercontent.com/milkypostman/melpa/2b3eb31c077fcaff94b74b757c1ce17650333943/package-build.el;
sha256 = "1biwg2pqmmdz5iwqbjdszljazqymvgyyjcnc255nr6qz8mhnx67j";
};
targets = concatStringsSep " " (if files == null then fileSpecs else files);
defaultMeta = {
homepage = args.src.meta.homepage or "http://melpa.org/#/${pname}";
};
@ -37,33 +21,58 @@ let
in
import ./generic.nix { inherit lib stdenv emacs texinfo; } ({
inherit packageBuild;
melpa = fetchFromGitHub {
owner = "melpa";
repo = "melpa";
rev = "7103313a7c31bb1ebb71419e365cd2e279ee4609";
sha256 = "0m10f83ix0mzjk0vjd4kkb1m1p4b8ha0ll2yjsgk9bqjd7fwapqb";
};
elpa2nix = ./elpa2nix.el;
melpa2nix = ./melpa2nix.el;
preUnpack = ''
mkdir -p "$NIX_BUILD_TOP/recipes"
if [ -n "$recipe" ]; then
cp "$recipe" "$NIX_BUILD_TOP/recipes/$pname"
fi
ln -s "$melpa/package-build" "$NIX_BUILD_TOP/package-build"
mkdir -p "$NIX_BUILD_TOP/packages"
'';
postUnpack = ''
mkdir -p "$NIX_BUILD_TOP/working"
ln -s "$NIX_BUILD_TOP/$sourceRoot" "$NIX_BUILD_TOP/working/$pname"
'';
buildPhase =
if recipeFile == null
then ''
runHook preBuild
''
runHook preBuild
export archive=$(emacs --batch -Q -l $packageBuild -l ${./melpa2nix.el} \
-f melpa2nix-build-package \
${pname} ${version} ${targets})
cd "$NIX_BUILD_TOP"
runHook postBuild
''
else ''
runHook preBuild
emacs --batch -Q \
-L "$melpa/package-build" \
-l "$melpa2nix" \
-f melpa2nix-build-package \
$pname $version
export archive=$(emacs --batch -Q -l $packageBuild -l ${./melpa2nix.el} \
-f melpa2nix-build-package-from-recipe \
${recipeFile} ${version})
runHook postBuild
'';
runHook postBuild
'';
installPhase = ''
runHook preInstall
emacs --batch -Q -l ${./elpa2nix.el} \
archive="$NIX_BUILD_TOP/packages/$pname-$version.el"
if [ ! -f "$archive" ]; then
archive="$NIX_BUILD_TOP/packages/$pname-$version.tar"
fi
emacs --batch -Q \
-l "$elpa2nix" \
-f elpa2nix-install-package \
"$archive" "$out/share/emacs/site-lisp/elpa"
@ -73,6 +82,4 @@ import ./generic.nix { inherit lib stdenv emacs texinfo; } ({
meta = defaultMeta // meta;
}
// removeAttrs args [ "files" "fileSpecs"
"meta"
])
// removeAttrs args [ "meta" ])

View file

@ -1,42 +1,16 @@
(require 'package)
(package-initialize)
(require 'package-recipe)
(require 'package-build)
(setq package-build-working-dir (expand-file-name ".")
package-build-archive-dir (expand-file-name "."))
(setq package-build-working-dir (expand-file-name "working/"))
(setq package-build-archive-dir (expand-file-name "packages/"))
(setq package-build-recipes-dir (expand-file-name "recipes/"))
(defun melpa2nix-build-package ()
(if (not noninteractive)
(error "`melpa2nix-build-package' is to be used only with -batch"))
(pcase command-line-args-left
(`(,package ,version . ,files)
(melpa2nix-package-build-archive package version files))))
(defun melpa2nix-build-package-from-recipe ()
(if (not noninteractive)
(error "`melpa2nix-build-package' is to be used only with -batch"))
(pcase command-line-args-left
(`(,recipe-file ,version)
(let* ((recipe (package-build--read-from-file recipe-file))
(rcp (cdr recipe))
(package (car recipe))
(files (package-build--config-file-list rcp)))
(melpa2nix-package-build-archive package version files)))))
(defun melpa2nix-package-build-archive (name version files)
"Build a package archive for package NAME."
(package-build--message "\n;;; %s\n" name)
(let* ((start-time (current-time))
(archive-entry (package-build-package name
version
files
package-build-working-dir
package-build-archive-dir))
(archive-file (package-build--archive-file-name archive-entry)))
(progn
(package-build--message "Built in %.3fs, finished at %s"
(time-to-seconds (time-since start-time))
(current-time-string))
(princ (format "%s\n" archive-file)))))
(`(,package ,version)
(package-build--package (package-recipe-lookup package) version))))

View file

@ -15891,7 +15891,7 @@ with pkgs;
emacsPackagesNgGen = emacs: import ./emacs-packages.nix {
inherit lib newScope stdenv;
inherit fetchFromGitHub fetchgit fetchhg fetchurl fetchpatch;
inherit emacs texinfo makeWrapper runCommand;
inherit emacs texinfo makeWrapper runCommand writeText;
inherit (xorg) lndir;
trivialBuild = callPackage ../build-support/emacs/trivial.nix {

View file

@ -32,7 +32,7 @@
# `meta` with `platforms` and `homepage` set to something you are
# unlikely to want to override for most packages
{ lib, newScope, stdenv, fetchurl, fetchgit, fetchFromGitHub, fetchhg, fetchpatch, runCommand
{ lib, newScope, stdenv, fetchurl, fetchgit, fetchFromGitHub, fetchhg, fetchpatch, runCommand, writeText
, emacs, texinfo, lndir, makeWrapper
, trivialBuild
@ -99,7 +99,11 @@ let
nativeBuildInputs = [ external.pkgconfig ];
buildInputs = with external; [ autoconf automake libpng zlib poppler ];
preBuild = "make server/epdfinfo";
fileSpecs = [ "lisp/pdf-*.el" "server/epdfinfo" ];
recipe = writeText "recipe" ''
(pdf-tools
:repo "politza/pdf-tools" :fetcher github
:files ("lisp/pdf-*.el" "server/epdfinfo"))
'';
packageRequires = [ tablist let-alist ];
meta = {
description = "Emacs support library for PDF files";
@ -118,7 +122,12 @@ let
};
buildInputs = [ external.libffi ];
preBuild = "make";
files = [ "ffi-glue" "ffi.el" ];
recipe = writeText "recipe" ''
(elisp-ffi
:repo "skeeto/elisp-ffi"
:fetcher github
:files ("ffi-glue" "ffi.el"))
'';
meta = {
description = "Emacs Lisp Foreign Function Interface";
longDescription = ''
@ -163,6 +172,9 @@ let
rev = "39ea47c73f040ce8dcc1c2d2639ebc0eb57ab8c8";
sha256 = "0q3av1qv4m6aj4bil608f688hjpr5px8zqnnrdqx784nz98rpjrs";
};
recipe = writeText "recipe" ''
(elpy :repo "jorgenschaefer/elpy" :fetcher github)
'';
patchPhase = ''
for file in elpy.el elpy-pkg.el; do
@ -203,6 +215,9 @@ let
rev = "fcadf2d93aaea3ba88a2ae63a860b9c1f0568167";
sha256 = "0axx6cc9z9c1wh7qgm6ya54dsp3bn82bnb0cwj1rpv509qqmwgsj";
};
recipe = writeText "recipe" ''
(evil-jumper :repo "bling/evil-jumper" :fetcher github)
'';
packageRequires = [ evil ];
meta = {
description = "Jump across buffer boundaries and revive dead buffers if necessary";
@ -222,6 +237,11 @@ let
rev = "53a8d8174f915d9dcf5ac6954b1c0cae61266177";
sha256 = "0wky8vqg08iw34prbz04bqmhfhj82y93swb8zkz6la2vf9da0gmd";
};
recipe = writeText "recipe" ''
(find-file-in-project
:repo "technomancy/find-file-in-project"
:fetcher github)
'';
meta = {
description = "Quick access to project files in Emacs";
longDescription = ''
@ -243,6 +263,9 @@ let
src = external.ghc-mod.src;
packageRequires = [ haskell-mode ];
propagatedUserEnvPkgs = [ external.ghc-mod ];
recipe = writeText "recipe" ''
(ghc-mod :repo "DanielG/ghc-mod" :fetcher github :files ("elisp/*.el"))
'';
fileSpecs = [ "elisp/*.el" ];
meta = {
description = "An extension of haskell-mode that provides completion of symbols and documentation browsing";
@ -259,6 +282,11 @@ let
rev = "d8d168148c187ed19350bb7a1a190217c2915a63";
sha256 = "09b7bg2s9aa4s8f2kdqs4xps3jxkq5wsvbi87ih8b6id38blhf78";
};
recipe = writeText "recipe" ''
(haskell-unicode-input-method
:repo "roelvandijk/emacs-haskell-unicode-input-method"
:fetcher github)
'';
packageRequires = [];
meta = {
homepage = "https://melpa.org/#haskell-unicode-input-method/";
@ -278,7 +306,11 @@ let
src = external.hindent.src;
packageRequires = [ haskell-mode ];
propagatedUserEnvPkgs = [ external.hindent ];
fileSpecs = [ "elisp/*.el" ];
recipe = writeText "recipe" ''
(hindent
:repo "commercialhaskell/hindent" :fetcher github
:files ("elisp/*.el"))
'';
meta = {
description = "Indent haskell code using the \"hindent\" program";
license = bsd3;
@ -297,7 +329,11 @@ let
configurePhase = ":";
propagatedUserEnvPkgs = [ external.rtags ];
fileSpecs = [ "src/*.el" ];
recipe = writeText "recipe" ''
(rtags
:repo "andersbakken/rtags" :fetcher github
:files ("src/*.el"))
'';
inherit (external.rtags) meta;
};
@ -305,7 +341,9 @@ let
pname = "lcs";
version = circe.version;
src = circe.src;
fileSpecs = [ "lcs.el" ];
recipe = writeText "recipe" ''
(lcs :repo "jorgenschaefer/circe" :fetcher github :files ("lcs.el"))
'';
meta = {
description = "Longest Common Sequence (LCS) library for Emacs";
license = gpl3Plus;
@ -320,7 +358,9 @@ let
version = circe.version;
src = circe.src;
packageRequires = [ tracking ];
fileSpecs = [ "lui*.el" ];
recipe = writeText "recipe" ''
(lcs :repo "jorgenschaefer/circe" :fetcher github :files ("lui*.el"))
'';
meta = {
description = "User interface library for Emacs";
license = gpl3Plus;
@ -345,7 +385,9 @@ let
pname = "shorten";
version = circe.version;
src = circe.src;
fileSpecs = [ "shorten.el" ];
recipe = writeText "recipe" ''
(shorten :repo "jorgenschaefer/circe" :fetcher github :files ("shorten.el"))
'';
meta = {
description = "String shortening to unique prefix library for Emacs";
license = gpl3Plus;
@ -354,20 +396,10 @@ let
stgit = callPackage ../applications/editors/emacs-modes/stgit { };
structured-haskell-mode = melpaBuild rec {
pname = "shm";
version = external.structured-haskell-mode.version;
src = external.structured-haskell-mode.src;
packageRequires = [ haskell-mode ];
fileSpecs = [ "elisp/*.el" ];
structured-haskell-mode = self.shm;
shm = (melpaPackages self).shm.overrideAttrs (attrs: {
propagatedUserEnvPkgs = [ external.structured-haskell-mode ];
meta = {
description = "Structured editing Emacs mode for Haskell";
license = bsd3;
platforms = external.structured-haskell-mode.meta.platforms;
};
};
});
thingatpt-plus = callPackage ../applications/editors/emacs-modes/thingatpt-plus { };
@ -386,6 +418,9 @@ let
rm weechat-sauron.el weechat-secrets.el
'';
packageRequires = [ s ];
recipe = writeText "recipe" ''
(weechat :repo "the-kenny/weechat" :fetcher github)
'';
meta = {
description = "A weechat IRC client frontend for Emacs";
license = gpl3Plus;