From patchwork Tue Mar 14 07:09:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Faiz X-Patchwork-Id: 47959 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 82B2916EA0; Tue, 14 Mar 2023 07:11:19 +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=unavailable 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 5387316E4E for ; Tue, 14 Mar 2023 07:11:16 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pbyoL-000729-KA; Tue, 14 Mar 2023 03:11:05 -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 1pbyoJ-000720-Ik for guix-patches@gnu.org; Tue, 14 Mar 2023 03:11: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 1pbyoJ-0006ly-2c for guix-patches@gnu.org; Tue, 14 Mar 2023 03:11:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pbyoI-00086k-Ij for guix-patches@gnu.org; Tue, 14 Mar 2023 03:11:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#62178] [PATCH 3/5] gnu: Add libgeramun. 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 07:11: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.167877780631099 (code B ref 62178); Tue, 14 Mar 2023 07:11:02 +0000 Received: (at 62178) by debbugs.gnu.org; 14 Mar 2023 07:10:06 +0000 Received: from localhost ([127.0.0.1]:36108 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pbynN-00085W-8s for submit@debbugs.gnu.org; Tue, 14 Mar 2023 03:10:05 -0400 Received: from knopi.disroot.org ([178.21.23.139]:39070) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pbynK-00084z-9C for 62178@debbugs.gnu.org; Tue, 14 Mar 2023 03:10:03 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id C450C4153C; Tue, 14 Mar 2023 08:10:00 +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 PmiweStz4rHn; Tue, 14 Mar 2023 08:09:59 +0100 (CET) Message-ID: <4a5cec1d-edac-a65d-c010-5a969c365e5b@disroot.org> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1678777799; bh=Pk6g3FzjlBJ8IaLuQhyKvG13sgoMi9lmG/+/e/m5QZE=; h=Date:To:From:Subject:Cc; b=QBNJ0oWtx+owbOtqUUkf1cwgdQscdColLCmrsCt6JlzuOPX9EleSjkavm2t9ryrFG zg/R70L2faIAyZmJZFL+jpFllEkiJBPYIZNvimMOTtSRJHmR/RGE1IfAu2mZe5I2mN 1CDEgns8MSeP9L0koeHJ5MH9tnvQxItRD6rjwmKed9IgiamLlM9e6cBvc/YS+3oO8c 94wWwul45TszlzpQw+reVGyHZto1DRIB46Qg/deGqm/SHAJqD16UhqQd26uI0GHSe1 uPps8GKpAGgiec/VSEQBmstVQnKbL2bAAQU6N1PHQZsaxcLkkdUULSTFWD2GtkpTOU a5kwzBbzKOJIg== Date: Tue, 14 Mar 2023 15:09:56 +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 03a5262a846175be5ce4c8e1b9ea6d199a46b4fa Mon Sep 17 00:00:00 2001 Message-Id: <03a5262a846175be5ce4c8e1b9ea6d199a46b4fa.1678775193.git.adam.faiz@disroot.org> In-Reply-To: References: From: AwesomeAdam54321 Date: Tue, 14 Mar 2023 14:02:58 +0800 Subject: [PATCH 3/5] gnu: Add libgeramun. * gnu/packages/game-development.scm (libgeramun): New variable. * gnu/packages/patches/libgeramun-Add-Makefile.patch: New file. * gnu/local.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + gnu/packages/game-development.scm | 41 ++++++++++ .../patches/libgeramun-Add-Makefile.patch | 79 +++++++++++++++++++ 3 files changed, 121 insertions(+) create mode 100644 gnu/packages/patches/libgeramun-Add-Makefile.patch diff --git a/gnu/local.mk b/gnu/local.mk index 1bdbddce5e..228ec92bb1 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1382,6 +1382,7 @@ dist_patch_DATA = \ %D%/packages/patches/libffi-3.3-powerpc-fixes.patch \ %D%/packages/patches/libffi-float128-powerpc64le.patch \ %D%/packages/patches/libgeotiff-fix-tests-with-proj-9.1.1.patch \ + %D%/packages/patches/libgeramun-Add-Makefile.patch \ %D%/packages/patches/libobjc2-unbundle-robin-map.patch \ %D%/packages/patches/librime-fix-build-with-gcc10.patch \ %D%/packages/patches/libvirt-add-install-prefix.patch \ diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index f86793fda0..57bffa9b88 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -2494,6 +2494,47 @@ (define-public libccd a.k.a. XenoCollide) as described in Game Programming Gems 7.") (license license:expat))) +(define-public libgeramun + (let ((commit "29668d33266a00fa730d8ee5a16893a86ee2d04d") + (revision "0")) + (package + (name "libgeramun") + (version (git-version "0.14" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/hydren/libgeramun") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1nfsdyp3nnz33wxy54vnbbm50kr2y5h6q40kz6g1whz12lqmi79n")) + (patches + (search-patches "libgeramun-Add-Makefile.patch")) + (modules '((guix build utils))) + (snippet + #~(begin + (for-each + (lambda (file) + (install-file file "include/libgeramun")) + (find-files "." "\\.h")))))) + (build-system gnu-build-system) + (arguments + (list #:tests? #f ; no tests + #:phases + #~(modify-phases %standard-phases + (delete 'configure)) + #:make-flags + #~(list (string-append "DESTDIR=" #$output) + "PREFIX="))) + (synopsis "Procedural platformer-game map generation library") + (description + "libgeramun is a set of +stochastic, procedural platformer-game map generation routines. + The routines are meant to produce maps with a Terraria-like look and feel.") + (home-page "https://gitlab.com/hydren/libgeramun") + (license license:gpl2+)))) + (define-public ode (package (name "ode") diff --git a/gnu/packages/patches/libgeramun-Add-Makefile.patch b/gnu/packages/patches/libgeramun-Add-Makefile.patch new file mode 100644 index 0000000000..01a94d6422 --- /dev/null +++ b/gnu/packages/patches/libgeramun-Add-Makefile.patch @@ -0,0 +1,79 @@ +From ac239d7be2755dc28fa831ba15a0fb318848a5a6 Mon Sep 17 00:00:00 2001 +From: AwesomeAdam54321 +Date: Sun, 12 Mar 2023 01:30:46 +0800 +Subject: [PATCH] libgeramun: Add Makefile. + +Adapted from https://gitlab.com/hydren/terrarium/-/raw/master/build/linux-gcc-sdl2-release/src_libs/libgeramun/subdir.mk +--- + Makefile | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 59 insertions(+) + create mode 100644 Makefile + +diff --git a/Makefile b/Makefile +new file mode 100644 +index 0000000..8d37ce4 +--- /dev/null ++++ b/Makefile +@@ -0,0 +1,59 @@ ++################################################################################ ++# Automatically-generated file. Do not edit! ++################################################################################ ++ ++# Add inputs and outputs from these tool invocations to the build variables ++CPP_SRCS += \ ++brush.cpp \ ++cave.cpp \ ++debug.cpp \ ++generators.cpp \ ++midpoint_displacement.cpp \ ++miners.cpp \ ++preview_callback.cpp \ ++random_walk.cpp \ ++spring.cpp \ ++surf_replacer.cpp ++ ++OBJS += \ ++brush.so \ ++cave.so \ ++debug.so \ ++generators.so \ ++midpoint_displacement.so \ ++miners.so \ ++preview_callback.so \ ++random_walk.so \ ++spring.so \ ++surf_replacer.so ++ ++SRCDIR ?= . ++INCLUDE_PATH ?= ${SRCDIR}/include ++PREFIX ?= /usr/local ++ ++all: libgeramun.so ++ ++libgeramun.so: $(OBJS) $(USER_OBJS) ++ @echo 'Building target: $@' ++ @echo 'Invoking: GCC C++ Linker' ++ g++ -shared -o "libgeramun.so" $(OBJS) $(USER_OBJS) $(LIBS) ++ @echo 'Finished building target: $@' ++ @echo ' ' ++ ++install: all ++ install -d $(DESTDIR)$(PREFIX) ++ cp -r include $(DESTDIR)$(PREFIX) ++ install -d $(DESTDIR)$(PREFIX)/lib ++ install -m 644 libgeramun.so $(DESTDIR)$(PREFIX)/lib ++ ++%.so: %.cpp ++ @echo 'Building file: $<' ++ @echo 'Invoking: GCC C++ Compiler' ++ g++ -I${INCLUDE_PATH} -O3 -Wall -shared -fPIC -c -fmessage-length=0 -MMD -MP -MF"$(@:%.o=%.d)" -MT"$(@)" -o "$@" "$<" ++ @echo 'Finished building: $<' ++ @echo ' ' ++ ++clean: ++ rm $(wildcard *.so) ++ ++ +-- +2.39.2 +