2021-04-09 00:35:36 +02:00
|
|
|
{ jansson, harfbuzz, glib-networking
|
|
|
|
, lib
|
|
|
|
|
|
|
|
, withPgtk ? true
|
|
|
|
, withNativeComp ? true
|
|
|
|
, name ? "emacs"
|
|
|
|
, emacsOverlay
|
|
|
|
, emacsSrc
|
|
|
|
}:
|
2021-04-11 00:25:36 +02:00
|
|
|
with lib;
|
2021-04-09 00:35:36 +02:00
|
|
|
(emacsOverlay.emacsGit.overrideAttrs
|
|
|
|
(old: {
|
|
|
|
src = emacsSrc;
|
|
|
|
buildInputs =
|
|
|
|
old.buildInputs ++ [ jansson harfbuzz.dev glib-networking ];
|
|
|
|
makeFlags = [ "NATIVE_FULL_AOT=1" ];
|
|
|
|
|
|
|
|
configureFlags =
|
2021-04-11 00:25:36 +02:00
|
|
|
(if withPgtk then
|
|
|
|
(remove "--with-xft" old.configureFlags)
|
|
|
|
++ singleton "--with-pgtk"
|
2021-04-09 00:35:36 +02:00
|
|
|
else
|
2021-04-11 00:25:36 +02:00
|
|
|
old.configureFlags) ++ (optional withNativeComp "--with-native-compilation");
|
2021-04-09 00:35:36 +02:00
|
|
|
|
|
|
|
inherit name;
|
|
|
|
})).override { nativeComp = withNativeComp; }
|