From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id QNOIDthTWmQOYgAASxT56A (envelope-from ) for ; Tue, 09 May 2023 16:08:24 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 6HhUDthTWmSw+gAAauVa8A (envelope-from ) for ; Tue, 09 May 2023 16:08:24 +0200 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D2ABE1D0F0 for ; Tue, 9 May 2023 16:08:23 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pwO0c-0000Qz-6p; Tue, 09 May 2023 10:08:06 -0400 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 1pwO0a-0000Qb-AO for guix-patches@gnu.org; Tue, 09 May 2023 10:08:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pwO0Z-0001bJ-9R for guix-patches@gnu.org; Tue, 09 May 2023 10:08:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pwO0Y-0002HT-LT for guix-patches@gnu.org; Tue, 09 May 2023 10:08:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#63391] [PATCH] gnu: Add bbcsdl. Resent-From: iyzsong@envs.net Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 09 May 2023 14:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 63391 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 63391@debbugs.gnu.org Cc: =?UTF-8?Q?=E5=AE=8B=E6=96=87=E6=AD=A6?= X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16836412608732 (code B ref -1); Tue, 09 May 2023 14:08:02 +0000 Received: (at submit) by debbugs.gnu.org; 9 May 2023 14:07:40 +0000 Received: from localhost ([127.0.0.1]:44097 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pwO0C-0002Gl-0V for submit@debbugs.gnu.org; Tue, 09 May 2023 10:07:40 -0400 Received: from lists.gnu.org ([209.51.188.17]:39742) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pwO07-0002Ga-Ja for submit@debbugs.gnu.org; Tue, 09 May 2023 10:07:38 -0400 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 1pwO07-0000JX-CG for guix-patches@gnu.org; Tue, 09 May 2023 10:07:35 -0400 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 1pwO01-0001V5-QK for guix-patches@gnu.org; Tue, 09 May 2023 10:07:33 -0400 Received: from localhost (mail.envs.net [127.0.0.1]) by mail.envs.net (Postfix) with ESMTP id 8672338A00C2; Tue, 9 May 2023 14:07:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=envs.net; s=modoboa; t=1683641238; bh=Vx4pyGsLMCPTq5bD5uErgdUvD470Ons6jXz8p0tWnbk=; h=From:To:Cc:Subject:Date:From; b=arvI0ol62keHZ4vNHqWLAfFCuzFwBLt3x9t6c9xcCkV4oM4Gd4Cb1ibuaqZaYeS16 6F16J9Zz0oh+q669GxRgdpX79R7naJTLLNuhxd+UNdXXbdVeaW7AAM3ybvMG90B+Xk duDkgJuHrq9eE968zQiFlUgqb0PfdHmG1uMFGjE7AmG2CuWUiHNEgDCj9b9Rh9tSdN Bhoo4cUYCzIZWriXLNbYs++R+UieNk1AojzLDH4dL3bNPNGk+4BUarwHI6z4+R19uP nPcniVtJgW8peD5Z5B0CxTHJ5e7qG3DAb4Y4eKvCIMcLlv7RMh8BqbQfDclHmboWWy 7AQNnjGJlOWD+F7S6jKnPAkPsIy5mA6dDZlhhVh55MIEFhubZYb18bt4ndbBTQAq2R tNzpJuREo0v3MRVaKXtgz3A1peAvgczEUJ8TeLFDHETFXM9M4Z4YQaxZSfnSKJ1g5X o1n7xexPXuwTGcMN4eQJKeaYeJoud4a/HHS1prj6PIEknlImur7Zgk25qyyr6BgP8x zC+UxII6DJBoB4eLxbV104Qcu2JsnNxIhEbEltDdNnFrOW6qDsvwAuqmrPWMdCUhHC f6FEmOaph6aTK6DhZzzrnSLOUpZmZQbjKgIyvz9RoZN1IYwHiFPSnBCPIQFgpZ3f9j P9nSTADqlkjlLLapKU+JYZFE= 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 iTIbslnRNldp; Tue, 9 May 2023 14:07:15 +0000 (UTC) Received: from localhost (unknown [36.170.44.145]) (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; Tue, 9 May 2023 14:07:14 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by localhost (OpenSMTPD) with ESMTP id 655cfc36; Tue, 9 May 2023 14:06:46 +0000 (UTC) Date: Tue, 9 May 2023 22:06:34 +0800 Message-Id: X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=5.199.136.28; envelope-from=iyzsong@envs.net; helo=mail.envs.net X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=unavailable 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 From: iyzsong--- via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Seal: i=1; s=key1; d=yhetil.org; t=1683641303; a=rsa-sha256; cv=none; b=ZHRz+3clt6BcHYk8pshHv5Qeoy01J5JAj4fa49HYk6bfZkeJoU0G+gh8MffO54UtVUfah1 DhNehrmDLFY2N69OC6vxX4NOE8p0Bm0H9dwEGEPfhHDFKjK61M9cr3/oATUG/4nV1XU0fN 7c5ocaHawU05k/RWEHbhXoBOqkGxnX8iOf1YwVcI9bZIoA8PyELLo7HFaAXq6W+MNhgAXr keNOAIDN5dKDnc5CXW/C8qSxEL1ybjyUihrfUgqmv3PjnOIvL6avhIqegXkAL8mWuj0W7x BPJdVY8dlUI73Kt6Zkyq0GKG0UzkBvD5xz5Ll9/QLESbAq+cY5J1u9DdgnTeNg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=envs.net header.s=modoboa header.b=arvI0ol6; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1683641303; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=Vx4pyGsLMCPTq5bD5uErgdUvD470Ons6jXz8p0tWnbk=; b=AmcjpXdPbZc2T4aaJOy7DUdY5j/1z0jgGFA2RGcEjgTBxSQakhjALH0B5pQLvXO6Co3mvG 87R6IFNWksdP/HFB+lz1yDAXIFwrPQGjqewLwoSLi4MQuOqjMo58MFFZpZAv+NWXPw0KAh +bRl1opDrtITwcfWM23uWeuAKAT1q8N30pC0nlJD/S06nCJZoX875U15ZMwqr2dXUKuZYY 6VNFxQ4LpaIpyMy4wSjVASeZO/WqfNsaBcfr+GJAn7HcZjJ115VIfLmeiyGHSJjlSFWL1/ QgaS0r9s0O/rEB8vOgus4UbEbwMOwC0eaANgmXktkvGjNVQHBMe47mZ0pvnn1g== X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=envs.net header.s=modoboa header.b=arvI0ol6; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -2.38 X-Spam-Score: -2.38 X-Migadu-Queue-Id: D2ABE1D0F0 X-TUID: IvST6AE/DXFK From: 宋文武 * gnu/packages/game-development.scm (bbcsdl): New variable. --- gnu/packages/game-development.scm | 72 +++++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 844ce935ae..ae6a49b1a1 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -59,6 +59,7 @@ (define-module (gnu packages game-development) #:use-module (guix build-system python) #:use-module (guix build-system scons) #:use-module (gnu packages) + #:use-module (gnu packages assembly) #:use-module (gnu packages audio) #:use-module (gnu packages autotools) #:use-module (gnu packages base) @@ -2884,3 +2885,74 @@ (define-public raylib writing your game.") (home-page "https://www.raylib.com/") (license license:zlib))) + +(define-public bbcsdl + (package + (name "bbcsdl") + (version "1.35a") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/rtrussell/BBCSDL/") + (commit "b9b2a3eb438cb799edb2766055b3c38e9518e3e3"))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1d03xmhrl6ba6w0vwfk46mpyc9d0w3bixxj2d4irx7wl7bh3bfic")))) + (build-system gnu-build-system) + (arguments + (list + #:tests? #f ; XXX: tests not automated + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ; no configure script + (replace 'build + (lambda* (#:key outputs #:allow-other-keys) + ;; 'makefile' expects the source directory to be named 'BBCSDL'. + (symlink "source" "../BBCSDL") + ;; 'bbcsdl' finds 'libstb.so' in its RPATH. + (substitute* "bin/linux/makefile" + (("-Wl,-R,'\\$\\$ORIGIN'") + (string-append "-Wl,-rpath=" + (assoc-ref outputs "out") "/opt/bbcsdl"))) + ;; Build 'bbcbasic' and 'bbcsdl'. + (invoke "make" "-C" "console/linux") + (invoke "make" "-C" "bin/linux"))) + (replace 'install + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (opt (string-append out "/opt/bbcsdl")) + (bin (string-append out "/bin"))) + (for-each + (lambda (f) + (copy-recursively f (string-append opt "/" f))) + ;; Those files need to be installed into the same difertory. + '("lib" "examples" "bbcsdl.bbc" + "libstb.so" "bbcsdl" "bbcbasic")) + ;; Replace bundled fonts. + (for-each + (lambda (font) + (delete-file (string-append opt "/lib/" font)) + (symlink + (search-input-file + inputs (string-append "share/fonts/truetype/" font)) + (string-append opt "/lib/" font))) + '("DejaVuSans.ttf" "DejaVuSansMono.ttf" + "FreeSans.ttf" "FreeMono.ttf" "FreeSerif.ttf")) + (mkdir bin) + (symlink (string-append opt "/bbcsdl") + (string-append bin "/bbcsdl")) + (symlink (string-append opt "/bbcbasic") + (string-append bin "/bbcbasic")))))))) + (native-inputs (list nasm)) + (inputs (list sdl2 sdl2-ttf sdl2-net font-dejavu font-gnu-freefont)) + (synopsis "BBC BASIC for SDL 2.0") + (home-page "https://www.bbcbasic.co.uk/bbcsdl/") + (description + "BBC BASIC is the programming language originally specified and adopted +by the British Broadcasting Corporation for its groundbreaking Computer +Literacy Project of the early 1980s. BBC BASIC for SDL 2.0 combines the +simplicity of BASIC with the sophistication of a modern structured language, +allowing you to write utilities and games, use sound and graphics, perform +calculations and create complete applications.") + (license license:zlib))) base-commit: 649ce7b433171a47e8a2819b849bfa88c736d0e9 -- 2.39.2