From patchwork Fri Jan 7 07:39:05 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Felix Gruber X-Patchwork-Id: 36066 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 7594527BBEA; Fri, 7 Jan 2022 07:41:24 +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=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL, 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 B0B9D27BBE9 for ; Fri, 7 Jan 2022 07:41:23 +0000 (GMT) Received: from localhost ([::1]:51858 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n5jsH-0007m7-IX for patchwork@mira.cbaines.net; Fri, 07 Jan 2022 02:41:22 -0500 Received: from eggs.gnu.org ([209.51.188.92]:32940) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n5jr0-0007l2-BV for guix-patches@gnu.org; Fri, 07 Jan 2022 02:40:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:50016) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n5jr0-00009g-00 for guix-patches@gnu.org; Fri, 07 Jan 2022 02:40:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n5jqz-00070q-OA for guix-patches@gnu.org; Fri, 07 Jan 2022 02:40:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#53065] [PATCH] gnu: dealii: Update to 9.3.2. Resent-From: Felix Gruber Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 07 Jan 2022 07:40:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 53065 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 53065@debbugs.gnu.org Cc: Felix Gruber X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.164154118326896 (code B ref -1); Fri, 07 Jan 2022 07:40:01 +0000 Received: (at submit) by debbugs.gnu.org; 7 Jan 2022 07:39:43 +0000 Received: from localhost ([127.0.0.1]:42919 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5jqZ-0006zL-Gm for submit@debbugs.gnu.org; Fri, 07 Jan 2022 02:39:43 -0500 Received: from lists.gnu.org ([209.51.188.17]:52712) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5jqP-0006yl-Ml for submit@debbugs.gnu.org; Fri, 07 Jan 2022 02:39:33 -0500 Received: from eggs.gnu.org ([209.51.188.92]:32836) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n5jqO-0007Dt-DX for guix-patches@gnu.org; Fri, 07 Jan 2022 02:39:25 -0500 Received: from mout01.posteo.de ([185.67.36.65]:56075) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n5jqL-0008Tz-P1 for guix-patches@gnu.org; Fri, 07 Jan 2022 02:39:24 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 0789E240028 for ; Fri, 7 Jan 2022 08:39:16 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641541157; bh=6VtN2tNBdZky+dFUp8EDAx8jWo34Fuy6lRCPfF2rroI=; h=From:To:Cc:Subject:Date:From; b=Sh80tkTkoxhAnbtRpZYVUzZRm0Dz2Ex1wUS6U+MnzUcmzmdLh4VM9XLO0koIlsPo+ zNUszKyE5ANFL6+JtREOVnbNIAxN+sXP0sadY1PI602mUx97UKjfHG9R+2T1Ho+JYr G9FIBLrXjWvgRui833zWaNHurELH90aR5uuqqLxnVJ8b7FWOKM2HeLWTQfCmVao63N 3tYfGWfeDWDG2WIG4ZjlVGWEk1SW4mIOgSzYyJaRCUFscuyGi3NZ+rCPIUPRTfG5fe WRgjccthyQ8WnDUCicQ888q4orfUIWoejQkb4nzPrRgmUIjl6sFxlsznoQQ5NykbgR T4MZ4oymJUcmw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JVZq830Ndz9rxL; Fri, 7 Jan 2022 08:39:16 +0100 (CET) From: Felix Gruber Date: Fri, 7 Jan 2022 07:39:05 +0000 Message-Id: <20220107073905.35503-1-felgru@posteo.net> MIME-Version: 1.0 Received-SPF: pass client-ip=185.67.36.65; envelope-from=felgru@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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_MED=-2.3, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=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" X-getmail-retrieved-from-mailbox: Patches * gnu/packages/maths.scm (dealii): Update to 9.3.2. [source]: Add dealii-fix-compiliation-with-boost-1.78.patch and dealii-fix-sundials.patch. [inputs]: Use simplified format. [native-inputs]: Use simplified format. * gnu/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch: New file. * gnu/packages/patches/dealii-fix-sundials.patch: New file. * gnu/local.mk: Add new patch files. --- gnu/local.mk | 4 +- gnu/packages/maths.scm | 24 ++++---- ...lii-fix-compiliation-with-boost-1.78.patch | 40 +++++++++++++ .../patches/dealii-fix-sundials.patch | 60 +++++++++++++++++++ 4 files changed, 115 insertions(+), 13 deletions(-) create mode 100644 gnu/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch create mode 100644 gnu/packages/patches/dealii-fix-sundials.patch diff --git a/gnu/local.mk b/gnu/local.mk index 31354e413f..be5268b9e8 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -31,7 +31,7 @@ # Copyright © 2020 R Veera Kumar # Copyright © 2020 Nicolò Balzarotti # Copyright © 2020 Michael Rohleder -# Copyright © 2020, 2021 Felix Gruber +# Copyright © 2020, 2021, 2022 Felix Gruber # Copyright © 2020 Ryan Prior # Copyright © 2020 Jan Wielkiewicz # Copyright © 2020, 2021 Brice Waegeneire @@ -987,6 +987,8 @@ dist_patch_DATA = \ %D%/packages/patches/dbus-c++-gcc-compat.patch \ %D%/packages/patches/dbus-c++-threading-mutex.patch \ %D%/packages/patches/dbxfs-remove-sentry-sdk.patch \ + %D%/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch \ + %D%/packages/patches/dealii-fix-sundials.patch \ %D%/packages/patches/debops-constants-for-external-program-names.patch \ %D%/packages/patches/debops-debops-defaults-fall-back-to-less.patch \ %D%/packages/patches/dee-vapi.patch \ diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index b0944f307b..f4dba92c11 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -34,7 +34,7 @@ ;;; Copyright © 2019 Steve Sprang ;;; Copyright © 2019 Robert Smith ;;; Copyright © 2020 Jakub Kądziołka -;;; Copyright © 2020, 2021 Felix Gruber +;;; Copyright © 2020–2022 Felix Gruber ;;; Copyright © 2020 R Veera Kumar ;;; Copyright © 2020 Vincent Legoll ;;; Copyright © 2020 Nicolò Balzarotti @@ -5268,14 +5268,16 @@ A unique design feature of Trilinos is its focus on packages.") (define-public dealii (package (name "dealii") - (version "9.3.1") + (version "9.3.2") (source (origin (method url-fetch) (uri (string-append "https://github.com/dealii/dealii/releases/" "download/v" version "/dealii-" version ".tar.gz")) (sha256 - (base32 "1f0sqvlxvl0myqcn0q6xrn1vnp5pgx143lai4a4jkh1dmdv4cbx6")) + (base32 "1s0kawnljg24jj6nibwrif5gxdgg2daqfylhqqpl1lvmzmmxfhak")) + (patches (search-patches "dealii-fix-compiliation-with-boost-1.78.patch" + "dealii-fix-sundials.patch")) (modules '((guix build utils))) (snippet '(begin @@ -5286,16 +5288,14 @@ A unique design feature of Trilinos is its focus on packages.") (outputs '("out" "doc")) (native-inputs ;; Required to build the documentation. - `(("dot" ,graphviz) - ("doxygen" ,doxygen) - ("perl" ,perl))) + (list graphviz doxygen perl)) (inputs - `(("arpack" ,arpack-ng) - ("blas" ,openblas) - ("gfortran" ,gfortran) - ("lapack" ,lapack) - ("muparser" ,muparser) - ("zlib" ,zlib))) + (list arpack-ng + openblas + gfortran + lapack + muparser + zlib)) (propagated-inputs ;; Some scripts are installed into share/deal.II/scripts that require ;; perl and python, but they are not executable (and some are missing the diff --git a/gnu/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch b/gnu/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch new file mode 100644 index 0000000000..1937aa9afc --- /dev/null +++ b/gnu/packages/patches/dealii-fix-compiliation-with-boost-1.78.patch @@ -0,0 +1,40 @@ +From cbef761731627cece2a6f0276b87dacabbdc8a72 Mon Sep 17 00:00:00 2001 +From: David Wells +Date: Tue, 4 Jan 2022 12:46:30 -0500 +Subject: [PATCH] Fix compilation with boost 1.78. + +I bisected (fortunately Boost.Geometry a header-only library so adding the +include directory sufficed) and +https://github.com/boostorg/geometry/commit/6eb9e238bcb37e26dc31d16acf826784a2ba30f4 +is where this problem starts for us. See also +https://github.com/boostorg/geometry/issues/792 - the easiest fix for all such +issues is to just include the project header `boost/geometry/geometry.hpp`. + +In this particular case, if you look at the commit which causes grid_tools.cc +fails to compile, its because we were relying on some implicit includes. In +particular, we need the distance header to find the distance between points and +boxes, but that was previously included in another file. + +This patch has been adapted from +e0e76835519d122fd12b5858e16d08641a641c6a to apply to dealii 9.3.2. + +See https://github.com/dealii/dealii/pull/13165. +--- + include/deal.II/numerics/rtree.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/include/deal.II/numerics/rtree.h b/include/deal.II/numerics/rtree.h +index 1b9d04dacd..1e1bfd2932 100644 +--- a/include/deal.II/numerics/rtree.h ++++ b/include/deal.II/numerics/rtree.h +@@ -26,6 +26,7 @@ + #include + + DEAL_II_DISABLE_EXTRA_DIAGNOSTICS ++#include + #include + #include + DEAL_II_ENABLE_EXTRA_DIAGNOSTICS +-- +2.30.2 + diff --git a/gnu/packages/patches/dealii-fix-sundials.patch b/gnu/packages/patches/dealii-fix-sundials.patch new file mode 100644 index 0000000000..7dd5df45da --- /dev/null +++ b/gnu/packages/patches/dealii-fix-sundials.patch @@ -0,0 +1,60 @@ +From af73f368f7f9d4a00df075d1a9f50fc495f8e87a Mon Sep 17 00:00:00 2001 +From: Timo Heister +Date: Sat, 25 Dec 2021 12:30:45 -0500 +Subject: [PATCH] fix sundials compilation + +--- + include/deal.II/sundials/n_vector.templates.h | 11 ++++++----- + 1 file changed, 6 insertions(+), 5 deletions(-) + +diff --git a/include/deal.II/sundials/n_vector.templates.h b/include/deal.II/sundials/n_vector.templates.h +index 2b49e3efc9..746f63a03b 100644 +--- a/include/deal.II/sundials/n_vector.templates.h ++++ b/include/deal.II/sundials/n_vector.templates.h +@@ -253,13 +253,13 @@ namespace SUNDIALS + template < + typename VectorType, + typename std::enable_if_t::value, int> = 0> +- MPI_Comm ++ const MPI_Comm & + get_communicator(N_Vector v); + + template < + typename VectorType, + typename std::enable_if_t::value, int> = 0> +- MPI_Comm ++ const MPI_Comm & + get_communicator(N_Vector v); + + /** +@@ -481,7 +481,7 @@ SUNDIALS::internal::NVectorOperations::destroy(N_Vector v) + + template ::value, int>> +-MPI_Comm ++const MPI_Comm & + SUNDIALS::internal::NVectorOperations::get_communicator(N_Vector v) + { + return unwrap_nvector_const(v)->block(0).get_mpi_communicator(); +@@ -491,7 +491,7 @@ SUNDIALS::internal::NVectorOperations::get_communicator(N_Vector v) + + template ::value, int>> +-MPI_Comm ++const MPI_Comm & + SUNDIALS::internal::NVectorOperations::get_communicator(N_Vector v) + { + return unwrap_nvector_const(v)->get_mpi_communicator(); +@@ -519,7 +519,8 @@ SUNDIALS::internal::NVectorOperations::get_communicator_as_void_ptr(N_Vector v) + (void)v; + return nullptr; + # else +- return get_communicator(v); ++ // We need to cast away const here, as SUNDIALS demands a pure `void *`. ++ return &(const_cast(get_communicator(v))); + # endif + } + +-- +2.30.2 +