From patchwork Mon Jun 6 11:01:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Paul A. Patience" X-Patchwork-Id: 39757 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 B85C427BBEA; Mon, 6 Jun 2022 12:03:38 +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=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 7F9DC27BBE9 for ; Mon, 6 Jun 2022 12:03:38 +0100 (BST) Received: from localhost ([::1]:43360 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nyAWH-0004Pa-MD for patchwork@mira.cbaines.net; Mon, 06 Jun 2022 07:03:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60894) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nyAUk-0003Qh-Ae for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40599) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nyAUk-0003jv-1f for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nyAUj-0001KW-Th for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#55819] [PATCH 1/2] gnu: vtk: Enable the RenderingExternal module. References: <20220606105824.901227-1-paul@apatience.com> In-Reply-To: <20220606105824.901227-1-paul@apatience.com> Resent-From: "Paul A. Patience" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 06 Jun 2022 11:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55819 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 55819@debbugs.gnu.org Cc: "Paul A. Patience" Received: via spool by 55819-submit@debbugs.gnu.org id=B55819.16545133085069 (code B ref 55819); Mon, 06 Jun 2022 11:02:01 +0000 Received: (at 55819) by debbugs.gnu.org; 6 Jun 2022 11:01:48 +0000 Received: from localhost ([127.0.0.1]:34492 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyAUW-0001Jh-Jq for submit@debbugs.gnu.org; Mon, 06 Jun 2022 07:01:48 -0400 Received: from mail-4018.proton.ch ([185.70.40.18]:21197) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyAUU-0001JL-Li for 55819@debbugs.gnu.org; Mon, 06 Jun 2022 07:01:47 -0400 Date: Mon, 06 Jun 2022 11:01:33 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apatience.com; s=protonmail2; t=1654513300; x=1654772500; bh=f28eHoa7ysYGpwNTDFi1Jjfj+Pyrtf0QckG6BOFntTQ=; h=Date:To:From:Cc:Reply-To:Subject:Message-ID:Feedback-ID:From:To: Cc:Date:Subject:Reply-To:Feedback-ID:Message-ID; b=PJkAxOApJUv5YG72MUouEFL+eXKQQD5Bob8qvBV1xv3LieXIH78zF4O9/1yb6EIJC sGyn5fh7+mquIowHJLwRdmNVQJCzxuN/eKFlJd/+fxRAhox9E5H9kNFoAIo3x91pZ7 BYLex9QLOgih0R9Rxqbq0smtdmwgR992Y4lggcsiBXDLfGQVGQ7AYeTw3V5utkxr7s bEhMor8QXl95ROpTLqNp/n8qUXIayyZhHx7Bx8WTevx6EqYgu7XJVZJRoAqIfVzU36 n/lPYoYfeFePRN5fb28IVst9ypZUkjQrozt+gM5kSqc8tqLBPQAH8VrEqKXWW1Guq6 KX0FyRg3lfG6w== From: "Paul A. Patience" Message-ID: <20220606110125.902061-1-paul@apatience.com> Feedback-ID: 19227857:user:proton 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: , Reply-To: "Paul A. Patience" Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/image-processing.scm (vtk)[arguments]<#:configure-flags>: Add -DVTK_MODULE_ENABLE_VTK_RenderingExternal=YES. --- gnu/packages/image-processing.scm | 1 + 1 file changed, 1 insertion(+) -- 2.36.0 diff --git a/gnu/packages/image-processing.scm b/gnu/packages/image-processing.scm index f4bf1724b4..249f916489 100644 --- a/gnu/packages/image-processing.scm +++ b/gnu/packages/image-processing.scm @@ -360,6 +360,7 @@ (define-public vtk "-DVTK_MODULE_USE_EXTERNAL_VTK_theora=ON" "-DVTK_MODULE_USE_EXTERNAL_VTK_tiff=ON" "-DVTK_MODULE_USE_EXTERNAL_VTK_zlib=ON" + "-DVTK_MODULE_ENABLE_VTK_RenderingExternal=YES" ; For F3D "-DVTK_WRAP_PYTHON=ON" "-DVTK_PYTHON_VERSION:STRING=3" ) From patchwork Mon Jun 6 11:01:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Paul A. Patience" X-Patchwork-Id: 39758 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 CD58C27BBE9; Mon, 6 Jun 2022 12:10:07 +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=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 ECDF827BBEA for ; Mon, 6 Jun 2022 12:10:06 +0100 (BST) Received: from localhost ([::1]:51520 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nyAcY-0001IN-2p for patchwork@mira.cbaines.net; Mon, 06 Jun 2022 07:10:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60896) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nyAUk-0003RI-QP for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40600) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nyAUk-0003k2-HD for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nyAUk-0001Kd-EC for guix-patches@gnu.org; Mon, 06 Jun 2022 07:02:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#55819] [PATCH 2/2] gnu: Add f3d. Resent-From: "Paul A. Patience" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 06 Jun 2022 11:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 55819 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 55819@debbugs.gnu.org Cc: "Paul A. Patience" Received: via spool by 55819-submit@debbugs.gnu.org id=B55819.16545133195098 (code B ref 55819); Mon, 06 Jun 2022 11:02:02 +0000 Received: (at 55819) by debbugs.gnu.org; 6 Jun 2022 11:01:59 +0000 Received: from localhost ([127.0.0.1]:34496 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyAUc-0001K3-RP for submit@debbugs.gnu.org; Mon, 06 Jun 2022 07:01:59 -0400 Received: from mail-4323.proton.ch ([185.70.43.23]:43301) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nyAUY-0001JQ-Uh for 55819@debbugs.gnu.org; Mon, 06 Jun 2022 07:01:54 -0400 Date: Mon, 06 Jun 2022 11:01:37 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apatience.com; s=protonmail2; t=1654513304; x=1654772504; bh=fj1itBU5906VgMCUAzGchim4GX+/6GGUk7eYieVAVto=; h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To: References:Feedback-ID:From:To:Cc:Date:Subject:Reply-To: Feedback-ID:Message-ID; b=LuGH2W1Kd5zJTPuNaW3rnzpko//8vexGvinq1HoFsh9/JuWJOX6BEset1q+8QD3jV /EtO094m/2ViMNlMUvfMeDyw2h+uZMyxUw/mq5XFxwag/wCO9xyRaMkV2tqrseJRTB GJ6jdgwPeP8kTuKngdTqmtfmkt/xBeFDbcYpFge4g5zoeKQJDYgu8GfI154FT8AqDL EGrVSMNMxIHUb1gZB5PkVP2ywaJIMOXaR0HTKgJtyRHG8TJG8B8i6mFvWI+SvfSXBn FlXIrfL6NniWgJ/oOZpNLH/h5auBW2utWNYdwwCx6DggeD5Ac3VxlVBf5gp8J9pLg5 wJgMdhJTJ6qHg== From: "Paul A. Patience" Message-ID: <20220606110125.902061-2-paul@apatience.com> In-Reply-To: <20220606110125.902061-1-paul@apatience.com> References: <20220606110125.902061-1-paul@apatience.com> Feedback-ID: 19227857:user:proton 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: , Reply-To: "Paul A. Patience" Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/graphics.scm (f3d): New variable. --- gnu/packages/graphics.scm | 111 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 111 insertions(+) -- 2.36.0 diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index 64286bf68d..d850a9cf06 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -30,6 +30,7 @@ ;;; Copyright © 2022 Michael Rohleder ;;; Copyright © 2022 John Kehayias ;;; Copyright © 2022 Zheng Junjie <873216071@qq.com> +;;; Copyright © 2022 Paul A. Patience ;;; ;;; This file is part of GNU Guix. ;;; @@ -2054,3 +2055,113 @@ (define-public monado such as VR and AR on mobile, PC/desktop, and any other device. Monado aims to be a complete and conforming implementation of the OpenXR API made by Khronos.") (license license:boost1.0))) + +(define-public f3d + ;; There have been many improvements since the last tagged version (1.2.1, + ;; released in December 2021), including support for the Alembic file + ;; format. + (let ((commit "d80fd4558f1851a31d13dfbb62d7648b7b2d36f8") + (revision "0")) + (package + (name "f3d") + (version (git-version "1.2.1" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/f3d-app/f3d") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "11lj63rfhqp0zwifl2d3rlp7cfbxgr2jb3j7pqh8lhsr2pa94f6s")))) + (build-system cmake-build-system) + (arguments + (list + ;; Many tests require files supplied by git-lfs. + ;; Also, some tests segfault (after an exception?) but the tested + ;; behavior, i.e., when the program is run manually, does not (for + ;; example, TestNonExistentConfigFile and TestInvalidConfigFile). + ;; Upstream is aware of occasionally flaky tests (see + ;; https://github.com/f3d-app/f3d/issues/92) but the tests run in CI + ;; seem to be passing. + ;; Anyway, the program runs and is able to open at least STL files + ;; without issue. + #:tests? #f + #:configure-flags + #~(list (string-append "-DVTK_DIR=" #$output "/lib") + "-DBUILD_TESTING=OFF" + "-DF3D_MODULE_ALEMBIC=ON" + "-DF3D_MODULE_ASSIMP=ON" + "-DF3D_MODULE_OCCT=ON" + ;; Prefer Guix's versioned documentation directory to F3D's + ;; unversioned one. + (string-append "-DCMAKE_INSTALL_DOCDIR=" #$output + "/share/doc/" #$name "-" #$version)) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'adjust-titles-and-descriptions + (lambda _ + (substitute* '("CMakeLists.txt" + "resources/f3d.desktop.in" + "resources/io.github.f3d_app.f3d.metainfo.xml") + (("A fast and minimalist 3D viewer") + "Fast and minimalistic 3D viewer")) + (substitute* "resources/io.github.f3d_app.f3d.metainfo.xml" + (("it is minimalist,") + "it is minimalistic,") + (("arguments in the command line\\.") + "arguments on the command line.")) + ;; Keep the title bar short. + (substitute* "application/F3DConfig.h.in" + (("AppTitle = \"@PROJECT_DESCRIPTION@\";") + "AppTitle = \"F3D\";")))) + (add-after 'unpack 'fix-typos + (lambda _ + (substitute* '("application/F3DOptionsParser.cxx" + "application/F3DStarter.cxx" + "cmake/testing.cmake" + "library/testing/TestSDKHelpers.h") + (("does not exists") + "does not exist")))) + ;; Skip checking for the relative-to-executable configuration file + ;; (located in ../../argv[0]) when the user configuration file + ;; doesn't exist, because the check fails and prints a warning + ;; message upon each invocation of the program. + ;; Besides, the usefulness of this configuration file is unclear, + ;; because F3D reads /etc/f3d/config.json as a fallback system + ;; configuration file. + (add-after 'unpack 'ignore-binary-config-file-dir + (lambda _ + (substitute* "application/F3DOptionsParser.cxx" + (("^ +filePath = .*->GetBinaryConfigFileDirectory\\(\\) .*") + ""))))))) + (inputs + (list alembic + assimp + double-conversion + eigen + expat + fontconfig + freetype + glew + hdf5 + imath + jsoncpp + libjpeg-turbo + libpng + libtiff + libx11 + lz4 + netcdf + opencascade-occt + vtk + zlib)) + (home-page "https://f3d-app.github.io/f3d/") + (synopsis "Fast and minimalistic 3D viewer") + (description "F3D (pronounced @samp{/fɛd/}) is a VTK-based 3D viewer +following the KISS principle, so it is minimalistic, efficient, has no GUI, +has simple interaction mechanisms and is fully controllable using arguments on +the command line. It supports a range of file formats (including animated +glTF, STL, STEP, PLY, OBJ, FBX), and provides numerous rendering and texturing +options.") + (license license:bsd-3))))