Subject: [bug#72406] [PATCH emacs-team WIP v4 17/24] gnu: emacs-guix: Build variants.

From: Liliana Marie Prikler <[email-masked]>
Date: Sun, 11 Aug 2024 14:58:48 +0200

* gnu/packages/emacs-xyz.scm (emacs-guix)[native-inputs]: Replace
emacs-minimal with emacs.
[properties]: Add ‘minimal-variant’, ‘next-variant’ and ‘pgtk-variant’.
(emacs-minimal-guix, emacs-next-guix, emacs-pgtk-guix): New variables.
---
 gnu/packages/emacs-xyz.scm | 47 ++++++++++++++++++++++++++++++++++++--
 1 file changed, 45 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index d10b2c0f1b..764b535d45 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -6216,7 +6216,7 @@ (define-public emacs-guix
                 ((assoc-ref emacs:%standard-phases 'expand-load-path)
                  #:prepend-source? #f))))))
       (native-inputs
-       (list autoconf automake emacs-minimal pkg-config texinfo))
+       (list autoconf automake emacs pkg-config texinfo))
       (inputs
        (list (lookup-package-input guix "guile")
              guix))
@@ -6235,7 +6235,50 @@ (define-public emacs-guix
 Guix package manager.  Particularly, it allows you to do various package
 management tasks from Emacs.  To begin with, run @code{M-x guix-about} or
 @code{M-x guix-help} command.")
-      (license license:gpl3+))))
+      (license license:gpl3+)
+      (properties
+       `((minimal-variant . ,(delay emacs-minimal-pdf-tools))
+         (next-variant . ,(delay emacs-next-pdf-tools))
+         (pgtk-variant . ,(delay emacs-pgtk-pdf-tools)))))))
+
+(define-public emacs-minimal-guix
+  (package/inherit emacs-guix
+    (name "emacs-minimal-guix")
+    (native-inputs (modify-inputs (package-native-inputs emacs-guix)
+                     (replace "emacs" emacs-minimal)))
+    (propagated-inputs (list emacs-minimal-bui
+                             emacs-minimal-dash
+                             emacs-minimal-edit-indirect
+                             emacs-minimal-geiser
+                             emacs-minimal-geiser-guile
+                             emacs-minimal-magit-popup
+                             guile-gcrypt))))
+
+(define-public emacs-next-guix
+  (package/inherit emacs-guix
+    (name "emacs-next-guix")
+    (native-inputs (modify-inputs (package-native-inputs emacs-guix)
+                     (replace "emacs" emacs-next)))
+    (propagated-inputs (list emacs-next-bui
+                             emacs-next-dash
+                             emacs-next-edit-indirect
+                             emacs-next-geiser
+                             emacs-next-geiser-guile
+                             emacs-next-magit-popup
+                             guile-gcrypt))))
+
+(define-public emacs-pgtk-guix
+  (package/inherit emacs-guix
+    (name "emacs-pgtk-guix")
+    (native-inputs (modify-inputs (package-native-inputs emacs-guix)
+                     (replace "emacs" emacs-pgtk)))
+    (propagated-inputs (list emacs-pgtk-bui
+                             emacs-pgtk-dash
+                             emacs-pgtk-edit-indirect
+                             emacs-pgtk-geiser
+                             emacs-pgtk-geiser-guile
+                             emacs-pgtk-magit-popup
+                             guile-gcrypt))))
 
 (define-public emacs-build-farm
   (package
-- 
2.45.2