From patchwork Sat Sep 16 16:01:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: dan X-Patchwork-Id: 53962 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 6109A27BBEA; Sat, 16 Sep 2023 17:03:22 +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,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 7510927BBE2 for ; Sat, 16 Sep 2023 17:03:18 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qhXlA-00076S-EL; Sat, 16 Sep 2023 12:03: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 1qhXl1-0006y7-M3 for guix-patches@gnu.org; Sat, 16 Sep 2023 12:02:55 -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 1qhXl1-0000mD-DK for guix-patches@gnu.org; Sat, 16 Sep 2023 12:02:55 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qhXl8-0002Pw-FR for guix-patches@gnu.org; Sat, 16 Sep 2023 12:03:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#66035] [PATCH] gnu: Add renderdoc. Resent-From: dan Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 16 Sep 2023 16:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 66035 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 66035@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16948801289209 (code B ref -1); Sat, 16 Sep 2023 16:03:02 +0000 Received: (at submit) by debbugs.gnu.org; 16 Sep 2023 16:02:08 +0000 Received: from localhost ([127.0.0.1]:48367 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qhXkE-0002OS-VG for submit@debbugs.gnu.org; Sat, 16 Sep 2023 12:02:08 -0400 Received: from lists.gnu.org ([2001:470:142::17]:36816) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qhXk9-0002NE-FI for submit@debbugs.gnu.org; Sat, 16 Sep 2023 12:02: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 1qhXjp-00046o-3H for guix-patches@gnu.org; Sat, 16 Sep 2023 12:01:46 -0400 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qhXjj-0000RV-CB for guix-patches@gnu.org; Sat, 16 Sep 2023 12:01:39 -0400 Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailout.west.internal (Postfix) with ESMTP id 248B2320047A for ; Sat, 16 Sep 2023 12:01:29 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Sat, 16 Sep 2023 12:01:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dan.games; h=cc :content-transfer-encoding:content-type:content-type:date:date :from:from:in-reply-to:message-id:mime-version:reply-to:sender :subject:subject:to:to; s=fm3; t=1694880088; x=1694966488; bh=7W EzjuIfClc+FVELkChWRR+Y/d26b4KsVGTQ37tcSVw=; b=HdlQNdZaeKjN2eFVGm kewbJKOM/1El849IoXvOZx85KCgwhbItCMoxajmenIqBdF1QakLHzTveVK5zV4nd 9wCpJVlrPC5iH+IuHNhftvKkVQfoAbDVgG8+w5WB5jk1ggKhYsqObHAdKI+2zS6W /kyatff31mKjaOYB57+CLHL6/+K5kObg1OGSDNKkRXu4WGVTI3O0xQRQSkXMks2t 6L3gCwPoQP1B+Uz9TQj7w1xtRXltClAvpXYqxvmcveXFX9uuvG6zBdIED2yn6MmK ea0i73PWCF3RkAeZNCorU6lHuayCcrbF0H/XYcRjcVqIIDs8pvrCOyOI+6gvdWkU hccQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:message-id:mime-version:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; t=1694880088; x=1694966488; bh=7WEzjuIfClc+F VELkChWRR+Y/d26b4KsVGTQ37tcSVw=; b=Z0oe9O0v9HhAFZExg9LBRTxktxkuE 690wk3gVxjMc3qp7gl9fJsF/LpPBo12dKGPhx7YJQwkpbyHxppnSKtIPPkYh05Kf w3Ffg4sUaqlZMWJ7Q71c8fwcO6mhITba9RLCVs3tvb8pB3a3u/sfcEemHcdTAwje 04R0l32nQc+9AzBH5vmVyo70wbmp7EnCOFDRLjYqbfvlBUw51b7PeBE624nZSt7g rIZ/gS5O8PvdtLNmMJnzNDqE64G3WPbb0vvhGhDobOS7RAc+tVRsPmjtzhndMCkp mUkyXLR5lYOA1xbVIGUy7hXs0YjuZXZP0Ngu0NXvBqgZhha8dWFzepI6A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedviedrudejgedgleegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofggtgfgsehtkeertd ertdejnecuhfhrohhmpegurghnuceoihesuggrnhdrghgrmhgvsheqnecuggftrfgrthht vghrnhepudefveegheevjeeuueekgeelvddttdejgeeltdehudfgiedtgffhfefgudehve dtnecuffhomhgrihhnpehgnhhurdhorhhgpdhgihhthhhusgdrtghomhdprhgvnhguvghr ughotgdrohhrghenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh hrohhmpehisegurghnrdhgrghmvghs X-ME-Proxy: Feedback-ID: i3b5946ed:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA for ; Sat, 16 Sep 2023 12:01:26 -0400 (EDT) From: dan Date: Sun, 17 Sep 2023 00:01:08 +0800 Message-ID: <20230916160108.31783-1-i@dan.games> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Received-SPF: pass client-ip=64.147.123.21; envelope-from=i@dan.games; helo=wout5-smtp.messagingengine.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-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: , 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 (renderdoc): New variable. --- gnu/packages/graphics.scm | 90 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 89 insertions(+), 1 deletion(-) base-commit: 04fad62acdcffa50c18528ce71f015907b9eb558 diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 9362666274..002d93f75b 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -32,7 +32,7 @@ ;;; Copyright © 2022 Zheng Junjie <873216071@qq.com> ;;; Copyright © 2022 Tobias Kortkamp ;;; Copyright © 2022 Paul A. Patience -;;; Copyright © 2022 dan +;;; Copyright © 2022, 2023 dan ;;; Copyright © 2023 Sharlatan Hellseher ;;; Copyright © 2023 David Thompson ;;; Copyright © 2023 Eric Bavier @@ -101,6 +101,7 @@ (define-module (gnu packages graphics) #:use-module (gnu packages multiprecision) #:use-module (gnu packages ninja) #:use-module (gnu packages pciutils) + #:use-module (gnu packages pcre) #:use-module (gnu packages pdf) #:use-module (gnu packages perl) #:use-module (gnu packages photo) @@ -2851,3 +2852,90 @@ (define-public gpaint It features cut-and-paste for irregular regions or polygons.") (home-page "https://www.gnu.org/software/gpaint/") (license license:gpl3+))) + +(define %swig-for-renderdoc-version + "renderdoc-modified-7") + +(define swig-for-renderdoc + (origin + (method url-fetch) + (uri (string-append "https://github.com/baldurk/swig/archive/refs/tags/" + %swig-for-renderdoc-version ".tar.gz")) + (sha256 (base32 + "19sb4vik8kgy9pxjfam8qc8i52iraj2971p1hrzh850fvl0nibg7")))) + +(define-public renderdoc + (package + (name "renderdoc") + (version "1.28") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/baldurk/renderdoc.git") + (commit (string-append "v" version)))) + (sha256 + (base32 + "1rny39s1b48bgv8x2871ylkzk1f9llvrskb809c6gcawnfazzivb")))) + (build-system cmake-build-system) + (arguments + (list #:tests? #f + #:configure-flags #~(list (string-append "-DVULKAN_LAYER_FOLDER=" + #$output + "/share/vulkan/implicit_layer.d")) + #:phases #~(modify-phases %standard-phases + (add-after 'unpack 'unpack-additional-sources + (lambda* (#:key inputs #:allow-other-keys) + (let ((sh (search-input-file inputs "/bin/sh"))) + (invoke "tar" "xvf" + #$swig-for-renderdoc) + (rename-file (string-append "swig-" + #$%swig-for-renderdoc-version) + "swig") + (substitute* "qrenderdoc/CMakeLists.txt" + (("URL \\$\\{RENDERDOC_SWIG_PACKAGE\\}") + "SOURCE_DIR ${CMAKE_SOURCE_DIR}/swig") + (("CONFIGURE_COMMAND\\s.*") + "CONFIGURE_COMMAND \"\"\n") + (("^\\s+COMMAND CC.*") + "")) + (substitute* "swig/Makefile.in" + (("/bin/sh") + sh)) + (chdir "swig") + (invoke sh "autogen.sh") + (chdir "..")))) + (add-after 'configure 'configure-swig + (lambda* (#:key inputs #:allow-other-keys) + (let ((build-dir (getcwd)) + (sh (search-input-file inputs "/bin/sh"))) + (chdir "../source/swig") + (apply invoke sh "./configure" + (list "CC=gcc" + "CXX=g++" + "CFLAGS=-fPIC" + "CXXFLAGS=-fPIC" + (string-append "SHELL=" sh) + "--with-pcre=yes" + (string-append "--prefix=" + build-dir))) + (chdir "../../build"))))))) + (inputs (list libx11 + libxcb + xcb-util-keysyms + mesa + qtbase-5 + qtsvg-5 + qtx11extras)) + (native-inputs (list autoconf + automake + bison + (list pcre "bin") + pkg-config + python)) + (home-page "https://renderdoc.org") + (synopsis "Graphics debugging tool") + (description + "RenderDoc is a frame-capture based graphics debugger, currently +available for Vulkan, D3D11, D3D12, OpenGL, and OpenGL ES development on +Windows, Linux, Android, and Nintendo Switch™.") + (license license:expat)))