GNU bug report logs - #66129
[PATCH 00/20] Split SuiteSparse into subpackages

Previous Next

Package: guix-patches;

Reported by: David Elsing <david.elsing <at> posteo.net>

Date: Wed, 20 Sep 2023 22:07:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludovic.courtes <at> inria.fr>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: David Elsing <david.elsing <at> posteo.net>
To: 66129 <at> debbugs.gnu.org
Cc: David Elsing <david.elsing <at> posteo.net>
Subject: [bug#66129] [PATCH 11/20] gnu: Add metis-suitesparse.
Date: Wed, 20 Sep 2023 22:08:01 +0000
* gnu/packages/maths.scm (metis-suitesparse): New variable.
---
 gnu/packages/maths.scm | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 668d564edc..b34ad70321 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -5253,6 +5253,32 @@ (define-public gklib-suitesparse
      (modify-inputs (package-inputs gklib)
        (prepend suitesparse-config)))))
 
+(define-public metis-suitesparse
+  (package/inherit metis-5.2
+    (name "metis-suitesparse")
+    (arguments
+     (substitute-keyword-arguments (package-arguments metis-5.2)
+       ((#:phases phases)
+        #~(modify-phases #$phases
+            (add-before 'prepare-cmake 'set-idxwidth
+              (lambda _
+                (substitute* "Makefile"
+                  (("IDXWIDTH.*=.*")
+                   "IDXWIDTH = \"\\#define IDXTYPEWIDTH 64\"\n"))))
+            (add-before 'prepare-cmake 'link-suitesparse-config
+              (lambda _
+                (substitute* "programs/CMakeLists.txt"
+                  (("include_directories.*" all)
+                   (string-append
+                    all "find_package(SuiteSparse_config REQUIRED)\n"))
+                  (("(target_link_libraries.*)GKlib(.*)" _ start end)
+                   (string-append
+                    start "GKlib ${SUITESPARSE_CONFIG_LIBRARIES}" end)))))))
+       ((#:configure-flags _)
+        #~(list "-DSHARED=ON"
+                (string-append "-DGKLIB_PATH=" #$gklib-suitesparse)))))
+    (inputs (list suitesparse-config gklib-suitesparse))))
+
 (define-public suitesparse
   (package
     (name "suitesparse")
-- 
2.41.0





This bug report was last modified 1 year and 219 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.