diff options
Diffstat (limited to 'overlays/patches/emacs/overlay/default.nix')
-rw-r--r-- | overlays/patches/emacs/overlay/default.nix | 56 |
1 files changed, 26 insertions, 30 deletions
diff --git a/overlays/patches/emacs/overlay/default.nix b/overlays/patches/emacs/overlay/default.nix index 1f3c36ae1013..6f6c2c317d10 100644 --- a/overlays/patches/emacs/overlay/default.nix +++ b/overlays/patches/emacs/overlay/default.nix @@ -37,7 +37,7 @@ let in builtins.foldl' (drv: fn: fn drv) - self.emacs + super.emacs [ (drv: drv.override ({ srcRepo = true; } // args)) @@ -49,9 +49,8 @@ let inherit (repoMeta) version; src = fetcher (builtins.removeAttrs repoMeta [ "type" "version" ]); - patches = [ - ./patches/tramp-detect-wrapped-gvfsd.patch - ]; + patches = [ ]; + postPatch = old.postPatch + '' substituteInPlace lisp/loadup.el \ --replace '(emacs-repository-get-version)' '"${repoMeta.rev}"' \ @@ -62,21 +61,17 @@ let ) ) - # --with-nativecomp was changed to --with-native-compilation - # Remove this once 21.05 is released - (drv: if drv.passthru.nativeComp && self.lib.elem "--with-nativecomp" drv.configureFlags then drv.overrideAttrs(old: { - configureFlags = builtins.map (flag: if flag == "--with-nativecomp" then "--with-native-compilation" else flag) old.configureFlags; - }) else drv) - # reconnect pkgs to the built emacs ( - drv: let + drv: + let result = drv.overrideAttrs (old: { passthru = old.passthru // { pkgs = self.emacsPackagesFor result; }; }); - in result + in + result ) ]; @@ -87,33 +82,34 @@ let } ); - emacsGit = mkGitEmacs "emacs-git" ./repos/emacs/emacs-master.json { }; + emacsGit = mkGitEmacs "emacs-git" ./repos/emacs/emacs-master.json { withSQLite3 = true; withWebP = true; }; - emacsGcc = mkGitEmacs "emacs-gcc" ./repos/emacs/emacs-master.json { nativeComp = true; }; + emacsNativeComp = super.emacsNativeComp or (mkGitEmacs "emacs-native-comp" ./repos/emacs/emacs-unstable.json { nativeComp = true; }); - emacsPgtk = mkPgtkEmacs "emacs-pgtk" ./repos/emacs/emacs-feature_pgtk.json { }; + emacsGitNativeComp = mkGitEmacs "emacs-git-native-comp" ./repos/emacs/emacs-master.json { + withSQLite3 = true; + withWebP = true; + nativeComp = true; + }; - emacsPgtkGcc = mkPgtkEmacs "emacs-pgtkgcc" ./repos/emacs/emacs-feature_pgtk.json { nativeComp = true; }; + emacsPgtk = mkPgtkEmacs "emacs-pgtk" ./repos/emacs/emacs-master.json { withSQLite3 = true; }; - emacsUnstable = (mkGitEmacs "emacs-unstable" ./repos/emacs/emacs-unstable.json { }).overrideAttrs ( - old: { - patches = [ - ./patches/tramp-detect-wrapped-gvfsd-27.patch - ]; - } - ); + emacsPgtkNativeComp = mkPgtkEmacs "emacs-pgtk-native-comp" ./repos/emacs/emacs-master.json { nativeComp = true; withSQLite3 = true; }; + + emacsUnstable = (mkGitEmacs "emacs-unstable" ./repos/emacs/emacs-unstable.json { }); in { inherit emacsGit emacsUnstable; - inherit emacsGcc; + inherit emacsNativeComp emacsGitNativeComp; - inherit emacsPgtk emacsPgtkGcc; + inherit emacsPgtk emacsPgtkNativeComp; emacsGit-nox = ( ( emacsGit.override { + withNS = false; withX = false; withGTK2 = false; withGTK3 = false; @@ -128,6 +124,7 @@ in emacsUnstable-nox = ( ( emacsUnstable.override { + withNS = false; withX = false; withGTK2 = false; withGTK3 = false; @@ -159,12 +156,8 @@ in generated = ./repos/elpa/elpa-generated.nix; }; - orgPackages = esuper.orgPackages.override { - generated = ./repos/org/org-generated.nix; - }; - epkgs = esuper.override { - inherit melpaStablePackages melpaPackages elpaPackages orgPackages; + inherit melpaStablePackages melpaPackages elpaPackages; }; in @@ -185,4 +178,7 @@ in ) ); +} // super.lib.optionalAttrs (super.config.allowAliases or true) { + emacsGcc = builtins.trace "emacsGcc has been renamed to emacsNativeComp, please update your expression." emacsNativeComp; + emacsPgtkGcc = builtins.trace "emacsPgtkGcc has been renamed to emacsPgtkNativeComp, please update your expression." emacsPgtkNativeComp; } |