Subject: [bug#73754] [PATCH 2/5] gnu: sameboy: Use gexps.

From: Maxim Cournoyer <[email-masked]>
Date: Sat, 12 Oct 2024 13:28:11 +0900

* gnu/packages/emulators.scm (sameboy) [arguments]: Use gexps.

Change-Id: Ic5c056f23e94c17072460e92a74663486cfe9e5d
---
 gnu/packages/emulators.scm | 40 +++++++++++++++++---------------------
 1 file changed, 18 insertions(+), 22 deletions(-)

diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm
index a2a1285d77..b7dff958b7 100644
--- a/gnu/packages/emulators.scm
+++ b/gnu/packages/emulators.scm
@@ -813,29 +813,25 @@ (define-public sameboy
        (sha256
         (base32 "1lab1x156ghfcjcy31rv731wi2b5h56z35n02h4i5pj8wjcf2jr9"))))
     (build-system gnu-build-system)
-    (native-inputs
-     (list rgbds pkg-config))
-    (inputs
-     (list sdl2))
     (arguments
-     `(#:tests? #f                      ; There are no tests
-       #:make-flags `(,(string-append "CC=" ,(cc-for-target))
-                      "NATIVE_CC=gcc" "CONF=release"
-                      ,(string-append "DATA_DIR="
-                                      (assoc-ref %outputs "out")
-                                      "/share/sameboy/"))
-       #:phases
-       (modify-phases %standard-phases
-         (delete 'configure)
-         (replace 'install
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let* ((out (assoc-ref outputs "out"))
-                    (bin (string-append out "/bin"))
-                    (data (string-append out "/share/sameboy/")))
-               (with-directory-excursion "build/bin/SDL"
-                 (install-file "sameboy" bin)
-                 (delete-file "sameboy")
-                 (copy-recursively "." data))))))))
+     (list
+      #:tests? #f                       ; There are no tests
+      #:make-flags #~(list #$(string-append "CC=" (cc-for-target))
+                           "NATIVE_CC=gcc" "CONF=release"
+                           (string-append "DATA_DIR=" #$output
+                                          "/share/sameboy/"))
+      #:phases
+      #~(modify-phases %standard-phases
+          (delete 'configure)
+          (replace 'install
+            (lambda _
+              (with-directory-excursion "build/bin/SDL"
+                (install-file "sameboy" (string-append #$output "/bin"))
+                (delete-file "sameboy")
+                (copy-recursively
+                 "." (string-append #$output "/share/sameboy/"))))))))
+    (inputs (list sdl2))
+    (native-inputs (list rgbds pkg-config))
     (home-page "https://sameboy.github.io/")
     (synopsis "Accurate Game Boy, Game Boy Color and Super Game Boy emulator")
     (description "SameBoy is a user friendly Game Boy, Game Boy Color
-- 
2.46.0