From patchwork Sun Feb 2 14:30:56 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: tusharhero--- via Guix-patches via X-Patchwork-Id: 38178 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E29DD27BBEA; Sun, 2 Feb 2025 14:28:31 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id CF4E427BBE2 for ; Sun, 2 Feb 2025 14:28:30 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1teaxH-0006mZ-BK; Sun, 02 Feb 2025 09:28:11 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1teax9-0006mD-9q for guix-patches@gnu.org; Sun, 02 Feb 2025 09:28:03 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1teax9-0007yj-1Z for guix-patches@gnu.org; Sun, 02 Feb 2025 09:28:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:Subject; bh=OnpByoQZSjBjiYEL0ej0SZL/FIgz2e57yEsWbCPH9GU=; b=Xj/saCz0a/AzQtWiU0Wq2pJTCR9AMaW1STAVdGo/Vdz4oe3N/SOBm6hGG3Qoftlc3LvpnU1nkaTqVZivZM6DTwARnFsRToI+0C0sWFbdeD31+iV9fN8aSU39rECGAC1mF62mivkEmnaYzP1hUsulq1V4LJo6q/zh3XuBCJ/UnazYc+7TdU1/zC6/1RB0s4FjPlK2EqUM2Md/8D4m4NTaJddfUt2IxEYjhIb3ZYaTJEtocU3YweJ3kODtx2n3AQMKahmh5rm18gbpL4bvdenFAzGTETVK70Zo+tHzhTOtDQRh1sfLpELAL0FuRBI+2agH48LPYUMX68DOgxDnRPIG5A==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1teax8-0003Nu-FE; Sun, 02 Feb 2025 09:28:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#76012] [PATCH] gnu: Add ghosthop. Resent-From: iyzsong@envs.net Original-Sender: "Debbugs-submit" Resent-CC: adam.faiz@disroot.org, liliana.prikler@gmail.com, iyzsong@envs.net, guix-patches@gnu.org Resent-Date: Sun, 02 Feb 2025 14:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 76012 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 76012@debbugs.gnu.org Cc: =?utf-8?b?5a6L5paH5q2m?= , Adam Faiz , Liliana Marie Prikler , =?utf-8?b?5a6L5paH5q2m?= X-Debbugs-Original-To: guix-patches@gnu.org X-Debbugs-Original-Xcc: Adam Faiz , Liliana Marie Prikler , =?utf-8?b?5a6L5paH5q2m?= Received: via spool by submit@debbugs.gnu.org id=B.173850647312992 (code B ref -1); Sun, 02 Feb 2025 14:28:02 +0000 Received: (at submit) by debbugs.gnu.org; 2 Feb 2025 14:27:53 +0000 Received: from localhost ([127.0.0.1]:33678 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1teawy-0003NT-LC for submit@debbugs.gnu.org; Sun, 02 Feb 2025 09:27:53 -0500 Received: from lists.gnu.org ([2001:470:142::17]:42848) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1teawq-0003Mn-Ot for submit@debbugs.gnu.org; Sun, 02 Feb 2025 09:27:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1teawf-0006jH-3b for guix-patches@gnu.org; Sun, 02 Feb 2025 09:27:33 -0500 Received: from mail.envs.net ([5.199.136.28]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1teawd-0007rU-6P for guix-patches@gnu.org; Sun, 02 Feb 2025 09:27:32 -0500 Received: from localhost (mail.envs.net [127.0.0.1]) by mail.envs.net (Postfix) with ESMTP id 6BDA738A3E6C; Sun, 2 Feb 2025 14:27:28 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at mail.envs.net Received: from mail.envs.net ([127.0.0.1]) by localhost (mail.envs.net [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id HrOgThuAgHu9; Sun, 2 Feb 2025 14:27:24 +0000 (UTC) Received: from localhost (unknown [112.44.100.200]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.envs.net (Postfix) with ESMTPSA; Sun, 2 Feb 2025 14:27:23 +0000 (UTC) Received: from localhost.localdomain (localhost.lan [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 72a34836; Sun, 2 Feb 2025 14:31:00 +0000 (UTC) Date: Sun, 2 Feb 2025 22:30:56 +0800 Message-ID: <1f3d3ae66d44a521b302f339872933303826abe5.1738506579.git.iyzsong@member.fsf.org> X-Mailer: git-send-email 2.48.1 MIME-Version: 1.0 Received-SPF: pass client-ip=5.199.136.28; envelope-from=iyzsong@envs.net; helo=mail.envs.net X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: iyzsong@envs.net X-ACL-Warn: , iyzsong--- via Guix-patches X-Patchwork-Original-From: iyzsong--- via Guix-patches via From: tusharhero--- via Guix-patches via Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches From: 宋文武 * gnu/packages/games.scm (ghosthop): New variable. Change-Id: I45867f844517666cb123b1d05a140c0ae8528e79 --- gnu/packages/games.scm | 66 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) base-commit: b64d3168af697ceb2a96e7e2c62bcf418b8a586a 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")