From patchwork Sat May 18 06:22:55 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andy Tai X-Patchwork-Id: 64539 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 89FA727BBEA; Sat, 18 May 2024 07:25:35 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,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 2FC4927BBE2 for ; Sat, 18 May 2024 07:25:34 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s8DVQ-0004b6-Df; Sat, 18 May 2024 02:25:20 -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 1s8DV5-0004Zn-SM for guix-patches@gnu.org; Sat, 18 May 2024 02:25:05 -0400 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 1s8DV5-0003JN-ET for guix-patches@gnu.org; Sat, 18 May 2024 02:24:59 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s8DV8-0003Cu-Ln for guix-patches@gnu.org; Sat, 18 May 2024 02:25:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50054] [PATCH v3 1/3] gnu: Add bx Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 18 May 2024 06:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50054 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50054@debbugs.gnu.org, ludo@gnu.org Cc: Andy Tai Received: via spool by 50054-submit@debbugs.gnu.org id=B50054.171601345612279 (code B ref 50054); Sat, 18 May 2024 06:25:02 +0000 Received: (at 50054) by debbugs.gnu.org; 18 May 2024 06:24:16 +0000 Received: from localhost ([127.0.0.1]:59528 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUO-0003By-0Z for submit@debbugs.gnu.org; Sat, 18 May 2024 02:24:16 -0400 Received: from mail-pl1-f175.google.com ([209.85.214.175]:43073) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUJ-0003BU-6V for 50054@debbugs.gnu.org; Sat, 18 May 2024 02:24:12 -0400 Received: by mail-pl1-f175.google.com with SMTP id d9443c01a7336-1ecd9a81966so8985175ad.0 for <50054@debbugs.gnu.org>; Fri, 17 May 2024 23:24:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716013382; x=1716618182; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=kC3YUL3e2vE6b3u+3T06gxqMh5F8mgrT5xHDDDjkzWY=; b=WVICQ0UBRze845d1IO9ujr4tQn6URBv8QZB5WuVV0ciMUCLDNaMYfca5O5t/5PWFnh +wLLLAZTjYr5kv8BQWmSzrZFtFj7xbtHCF+3/w4dKi+BYHxDLESCHabAwLkByoh6japz ST/PVBgIO0NwgrWw8u2p7/47V1LLMw6AycOJiPsQFC+Lwtg7VdatACXN1zLuFN6L2cyh yG0WI0bTq5G0oObhhsTaMmEx7CbUMcHAgeuTsj78yx6ULyQ4DZS0TmBonK2sHzfl6x1k WIwpLCFKRBHOw3CU358k2V34bAcCCSQR+fX4EhrBD0LOu3mxwMszEfIc5FJJsGyQ3Gxf JvVg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716013382; x=1716618182; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=kC3YUL3e2vE6b3u+3T06gxqMh5F8mgrT5xHDDDjkzWY=; b=lUiQY6j/U+qOmZke+E7jhlkfbHyKmXIdqHyvF0UZW3efsbjTffBEOL5jx9SDjpo6To f0jt4QUtx8gP6a8jD1dzEtl7D36rcJZp33ZKPuYuDIU6l/hWC8nKjza8IcRuc7A+d5Vp K5i2+ranJH4NF9IIT2Q4k8vo7BjS2d/TsMyzOloW+nhMD6nX1bCukakpRVi9z7fr5AVq ZobowlXzCdPb+FAKgYkKmCukmpRfyJpWcwpzaUD+Zv0H+nSXRvFmEDxGuFNQNsyJvA47 pHK4NlICXaYXNSadt9dZx785lYD0xJpLyGa1UJhfB+L3PqqrdiPdGwewiT9nkxed0ugc NMCg== X-Gm-Message-State: AOJu0YwdHKCt5VJCJ3lqDSAj0JreDI+WFSI5UNMKKBq6JOA5skreJhnQ FV10JoKq4Lbp8X9iJZzkCOx+29aCnzuERSx3T1KoBpzg1M+g2xOOM0RI9w== X-Google-Smtp-Source: AGHT+IHmjrlDYABjoh6OZNPn//RzBVAZjZRVCiZvOvxRi9Mg++YR93e49fOByyrI0EFkZ6ZAzF/5pA== X-Received: by 2002:a17:902:e549:b0:1f0:9667:23c9 with SMTP id d9443c01a7336-1f2ed293878mr16477905ad.20.1716013381698; Fri, 17 May 2024 23:23:01 -0700 (PDT) Received: from DEskMiniX300.. (c-98-37-226-154.hsd1.ca.comcast.net. [98.37.226.154]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1ef0c037550sm166878095ad.225.2024.05.17.23.23.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 23:23:01 -0700 (PDT) From: Andy Tai Date: Fri, 17 May 2024 23:22:55 -0700 Message-Id: <1549891c1d8d81ca71bc5d959d4c41429943531a.1716013164.git.atai@atai.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 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: , 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 * gnu/packages/graphics.scm (bx): New variable Change-Id: I7a0b4ccfb2e7a1edad80da0ba55fa5cd0fca0032 --- gnu/packages/graphics.scm | 65 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 64 insertions(+), 1 deletion(-) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 7a2f827d36..5522fffcc8 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -24,7 +24,7 @@ ;;; Copyright © 2020, 2021, 2022, 2023 Maxim Cournoyer ;;; Copyright © 2020 Gabriel Arazas ;;; Copyright © 2021 Antoine Côté -;;; Copyright © 2021 Andy Tai +;;; Copyright © 2021, 2024 Andy Tai ;;; Copyright © 2021 Ekaitz Zarraga ;;; Copyright © 2021, 2022 Vinicius Monego ;;; Copyright © 2022 Michael Rohleder @@ -2960,6 +2960,69 @@ (define-public f3d options.") (license license:bsd-3))) +(define-public bx + (let ((commit "d3434707384f6d62229a4476b10b6dc22fee7c9a") + (revision "1")) + (package + (name "bx") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/bkaradzic/bx") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "11jii8dfb0nzxamkffa6ij3p6r4w7csfbxw7wpxsmqhirv5i8rns")))) + (build-system gnu-build-system) + (arguments + (list + #:phases #~(modify-phases %standard-phases + (delete 'configure) + + (replace 'build + (lambda _ + (invoke "make" + "-j" (number->string (parallel-job-count)) + "linux-release64" + (string-append "GENIE=" + #$(this-package-native-input + "genie") "/bin/genie") "-j" + (number->string (parallel-job-count))))) + + (replace 'check + (lambda _ + (invoke "make" "test"))) + (replace 'install + (lambda _ + (install-file + ".build/linux64_gcc/obj/x64/Release/bin2c/tools/bin2c" + (string-append #$output "/bin")) + (install-file + ".build/linux64_gcc/obj/x64/Release/lemon/tools/lemon" + (string-append #$output "/bin")) + (for-each (lambda (f) + (install-file f + (string-append #$output + "/lib"))) + (find-files ".build/linux64_gcc" "\\.a$")) + (copy-recursively "include/bx" + (string-append #$output + "/include/bx"))))))) + (native-inputs (list genie)) + (home-page "https://github.com/bkaradzic/bx") + (synopsis "C++ utility library for the Bgfx graphics library") + (description + "Bx is a C++ library that implements low level functions of the +Bgfx graphics library +@itemize +@item Providing OS/runtime/compiler independent core functionality +to be able to write cross-platform applications. +@item Allowing compile without C Runtime (CRT) and without C++ Standard Library (STL). +@end itemize") + (license license:bsd-2)))) + (define-public gpaint (package (name "gpaint") From patchwork Sat May 18 06:22:56 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Tai X-Patchwork-Id: 64540 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 B67A427BBE9; Sat, 18 May 2024 07:25:46 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS 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 751CD27BBE2 for ; Sat, 18 May 2024 07:25:43 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s8DVd-0004dp-52; Sat, 18 May 2024 02:25:33 -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 1s8DV6-0004Zp-Nj for guix-patches@gnu.org; Sat, 18 May 2024 02:25:05 -0400 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 1s8DV5-0003JU-Rv for guix-patches@gnu.org; Sat, 18 May 2024 02:24:59 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s8DV9-0003D1-2Y for guix-patches@gnu.org; Sat, 18 May 2024 02:25:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50054] [PATCH v3 2/3] gnu: Add bimg. Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 18 May 2024 06:25:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50054 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50054@debbugs.gnu.org, ludo@gnu.org Cc: Andy Tai Received: via spool by 50054-submit@debbugs.gnu.org id=B50054.171601345612286 (code B ref 50054); Sat, 18 May 2024 06:25:03 +0000 Received: (at 50054) by debbugs.gnu.org; 18 May 2024 06:24:16 +0000 Received: from localhost ([127.0.0.1]:59530 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUO-0003C0-Ej for submit@debbugs.gnu.org; Sat, 18 May 2024 02:24:16 -0400 Received: from mail-pl1-f175.google.com ([209.85.214.175]:46163) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUJ-0003BV-Sn for 50054@debbugs.gnu.org; Sat, 18 May 2024 02:24:12 -0400 Received: by mail-pl1-f175.google.com with SMTP id d9443c01a7336-1ed96772f92so28840535ad.0 for <50054@debbugs.gnu.org>; Fri, 17 May 2024 23:24:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716013382; x=1716618182; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=RVxC6+XszcM9yt+TPYTHkZ51xlPUVVYv4or15fC9qOw=; b=UA8me6PmrvQVQ7I5p1a3PgLQnuuK/Smx1GjGEllJzRrtGOLJl4dl76j/fK7qVGVylb a5NHM/z7Y8OoTDG7i5fpYHrP7v9qvtA00ZQPrh8QZQKaeyB2FFdjSlG5Mq1jwp4zUfHf fvphdvLFF3ewAfZMNRIwDoNmYzkPQdoFyGa0AL25kvsu5h3HF3n4KY9/LJaPbRL2H2k8 erYq+bLj14fQVEks2ys7vXK8R8PYJDh20anlFwvae2cHaTn0K0/DSIu5O2d3H0J0sdkf hJqvDDDI2NwpAaSfHzk0ymJmaNSbiT5piWkrbOt3xJJLuCZggfQGuVXeQECzlRB87KEc sCVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716013382; x=1716618182; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=RVxC6+XszcM9yt+TPYTHkZ51xlPUVVYv4or15fC9qOw=; b=KqFcg/bTx73vfRQHjKf+CuZjkB72Wfyl70NxFJvuU/yKYMQrRGj/+86fdbw4xQtCbP JtF3InAGIvcQl25pVh+f79VlB0oE1RwzzFj3HVab/WOV8G4Mcne2YTpvZMRbrtR0rGz1 pU1BQg0NGLbtx0dcvvIP2SStoaW8OA+GcIjq3ArxGocGEcC5xgAaHgRn72vwavBbSf0h dD/Ql8BXBV4/kG/a8R6qIzdIQREGqg7i3ALbDxbYlBomaRQAFAkzxSyaX77FQzkzaaJu oJNYgjlIue6G785vHZlFwazuH+9TGp+V+Ejwgpw9Jy6c58QT42EWkABTJ3ofkLoOZQS1 EtDw== X-Gm-Message-State: AOJu0YyMW7wKPSvozGW0SMG9/OhA9Qr963iHbRoRZVasCIU1PLA3qOxe zqTv7A3YMTzqledZWZ3Zx3L0GUZRmldL1NH8ck0vLYMsATkMrjqD/ver5Q== X-Google-Smtp-Source: AGHT+IEdqLS7QbQEdJUgbp7z9uqoTfNf8F5gnA7iamcflJVX11149sdTEgrqBzJVe1XxChI9vVzB2Q== X-Received: by 2002:a17:903:41c4:b0:1eb:50fd:7875 with SMTP id d9443c01a7336-1ef43e2323cmr295204915ad.33.1716013382466; Fri, 17 May 2024 23:23:02 -0700 (PDT) Received: from DEskMiniX300.. (c-98-37-226-154.hsd1.ca.comcast.net. [98.37.226.154]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1ef0c037550sm166878095ad.225.2024.05.17.23.23.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 23:23:02 -0700 (PDT) From: Andy Tai Date: Fri, 17 May 2024 23:22:56 -0700 Message-Id: <12d7e386afb210164584706990f5cd981a1b88f5.1716013164.git.atai@atai.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 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: , 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 * gnu/packages/graphics.scm (bimg): New variable. Change-Id: I431bed18c6a63d8b6c073177c01816fd32e005f4 --- gnu/packages/graphics.scm | 66 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 5522fffcc8..678e916b7c 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -3023,6 +3023,72 @@ (define-public bx @end itemize") (license license:bsd-2)))) +(define-public bimg + (let ((commit "e9fa0ceff2df3399011af136c82652c81655c1d3") + (revision "1")) + (package + (name "bimg") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/bkaradzic/bimg") + (commit commit))) + (file-name (git-file-name name version)) + (modules '((guix build utils))) + (sha256 + (base32 "0i80r5hwbnh94wfmv4dys6kmy7szvmpqynbb7bvvvhfjn13jh754")))) + (build-system gnu-build-system) + (arguments + (list + #:tests? #f ;there are no tests + #:phases #~(modify-phases %standard-phases + (delete 'configure) + + (replace 'build + (lambda _ + (for-each (lambda (target) + (invoke "make" + "-j" + (number->string (parallel-job-count)) + target + + (string-append "BX_DIR=" + #$(this-package-input + "bx-sources")) + (string-append "NINJA=" + #$(this-package-native-input + "ninja") + "/bin/ninja") + (string-append "GENIE=" + #$(this-package-native-input + "genie") + "/bin/genie"))) + (list "linux-release64" "tools")))) + + (replace 'install + (lambda _ + (install-file + ".build/linux64_gcc/obj/x64/Release/texturec/tools/texturec" + (string-append #$output "/bin")) + (for-each (lambda (f) + (install-file f + (string-append #$output + "/lib"))) + (find-files ".build/linux64_gcc" "\\.a$")) + (copy-recursively "include/bimg" + (string-append #$output + "/include/bimg"))))))) + (native-inputs (list genie ninja)) + (inputs `(("bx-sources" ,(package-source bx)))) + (home-page "https://github.com/bkaradzic/bimg") + (synopsis "Image library") + (description + "Bimg is an imaging library that implements low level functions of the +Bgfx graphics library.") + (license license:bsd-2)))) + (define-public gpaint (package (name "gpaint") From patchwork Sat May 18 06:22:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Tai X-Patchwork-Id: 64541 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 312BA27BBE2; Sat, 18 May 2024 07:26:05 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED,URIBL_SBL_A 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 2E39227BBEB for ; Sat, 18 May 2024 07:26:01 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s8DVa-0004cx-Ny; Sat, 18 May 2024 02:25:30 -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 1s8DV6-0004Zr-Nu for guix-patches@gnu.org; Sat, 18 May 2024 02:25:05 -0400 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 1s8DV6-0003JW-Ac for guix-patches@gnu.org; Sat, 18 May 2024 02:25:00 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s8DV9-0003D8-Ht for guix-patches@gnu.org; Sat, 18 May 2024 02:25:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50054] [PATCH v3 3/3] gnu: Add bgfx. Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 18 May 2024 06:25:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50054 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 50054@debbugs.gnu.org, ludo@gnu.org Cc: Andy Tai Received: via spool by 50054-submit@debbugs.gnu.org id=B50054.171601345712292 (code B ref 50054); Sat, 18 May 2024 06:25:03 +0000 Received: (at 50054) by debbugs.gnu.org; 18 May 2024 06:24:17 +0000 Received: from localhost ([127.0.0.1]:59532 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUO-0003C7-R3 for submit@debbugs.gnu.org; Sat, 18 May 2024 02:24:17 -0400 Received: from mail-pl1-f178.google.com ([209.85.214.178]:59479) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s8DUL-0003BW-8w for 50054@debbugs.gnu.org; Sat, 18 May 2024 02:24:13 -0400 Received: by mail-pl1-f178.google.com with SMTP id d9443c01a7336-1ecddf96313so3350185ad.2 for <50054@debbugs.gnu.org>; Fri, 17 May 2024 23:24:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1716013384; x=1716618184; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=DFLXQKYFBjsUMHmFcMzJ3bxuOH5+0G/R8wApqRi4/3A=; b=AmmgR0AhkyzILDUmXkpHuUJ04MbWP2C/Bcpxjd4KBu7ifksK5AkMIzblO/W5um3Cpj W4NRaj0dEAHkG7WG+EDNMgF0ZaLv0+PfKqCIlMCpCMGtHLXkxKxDdqItBhmBLPiPXS3/ IBLyFLPWUsgMNLRGKtbvPwpkgfMncgS8qg8h30iz1BwwB8ghP2J5f2vX1VJv6zDW1Tyn knifERFSR3n67FGtxBnrROndrc3EfwbFqvnGYNCD1eU1Nq4lnTl0pXrfUQMfIMdtmthR /LAKygCIG1O4wt9Lmpa9VCb9mw7Njm6cwno6hVu7O5a9ToPGV+DOFvd6Wdb/N1A8mbFT Y0PQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716013384; x=1716618184; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=DFLXQKYFBjsUMHmFcMzJ3bxuOH5+0G/R8wApqRi4/3A=; b=YkkkSifM7BGWnK56IVDk+hVcq3xP+CMdzHjRJFwEC2OwrsR340QcHJNAbO4kWPP0wJ CVvf+pm2uENXnkHtZj/GWPlKJiwS6Jr+wjb163mtm/g1yRjOcPg5fcG8Ket6FgCYzPEv EOIk7KUx1qCHuXZnTGcqoUL1AOBXKNoSZFIE0Ge++VaLKN5K7dfsn/531Fd9e1IKnYyq 1yoIPjChgu83bodBOTE23kYEOElo+wx5rW93X7H4GZzaIfHc7Dnzz9Qa7jB+xXbvmHjN MwCXjMf5NbjNUUFUzmtnoXed0Orc825uCIatPZQEi/dvTk6H3Wnmng0kaarLVMvjFqNM 6NnQ== X-Gm-Message-State: AOJu0YzB6kyrq6I4PcTXQ1hHgQJ7T4K8i5K397j3MKC1dhm88BpnwIdK 3Yo/WiSOLeAU7uRTWqLqwtm65S9ZKBRwpYJZf+B3cMt8EG83o9nt2e7r+g== X-Google-Smtp-Source: AGHT+IGLX4HexNioT4jvC+H8LOolIYzYozW+5BnGhTx4QDPh/4NS0Qyof+ow6LubxDFnfM2km7yCuA== X-Received: by 2002:a17:902:d2c8:b0:1f2:e644:d94 with SMTP id d9443c01a7336-1f2e64412aemr40026255ad.61.1716013383956; Fri, 17 May 2024 23:23:03 -0700 (PDT) Received: from DEskMiniX300.. (c-98-37-226-154.hsd1.ca.comcast.net. [98.37.226.154]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-1ef0c037550sm166878095ad.225.2024.05.17.23.23.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 May 2024 23:23:02 -0700 (PDT) From: Andy Tai Date: Fri, 17 May 2024 23:22:57 -0700 Message-Id: <5d8f9510b491338aa503504065db36291f831b90.1716013164.git.atai@atai.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 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: , 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 * gnu/packages/graphics.scm (bgfx): New variable. Change-Id: I2737803c838229ed04fbfe30d0e67749444d871b --- gnu/packages/graphics.scm | 90 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 90 insertions(+) diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 678e916b7c..ec1b490819 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -3089,6 +3089,96 @@ (define-public bimg Bgfx graphics library.") (license license:bsd-2)))) +(define-public bgfx + (let ((commit "932302d8f460e514b933deba8c0e575a00f0bcd6") + (revision "1")) + (package + (name "bgfx") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/bkaradzic/bgfx") + (commit commit))) + (file-name (git-file-name name version)) + (modules '((guix build utils))) + (sha256 + (base32 "0by2is3qzbhg0m3wv7np28l6k9hm0lr5ybc2z7fc5c8x3afqcxzr")))) + (build-system gnu-build-system) + (arguments + (list + #:tests? #f ;there are no tests + #:phases #~(modify-phases %standard-phases + (delete 'configure) + + (replace 'build + (lambda _ + (for-each (lambda (target) + (invoke "make" + "-j" + (number->string (parallel-job-count)) + target + + (string-append "BX_DIR=" + #$(package-source bx)) + (string-append "BIMG_DIR=" + #$(package-source bimg)) + (string-append "NINJA=" + #$(this-package-native-input + "ninja") + "/bin/ninja") + (string-append "GENIE=" + #$(this-package-native-input + "genie") + "/bin/genie"))) + (list "linux-release64" "tools")))) + ;; (replace 'check + ;; (lambda _ + ;; (invoke "make" "test"))) + (replace 'install + (lambda _ + (for-each (lambda (f) + (install-file f + (string-append #$output + "/bin"))) + (find-files "./tools/bin/linux")) + (for-each (lambda (f) + (install-file f + (string-append #$output + "/lib"))) + (find-files ".build/linux64_gcc" "\\.a$")) + (for-each (lambda (f) + (install-file f + (string-append #$output + "/lib"))) + (find-files ".build/linux64_gcc" "\\.so$")) + (copy-recursively "include/bgfx" + (string-append #$output + "/include/bgfx"))))))) + (native-inputs (list genie ninja)) + (inputs (list mesa mesa-headers vulkan-headers)) + (home-page "https://bkaradzic.github.io/bgfx/overview.html") + (synopsis "Cross-platform, graphics API agnostic, +\"Bring Your Own Framework\" rendering library") + (description + "bgfx is a Cross-platform, graphics API agnostic rendering library +providing the same graphics APIs over +@itemize +@item Direct3D 11 +@item Direct3D 12 +@item GNM (only for licensed PS4 developers, search DevNet forums for source) +@item Metal +@item OpenGL 2.1 +@item OpenGL 3.1+ +@item OpenGL ES 2 +@item OpenGL ES 3.1 +@item Vulkan +@item WebGL 1.0 +@item WebGL 2.0 +@end itemize") + (license license:bsd-2)))) + (define-public gpaint (package (name "gpaint")