GNU bug report logs - #76012
[PATCH] gnu: Add ghosthop.

Previous Next

Package: guix-patches;

Reported by: iyzsong <at> envs.net

Date: Sun, 2 Feb 2025 14:28:02 UTC

Severity: normal

Tags: patch

Done: 宋文武 <iyzsong <at> envs.net>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 76012 in the body.
You can then email your comments to 76012 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to adam.faiz <at> disroot.org, liliana.prikler <at> gmail.com, iyzsong <at> envs.net, guix-patches <at> gnu.org:
bug#76012; Package guix-patches. (Sun, 02 Feb 2025 14:28:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to iyzsong <at> envs.net:
New bug report received and forwarded. Copy sent to adam.faiz <at> disroot.org, liliana.prikler <at> gmail.com, iyzsong <at> envs.net, guix-patches <at> gnu.org. (Sun, 02 Feb 2025 14:28:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: iyzsong <at> envs.net
To: guix-patches <at> gnu.org
Cc: 宋文武 <iyzsong <at> member.fsf.org>
Subject: [PATCH] gnu: Add ghosthop.
Date: Sun,  2 Feb 2025 22:30:56 +0800
From: 宋文武 <iyzsong <at> member.fsf.org>

* gnu/packages/games.scm (ghosthop): New variable.

Change-Id: I45867f844517666cb123b1d05a140c0ae8528e79
---
 gnu/packages/games.scm | 66 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 66 insertions(+)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 8255e0623b..4bb96c67c7 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -181,6 +181,7 @@ (define-module (gnu packages games)
   #:use-module (gnu packages libidn)
   #:use-module (gnu packages libunwind)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages lisp)
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages lua)
   #:use-module (gnu packages man)
@@ -2176,6 +2177,71 @@ (define-public knightsgame
     ;; license.  The whole package is released under GPLv3+.
     (license license:gpl3+)))
 
+(define-public ghosthop
+  (let ((commit "9fefc22830ff8fde484452d7a249f4c54feec0fc")
+        (revision "1"))
+    (package
+      (name "ghosthop")
+      (version (git-version "0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://gitlab.com/gcmas/ghosthop.git")
+               (commit commit)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32
+           "021awll73bgjk61r6y6cbqn0dpmki9jp627km7yhx5px15panslq"))
+         (modules '((guix build utils)))
+         (snippet '(delete-file-recursively "vendor"))))
+      (build-system copy-build-system)
+      (arguments
+       (list
+        #:install-plan
+        ;; 'ghosthop' load 'asset' and 'scm' from the current directory.
+        #~'(("ghosthop" "opt/ghosthop/")
+            ("asset" "opt/ghosthop/")
+            ("scm" "opt/ghosthop/"))
+        #:phases
+        #~(modify-phases %standard-phases
+            (add-before 'install 'build
+              ;; Avoid its Makefile to build with system libraries.
+              (lambda* (#:key inputs #:allow-other-keys)
+                (with-output-to-file "rlbind.c"
+                  (lambda ()
+                    (invoke "repl" "rlbind.scm")))
+                (invoke #$(cc-for-target)
+                        "-o" "ghosthop"
+                        "-O3" "-lm" "-lraylib"
+                        (search-input-file inputs "/share/s7/s7.c")
+                        "rlbind.c" "src/init.c")
+                (invoke #$(strip-for-target) "ghosthop")))
+            (add-after 'install 'install-launcher
+              ;; Create an launcher script for 'ghosthop'.
+              (lambda* (#:key inputs outputs #:allow-other-keys)
+                (let* ((out (assoc-ref outputs "out"))
+                       (bindir (string-append out "/bin"))
+                       (gamedir (string-append out "/opt/ghosthop"))
+                       (launcher (string-append bindir "/ghosthop"))
+                       (bash (search-input-file inputs "/bin/bash")))
+                  (mkdir (dirname launcher))
+                  (with-output-to-file launcher
+                    (lambda ()
+                      (format #t "#!~a~%" bash)
+                      (format #t "cd ~a~%" gamedir)
+                      (format #t "exec -a ghosthop ~a~%"
+                              (string-append gamedir "/ghosthop"))))
+                  (chmod launcher #o755)))))))
+      (native-inputs (list s7))
+      (inputs (list bash-minimal raylib))
+      (home-page "https://gitlab.com/gcmas/ghosthop")
+      (synopsis "Puzzle game with colored rules")
+      (description "This is a small puzzle game made for the 2024 Spring Lisp
+Game Jam.  The objective is to reach the goal by assigning rules to colors.")
+      (license (list license:gpl3+            ;code and other assets
+                     license:cc-by-sa3.0))))) ;music
+
 (define-public gnome-2048
   (package
     (name "gnome-2048")

base-commit: b64d3168af697ceb2a96e7e2c62bcf418b8a586a
-- 
2.48.1





Reply sent to 宋文武 <iyzsong <at> envs.net>:
You have taken responsibility. (Tue, 04 Feb 2025 09:48:02 GMT) Full text and rfc822 format available.

Notification sent to iyzsong <at> envs.net:
bug acknowledged by developer. (Tue, 04 Feb 2025 09:48:02 GMT) Full text and rfc822 format available.

Message #10 received at 76012-done <at> debbugs.gnu.org (full text, mbox):

From: 宋文武 <iyzsong <at> envs.net>
To: 76012-done <at> debbugs.gnu.org
Subject: Re: [bug#76012] [PATCH] gnu: Add ghosthop.
Date: Tue, 04 Feb 2025 17:50:53 +0800
Pushed to master, close.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 04 Mar 2025 12:24:08 GMT) Full text and rfc822 format available.

This bug report was last modified 186 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.