diff options
author | Thomas Tuegel <ttuegel@gmail.com> | 2015-12-16 20:53:12 -0600 |
---|---|---|
committer | Thomas Tuegel <ttuegel@gmail.com> | 2015-12-19 09:31:41 -0600 |
commit | dadfd93811c9ddef93024f164edef636bdd48481 (patch) | |
tree | e9b3317d631d026ce66519975986d9a8820b0fbb /pkgs/build-support/emacs/wrapper.nix | |
parent | 78d68b8c149d7c7a2f6f48d25ae61e5ec66212d7 (diff) | |
download | nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar.gz nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar.bz2 nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar.lz nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar.xz nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.tar.zst nixpkgs-dadfd93811c9ddef93024f164edef636bdd48481.zip |
emacsWithPackages: know its own package set
Fixes #10819. emacsWithPackages will know its own package set. This requires it to be in a package set, rather than at the top level, so it lives in emacsPackagesNg.
Diffstat (limited to 'pkgs/build-support/emacs/wrapper.nix')
-rw-r--r-- | pkgs/build-support/emacs/wrapper.nix | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/pkgs/build-support/emacs/wrapper.nix b/pkgs/build-support/emacs/wrapper.nix index 4020a1aca33..8de13dc0c64 100644 --- a/pkgs/build-support/emacs/wrapper.nix +++ b/pkgs/build-support/emacs/wrapper.nix @@ -1,8 +1,15 @@ -{ stdenv, makeWrapper, emacs }: +{ lib, makeWrapper, stdenv }: self: -with stdenv.lib; +with lib; let inherit (self) emacs; in -explicitRequires: # packages explicitly requested by the user +packagesFun: # packages explicitly requested by the user + +let + explicitRequires = + if builtins.isFunction packagesFun + then packagesFun self + else packagesFun; +in stdenv.mkDerivation { name = (appendToName "with-packages" emacs).name; |