From patchwork Tue Mar 14 06:57:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Faiz X-Patchwork-Id: 47957 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 CBE6A16EA5; Tue, 14 Mar 2023 06:58:16 +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=-1.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,URIBL_BLOCKED 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 CFE9F16E4E for ; Tue, 14 Mar 2023 06:58:15 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pbybk-0002tj-QW; Tue, 14 Mar 2023 02:58:04 -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 1pbybj-0002tV-3W for guix-patches@gnu.org; Tue, 14 Mar 2023 02:58:03 -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 1pbybi-0004uK-QM for guix-patches@gnu.org; Tue, 14 Mar 2023 02:58:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pbybi-0007mV-DY for guix-patches@gnu.org; Tue, 14 Mar 2023 02:58:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#62178] [PATCH 1/5] gnu: Add fgeal. References: <00c2af06-fa2f-81d3-e3de-444eaf232732@disroot.org> In-Reply-To: <00c2af06-fa2f-81d3-e3de-444eaf232732@disroot.org> Resent-From: Adam Faiz Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 14 Mar 2023 06:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62178 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 62178@debbugs.gnu.org Cc: Liliana Marie Prikler , iyzsong@envs.net Received: via spool by 62178-submit@debbugs.gnu.org id=B62178.167877704529854 (code B ref 62178); Tue, 14 Mar 2023 06:58:02 +0000 Received: (at 62178) by debbugs.gnu.org; 14 Mar 2023 06:57:25 +0000 Received: from localhost ([127.0.0.1]:36096 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pbyb7-0007lS-3w for submit@debbugs.gnu.org; Tue, 14 Mar 2023 02:57:25 -0400 Received: from knopi.disroot.org ([178.21.23.139]:38842) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pbyb4-0007lJ-Cb for 62178@debbugs.gnu.org; Tue, 14 Mar 2023 02:57:23 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 9D74644593; Tue, 14 Mar 2023 07:57:21 +0100 (CET) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5omTNKjCcRU8; Tue, 14 Mar 2023 07:57:20 +0100 (CET) Message-ID: <21349edf-d7fa-ec74-e40f-7fc155658449@disroot.org> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1678777040; bh=jciicnkvX5BnfEH1W39R6Hmj/8U8Yd/ZBzd/LPLgxpU=; h=Date:To:Cc:From:Subject; b=c4H6VNthwKFGrT0QcDcdK1XJrAlUPFtXQXi3rKGDh4CDPJg4uK9cO1NxwsJRyHfti Yb1/zbKvpSfx8X2Q3aha0D7DVHrzIZAcsIY8woeN4s6/ykIcUaXlLGU6tM6AJiLnpj W91MUbrzGFuaNxIdHPtO2lTStn3X++y060tQzJ/GtFQesn6QllnKh9yxaxZ+ejysT2 IbmxBEAHwn2XGZsuvux74CBM8+TiwvfigenEE9l6yC0eKthSUClrF6WNmctM6sN3Qw ts7HkYVwYjaPK+pf+QOatKjSJ6ZxFZt8FxsyQj0ELIh55vPVaNefFRH88MCGBpOsM6 q4eHX1LH1s1Kw== Date: Tue, 14 Mar 2023 14:57:16 +0800 MIME-Version: 1.0 Content-Language: en-US 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: Adam Faiz X-ACL-Warn: , Adam Faiz via Guix-patches X-Patchwork-Original-From: Adam Faiz via Guix-patches via From: Adam Faiz 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 f2dc6209535b2ad8aed999845c0992264cc7aff6 Mon Sep 17 00:00:00 2001 Message-Id: In-Reply-To: References: From: AwesomeAdam54321 Date: Tue, 14 Mar 2023 13:38:36 +0800 Subject: [PATCH 1/5] gnu: Add fgeal. * gnu/packages/game-development.scm (fgeal): New variable. --- gnu/packages/game-development.scm | 106 ++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index a384572a9d..f86793fda0 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -2359,6 +2359,112 @@ (define-public flatzebra double-buffering.") (license license:gpl2+))) +(define-public fgeal + (let ((commit "0ae72fbf31eb2e133fe83520391e7a82c0b59e67") + (revision "0")) + (package + (name "fgeal") + (version (git-version "0.8.4" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/hydren/fgeal") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0lck86n8nkhb088bd0jg4imi9j5l1lwfr2pddqqr880rjrnnm8fw")) + (modules '((guix build utils))) + (snippet + #~(begin + (with-directory-excursion "project/build/linux-gcc-sdl2-release" + (rename-file "configure.sh" "configure") + (substitute* "configure" + (("-exec sed -i") + (string-append + "-exec sed -i" + " \"s,SDL2_CFLAGS,`pkg-config --cflags sdl2`,g\" {} \\;" + " -exec sed -i")) + (("which") "type -p")) + (substitute* "makefile" + (("RM := rm -rf") + (string-append "RM := rm -rf\n" + "PREFIX ?= /usr/local")) + (("clean:") + (string-append + "install:\n\t" + "install -d $(DESTDIR)$(PREFIX)/include\n\t" + "cp -r ../fgeal $(DESTDIR)$(PREFIX)/include\n\t" + "install -d $(DESTDIR)$(PREFIX)/lib\n\t" + "install -m 644 libfgeal.so $(DESTDIR)$(PREFIX)/lib\n\n" + "clean:"))) + (substitute* "extra/subdir.mk" + (("../extra/input_manager.cpp \\\\") + (string-append "../extra/input_manager.cpp \\\n" + "../extra/primitives.cpp \\")) + (("./extra/input_manager.o \\\\") + (string-append "./extra/input_manager.o \\\n" + "./extra/primitives.o \\")) + (("./extra/input_manager.d \\\\") + (string-append "./extra/input_manager.d \\\n" + "./extra/primitives.d \\")))) + (copy-recursively "project/build/linux-gcc-sdl2-release" + "linux-gcc-sdl2-release") + (substitute* (find-files "." "\\.mk") + (("-I\"BUILD_PATH\"") "-I\"BUILD_PATH\" SDL2_CFLAGS")) + (for-each + (lambda (file) + (install-file file "fgeal")) + '("agnostic_cached_drawable_text.hxx" + "agnostic_filesystem.hxx" + "agnostic_sound_stream.hxx" + "colors.hpp" + "core.hpp" + "display.hpp" + "event.hpp" + "exceptions.hpp" + "fgeal.hpp" + "filesystem.hpp" + "font.hpp" + "friend_classes.hxx" + "generic_graphics.hxx" + "geometry.hpp" + "graphics.hpp" + "image.hpp" + "input.hpp" + "sound.hpp" + "version.h")) + (for-each + (lambda (file) + (install-file file "fgeal/extra")) + (find-files "extra" "\\.hpp")))))) + (build-system gnu-build-system) + (native-inputs + (list pkg-config)) + (inputs + (list sdl2 + sdl2-gfx + sdl2-image + sdl2-mixer + sdl2-ttf)) + (arguments + (list #:tests? #f ; no tests + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'chdir + (lambda _ + (chdir "linux-gcc-sdl2-release")))) + #:make-flags + #~(list (string-append "DESTDIR=" #$output) + "PREFIX="))) + (home-page "https://gitlab.com/hydren/fgeal") + (synopsis "Simple C++ game library wrapper") + (description "fgeal is a simple C++ wrapper library meant to provide +common functionalities between some game libraries through a single API. + It serves as a cross-platform abstraction layer to other low-level game +libraries, such as SDL.") + (license license:lgpl2.1+)))) + (define-public libccd (package (name "libccd")