Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkgs/applications/editors/emacs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ lib.makeScope pkgs.newScope (
inherit lib;
inherit (pkgs)
fetchFromBitbucket
fetchurl
fetchzip
;
};

Expand Down
13 changes: 11 additions & 2 deletions pkgs/applications/editors/emacs/make-emacs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@
# Boolean flags
withNativeCompilation ? stdenv.buildPlatform.canExecute stdenv.hostPlatform,
noGui ? false,
srcRepo ? false,
withAcl ? false,
withAlsaLib ? false,
withAthena ? false,
Expand Down Expand Up @@ -199,11 +200,14 @@ mkDerivation (finalAttrs: {
];

postPatch = lib.concatStringsSep "\n" [
(lib.optionalString srcRepo ''
rm -fr .git
'')

# See: https://github.com/NixOS/nixpkgs/issues/170426
''
(lib.optionalString (!srcRepo) ''
find . -type f \( -name "*.elc" -o -name "*loaddefs.el" \) -exec rm {} \;
''
'')

# Add the name of the wrapped gvfsd
# This used to be carried as a patch but it often got out of sync with
Expand Down Expand Up @@ -248,6 +252,11 @@ mkDerivation (finalAttrs: {
nativeBuildInputs = [
makeWrapper
pkg-config
]
++ lib.optionals (variant == "macport") [
texinfo
]
++ lib.optionals srcRepo [
autoreconfHook
texinfo
]
Expand Down
10 changes: 5 additions & 5 deletions pkgs/applications/editors/emacs/sources.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
lib,
fetchFromBitbucket,
fetchurl,
fetchzip,
}:

let
Expand All @@ -26,8 +26,8 @@ let
src =
{
"mainline" = (
fetchurl {
url = "mirror://gnu/emacs/emacs-${rev}.tar.xz";
fetchzip {
url = "mirror://gnu/emacs/${rev}.tar.xz";
inherit hash;
}
);
Expand Down Expand Up @@ -107,8 +107,8 @@ in
pname = "emacs";
version = "30.2";
variant = "mainline";
rev = "30.2";
hash = "sha256-s/NvGKbdJxVxM3AWYlfeL64B+dOM/oeM7Zsebe1b79k=";
rev = "emacs-30.2";
hash = "sha256-W2eZ+cNQhi/fMeRkwOqSKU7Vzvp43WUOpiwaLLNEXtg=";
patches = fetchpatch: [
(builtins.path {
name = "inhibit-lexical-cookie-warning-67916.patch";
Expand Down
Loading