Subject: [bug#75537] [PATCH 2/2] gnu: Add libretro-bsnes-hd.

From: Maxim Cournoyer <[email-masked]>
Date: Tue, 14 Jan 2025 00:28:11 +0900

* gnu/packages/emulators.scm (libretro-bsnes-hd): New variable.

Change-Id: Ibb99d4f027530d5dc812c1cdbc22ad9d972234e5
---
 gnu/packages/emulators.scm | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm
index 5a2ac8846f..1c8f66c924 100644
--- a/gnu/packages/emulators.scm
+++ b/gnu/packages/emulators.scm
@@ -3230,6 +3230,21 @@ (define-public bsnes-hd
 @end table")
     (license license:gpl3+)))
 
+(define-public libretro-bsnes-hd
+  (package/inherit bsnes-hd
+    (name "libretro-bsnes-hd")
+    (arguments
+     (substitute-keyword-arguments (package-arguments bsnes-hd)
+       ((#:make-flags flags ''())
+        #~(cons "target=libretro" #$flags))
+       ((#:phases phases '%standard-phases)
+        #~(modify-phases #$phases
+            (replace 'install           ;no install target
+              (lambda _
+                (install-file "bsnes/out/bsnes_hd_beta_libretro.so"
+                              (string-append #$output "/lib/libretro/"))))))))
+    (synopsis "Libretro port of bsnes-hd")))
+
 (define-public jg-api
   (package
     (name "jg-api")
-- 
2.47.1