From patchwork Fri Jul 9 20:27:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Paul A. Patience" X-Patchwork-Id: 31270 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 12C2227BC83; Fri, 9 Jul 2021 21:28:16 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS, T_DKIM_INVALID,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 6AECC27BC81 for ; Fri, 9 Jul 2021 21:28:15 +0100 (BST) Received: from localhost ([::1]:42686 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m1x6c-0005ML-Di for patchwork@mira.cbaines.net; Fri, 09 Jul 2021 16:28:14 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60270) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m1x6R-0005Ll-7W for guix-patches@gnu.org; Fri, 09 Jul 2021 16:28:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:48291) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m1x6Q-0007Ff-KK for guix-patches@gnu.org; Fri, 09 Jul 2021 16:28:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m1x6Q-0002CO-I3 for guix-patches@gnu.org; Fri, 09 Jul 2021 16:28:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#49500] [PATCH] gnu: dealii: Update to 9.3.0 and clean up. Resent-From: "Paul A. Patience" Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 09 Jul 2021 20:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 49500 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 49500@debbugs.gnu.org X-Debbugs-Original-To: "guix-patches@gnu.org" Received: via spool by submit@debbugs.gnu.org id=B.16258624758438 (code B ref -1); Fri, 09 Jul 2021 20:28:02 +0000 Received: (at submit) by debbugs.gnu.org; 9 Jul 2021 20:27:55 +0000 Received: from localhost ([127.0.0.1]:59837 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1x6J-0002C1-9D for submit@debbugs.gnu.org; Fri, 09 Jul 2021 16:27:55 -0400 Received: from lists.gnu.org ([209.51.188.17]:58314) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m1x6G-0002Bt-VU for submit@debbugs.gnu.org; Fri, 09 Jul 2021 16:27:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60256) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m1x6G-0005HN-6J for guix-patches@gnu.org; Fri, 09 Jul 2021 16:27:52 -0400 Received: from mail1.protonmail.ch ([185.70.40.18]:31033) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m1x6A-000773-9K for guix-patches@gnu.org; Fri, 09 Jul 2021 16:27:51 -0400 Date: Fri, 09 Jul 2021 20:27:41 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=apatience.com; s=protonmail3; t=1625862463; bh=aESPlkJrzc1yOHeD6wmrbKVu3thBLDa7hG/W+2Z6fFc=; h=Date:To:From:Reply-To:Subject:From; b=GBbDCg+D/z9B6h8ilX/PnBGC76FogZ9c4c4SK9k+jqbR5jhG/s4EsUtGxsQmOIuTq OL4m6Y7wKqRVsDpYEhzc5WCIgdv0hAkP+i4t5slv3kT5ZIsVyn10nEG8F3YdZmWvuF ACV9tHX5UUPD3UJsYCCHVQSjPGfRayFjTAMaN+2V3F7JPd4shC0z2gx2IDhaGfphbH 4xHUJ001kquG3ICq3NhVY4+h3tvEjVoGDyU954QsryGNfwluUw1C+vtjxEFEYrwU87 yMfKUdSnIU4l6SnBxfKuOXdtnaNqE0Exk2py7QuauI3emkwOpv+7/uf/LtRFqVdPrh m1uhh0362crTA== From: "Paul A. Patience" Message-ID: MIME-Version: 1.0 Received-SPF: pass client-ip=185.70.40.18; envelope-from=paul@apatience.com; helo=mail1.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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_MSPIKE_H2=-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: , 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 Empty Message From 9e8aa19cf0e4d4963b58478e7ee353b5b079d6e0 Mon Sep 17 00:00:00 2001 From: "Paul A. Patience" Date: Fri, 9 Jul 2021 16:06:34 -0400 Subject: [PATCH] gnu: dealii: Update to 9.3.0 and clean up. The cleanup notably: * Builds and installs the documentation into a separate doc output (in the process moving around some files erroneously installed into the root directory); and * Removes unnecessary inputs, adds missing inputs and moves some inputs into propagated-inputs (the candidates of which were determined with a search for "include.*LIBNAME" in include/deal.II). * gnu/packages/maths.scm (dealii): Reword comments. [version]: Update to 9.3.0. [outputs]: New field including doc output. [native-inputs]: New field. [inputs]: Sort them. Add perl and python-wrapper. Remove p4est (deal.II interfaces with it only when MPI is enabled). Move boost, suitesparse and tbb to... [propagated-inputs]: ...here. New field including hdf5, which is actually supported in deal.II without MPI. [arguments]<#:tests?>: New argument. The tests were not being run before anyway. <#:configure-flags>[-DDEAL_II_COMPONENT_DOCUMENTATION]: New flag. [-DDEAL_II_DOCREADME_RELDIR]: New flag. Prevents the LICENSE.md, README.md, detailed.log and summary.log files from being installed in the root directory (though note that the logs are removed in the new remove-build-logs phase). [-DDEAL_II_DOCHTML_RELDIR]: New flag. [-DDEAL_II_COMPILE_EXAMPLES]: New flag. [-DDEAL_II_EXAMPLES_RELDIR]: New flag. Prevents the examples directory from being installed in the root directory. [-DCMAKE_POSITION_INDEPENDENT_CODE]: Remove flag. The issue has been resolved. <#:phases>{remove-build-logs}: New phase. [home-page]: Add trailing slash. (dealii-openmpi): Use package/inherit. [inputs]: Sort them. Remove mumps-metis-openmpi (deal.II no longer interfaces with MUMPS). Move hdf5-parallel-openmpi, openmpi, p4est-openmpi, petsc-openmpi and slepc-openmpi to... [propagated-inputs]: ...here. New field. [arguments]<#:configure-flags>: Rename cf variable to flags. <#:phases>{mpi-setup}: Remove phase which is unused because the tests are disabled. --- gnu/packages/maths.scm | 92 +++++++++++++++++++++++++++--------------- 1 file changed, 59 insertions(+), 33 deletions(-) diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index b8e9a31be7..79b198e644 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -4436,40 +4436,72 @@ revised simplex and the branch-and-bound methods.") (define-public dealii (package (name "dealii") - (version "9.2.0") + (version "9.3.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/dealii/dealii/releases/" "download/v" version "/dealii-" version ".tar.gz")) (sha256 - (base32 - "0fm4xzrnb7dfn4415j24d8v3jkh0lssi86250x2f5wgi83xq4nnh")) + (base32 "0cdr74l4ymdjcmxgm5lzq16h10pzggnx9gg3z9yq5khhfnlcgy5f")) (modules '((guix build utils))) (snippet - ;; Remove bundled sources: UMFPACK, TBB, muParser, and boost '(begin + ;; Remove bundled boost, muparser, TBB and UMFPACK. (delete-file-recursively "bundled") #t)))) (build-system cmake-build-system) + (outputs '("out" "doc")) + (native-inputs + ;; Required to build the documentation. + ;; (Also required is perl, which is in inputs.) + `(("dot" ,graphviz) + ("doxygen" ,doxygen))) (inputs - `(("tbb" ,tbb) - ("zlib" ,zlib) - ("boost" ,boost) - ("p4est" ,p4est) + `(("arpack" ,arpack-ng) ("blas" ,openblas) + ("gfortran" ,gfortran) ("lapack" ,lapack) - ("arpack" ,arpack-ng) ("muparser" ,muparser) - ("gfortran" ,gfortran) - ("suitesparse" ,suitesparse))) ;for UMFPACK + ("zlib" ,zlib) + ;; Required only for scripts installed in share/deal.II/scripts. + ;; (perl is also required to build the documentation.) + ("perl" ,perl) + ("python" ,python-wrapper))) + (propagated-inputs + `(("boost" ,boost) + ("hdf5" ,hdf5) + ("suitesparse" ,suitesparse) ; For UMFPACK. + ("tbb" ,tbb))) (arguments - `(#:build-type "DebugRelease" ;only supports Release, Debug, or DebugRelease + `(#:build-type "DebugRelease" ; Supports only Debug, Release and DebugRelease. + ;; The tests take too long and must be explicitly enabled with "make + ;; setup_tests". + ;; See https://www.dealii.org/developer/developers/testsuite.html. + ;; (They can also be run for an already installed deal.II.) + #:tests? #f #:configure-flags - ;; Work around a bug in libsuitesparseconfig linking - ;; see https://github.com/dealii/dealii/issues/4745 - '("-DCMAKE_POSITION_INDEPENDENT_CODE:BOOL=ON"))) - (home-page "https://www.dealii.org") + (let ((doc (string-append (assoc-ref %outputs "doc") + "/share/doc/" ,name "-" ,version))) + `("-DDEAL_II_COMPONENT_DOCUMENTATION=ON" + ,(string-append "-DDEAL_II_DOCREADME_RELDIR=" doc) + ,(string-append "-DDEAL_II_DOCHTML_RELDIR=" doc "/html") + ;; Don't compile the examples because the source and CMakeLists.txt + ;; are installed anyway, allowing users to do so for themselves. + "-DDEAL_II_COMPILE_EXAMPLES=OFF" + ,(string-append "-DDEAL_II_EXAMPLES_RELDIR=" doc "/examples"))) + #:phases + (modify-phases %standard-phases + (add-after 'install 'remove-build-logs + ;; These build logs leak the name of the build directory by storing + ;; the values of CMAKE_SOURCE_DIR and CMAKE_BINARY_DIR. + (lambda* (#:key outputs #:allow-other-keys) + (let ((doc (string-append (assoc-ref outputs "doc") + "/share/doc/" ,name "-" ,version))) + (for-each delete-file (map (lambda (f) (string-append doc "/" f)) + '("detailed.log" "summary.log")))) + #t))))) + (home-page "https://www.dealii.org/") (synopsis "Finite element library") (description "Deal.II is a C++ program library targeted at the computational solution @@ -4480,30 +4512,24 @@ in finite element programs.") (license license:lgpl2.1+))) (define-public dealii-openmpi - (package (inherit dealii) + (package/inherit dealii (name "dealii-openmpi") (inputs - `(("mpi" ,openmpi) - ;;Supported only with MPI: - ("hdf5" ,hdf5-parallel-openmpi) ;TODO: have petsc-openmpi propagate? + `(("arpack" ,arpack-ng-openmpi) + ("metis" ,metis) + ("scalapack" ,scalapack) + ,@(alist-delete "arpack" (package-inputs dealii)))) + (propagated-inputs + `(("hdf5" ,hdf5-parallel-openmpi) + ("mpi" ,openmpi) ("p4est" ,p4est-openmpi) ("petsc" ,petsc-openmpi) ("slepc" ,slepc-openmpi) - ("metis" ,metis) ;for MUMPS - ("scalapack" ,scalapack) ;for MUMPS - ("mumps" ,mumps-metis-openmpi) ;configure supports only metis orderings - ("arpack" ,arpack-ng-openmpi) - ,@(fold alist-delete (package-inputs dealii) - '("p4est" "arpack")))) + ,@(alist-delete "hdf5" (package-propagated-inputs dealii)))) (arguments (substitute-keyword-arguments (package-arguments dealii) - ((#:configure-flags cf) - `(cons "-DDEAL_II_WITH_MPI:BOOL=ON" - ,cf)) - ((#:phases phases '%standard-phases) - `(modify-phases ,phases - (add-before 'check 'mpi-setup - ,%openmpi-setup))))) + ((#:configure-flags flags) + `(cons "-DDEAL_II_WITH_MPI=ON" ,flags)))) (synopsis "Finite element library (with MPI support)"))) (define-public flann -- 2.32.0