guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: gnu: Add moonfish.


From: guix-commits
Subject: branch master updated: gnu: Add moonfish.
Date: Fri, 27 Oct 2023 07:52:41 -0400

This is an automated email from the git hooks/post-receive script.

rekado pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new c11b9133d2 gnu: Add moonfish.
c11b9133d2 is described below

commit c11b9133d29a815d947b556551563c8dc4a68a35
Author: zamfofex <zamfofex@twdb.moe>
AuthorDate: Fri Oct 20 22:17:28 2023 -0300

    gnu: Add moonfish.
    
    * gnu/packages/games.scm (moonfish): New variable.
    
    Signed-off-by: Ricardo Wurmus <rekado@elephly.net>
    Change-Id: Idadb367c60648a1c98601302398dae1373e68919
---
 gnu/packages/games.scm | 49 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 48d5007ff2..16f49f5e6a 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -10366,6 +10366,55 @@ ChessX.")
       (home-page "https://stockfishchess.org/";)
       (license license:gpl3+))))
 
+(define-public moonfish
+  (let ((commit "4f8829009e8c26e6a878261e0bc4c7e7617ef6b6")
+        (revision "1"))
+    (package
+      (name "moonfish")
+      (version (git-version "0" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://git.sr.ht/~zamfofex/moonfish";)
+                      (commit commit)))
+                (sha256
+                 (base32
+                  "1ksg42x9cyn3pbfryy9raqb355k47cqcisascpy157c3cgdr2z60"))
+                (file-name (git-file-name name version))))
+      (build-system gnu-build-system)
+      (arguments
+       (list
+        #:make-flags
+        #~(list (string-append "CC=" #$(cc-for-target)))
+        #:tests? #f                     ;no check target
+        #:phases
+        #~(modify-phases %standard-phases
+            (delete 'configure)         ;no configure script
+            (replace 'install           ;no 'install' target
+              (lambda _
+                (let* ((out-bin (string-append #$output "/bin"))
+                       (tools-bin (string-append #$output:tools "/bin"))
+                       (tool (string-append tools-bin "/moonfish-")))
+                  (mkdir-p out-bin)
+                  (mkdir-p tools-bin)
+                  (copy-file "moonfish"
+                             (string-append out-bin "/moonfish"))
+                  (copy-file "play"
+                             (string-append tool "play"))
+                  (copy-file "lichess"
+                             (string-append tool "lichess"))
+                  (copy-file "analyse"
+                             (string-append tool "analyse"))))))))
+      (inputs (list bearssl cjson))
+      (outputs '("out" "tools"))
+      (home-page "https://git.sr.ht/~zamfofex/moonfish";)
+      (synopsis "Simple chess engine written in C")
+      (description
+       "moonfish is a toy UCI chess engine made for fun.  It is inspired by
+sunfish, but is written in C rather than Python.  It also has TUI tools for
+using any UCI engine and also to connect UCI engines to Lichess.")
+      (license license:agpl3+))))
+
 (define-public barrage
   (package
     (name "barrage")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]