all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#28220] [PATCH 1/2] gnu: add scotch32
@ 2017-08-24 14:56 Paul Garlick
  2017-08-24 14:56 ` [bug#28221] [PATCH 2/2] gnu: Add pt-scotch32 Paul Garlick
  2017-08-31 10:21 ` bug#28220: [PATCH 1/2] gnu: add scotch32 Ludovic Courtès
  0 siblings, 2 replies; 4+ messages in thread
From: Paul Garlick @ 2017-08-24 14:56 UTC (permalink / raw)
  To: 28220; +Cc: Paul Garlick

*gnu/packages/maths.scm: Add scotch32
---
 gnu/packages/maths.scm | 47 +++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 47 insertions(+)

Hello Guix,

Here are the patches to add 'scotch32' and 'pt-scotch32' packages, as
discussed in bug#28045.

There is one 'guix lint' warning to be aware of:

"file names of patches should start with the package name"

This is caused by the new packages inheriting the patch names from the
original packages.  I guess this is best ignored ('pt-scotch' already
shares the same patches as 'scotch').

Paul.

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 1bb9f10ec..bc0ffb09a 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -1937,6 +1937,53 @@ bio-chemistry.")
     ;; See LICENSE_en.txt
     (license license:cecill-c)))
 
+(define-public scotch32
+  (package (inherit scotch)
+    (name "scotch32")
+    (arguments
+     (substitute-keyword-arguments (package-arguments scotch)
+       ((#:phases scotch-phases)
+        `(modify-phases ,scotch-phases
+          (replace
+           'configure
+           (lambda _
+             (call-with-output-file "Makefile.inc"
+               (lambda (port)
+                 (format port "
+EXE =
+LIB = .a
+OBJ = .o
+MAKE = make
+AR = ar
+ARFLAGS = -ruv
+CAT = cat
+CCS = gcc
+CCP = mpicc
+CCD = gcc
+CPPFLAGS =~{ -D~a~}
+CFLAGS = -O2 -g -fPIC $(CPPFLAGS)
+LDFLAGS = -lz -lm -lrt -lpthread
+CP = cp
+LEX = flex -Pscotchyy -olex.yy.c
+LN = ln
+MKDIR = mkdir
+MV = mv
+RANLIB = ranlib
+YACC = bison -pscotchyy -y -b y
+"
+                        '("COMMON_FILE_COMPRESS_GZ"
+                          "COMMON_PTHREAD"
+                          "COMMON_RANDOM_FIXED_SEED"
+                          "INTSIZE32"   ;use 32-bit integers.  See INSTALL.txt
+                          ;; Prevents symbolc clashes with libesmumps
+                          "SCOTCH_RENAME"
+                          ;; XXX: Causes invalid frees in superlu-dist tests
+                          ;; "SCOTCH_PTHREAD"
+                          ;; "SCOTCH_PTHREAD_NUMBER=2"
+                          "restrict=__restrict"))))))))))
+    (synopsis
+        "Programs and libraries for graph algorithms (using 32-bit integers")))
+
 (define-public pt-scotch
   (package (inherit scotch)
     (name "pt-scotch")
-- 
2.13.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#28221] [PATCH 2/2] gnu: Add pt-scotch32
  2017-08-24 14:56 [bug#28220] [PATCH 1/2] gnu: add scotch32 Paul Garlick
@ 2017-08-24 14:56 ` Paul Garlick
  2017-08-31 10:27   ` bug#28221: " Ludovic Courtès
  2017-08-31 10:21 ` bug#28220: [PATCH 1/2] gnu: add scotch32 Ludovic Courtès
  1 sibling, 1 reply; 4+ messages in thread
From: Paul Garlick @ 2017-08-24 14:56 UTC (permalink / raw)
  To: 28221; +Cc: Paul Garlick

*gnu/packages/maths.scm: Add pt-scotch32
---
 gnu/packages/maths.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index bc0ffb09a..f228518b0 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -2007,6 +2007,30 @@ YACC = bison -pscotchyy -y -b y
             (lambda _ (zero? (system* "make" "ptcheck"))))))))
     (synopsis "Programs and libraries for graph algorithms (with MPI)")))
 
+(define-public pt-scotch32
+  (package (inherit scotch32)
+    (name "pt-scotch32")
+    (propagated-inputs
+     `(("openmpi" ,openmpi)))           ;Headers include MPI headers
+    (arguments
+     (substitute-keyword-arguments (package-arguments scotch)
+       ((#:phases scotch-phases)
+        `(modify-phases ,scotch-phases
+           (replace
+            'build
+            (lambda _
+              (and
+               (zero? (system* "make"
+                               (format #f "-j~a" (parallel-job-count))
+                               "ptscotch" "ptesmumps"))
+               ;; Install the serial metis compatibility library
+               (zero? (system* "make" "-C" "libscotchmetis" "install")))))
+           (replace
+            'check
+            (lambda _ (zero? (system* "make" "ptcheck"))))))))
+    (synopsis
+"Programs and libraries for graph algorithms (with MPI and 32-bit integers)")))
+
 (define-public metis
   (package
     (name "metis")
-- 
2.13.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* bug#28220: [PATCH 1/2] gnu: add scotch32
  2017-08-24 14:56 [bug#28220] [PATCH 1/2] gnu: add scotch32 Paul Garlick
  2017-08-24 14:56 ` [bug#28221] [PATCH 2/2] gnu: Add pt-scotch32 Paul Garlick
@ 2017-08-31 10:21 ` Ludovic Courtès
  1 sibling, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-08-31 10:21 UTC (permalink / raw)
  To: Paul Garlick; +Cc: 28220-done

Hi Paul,

Paul Garlick <pgarlick@tourbillion-technology.com> skribis:

> *gnu/packages/maths.scm: Add scotch32

Applied with minor cosmetic changes.

Thanks and sorry for the delay!

Ludo’.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#28221: [PATCH 2/2] gnu: Add pt-scotch32
  2017-08-24 14:56 ` [bug#28221] [PATCH 2/2] gnu: Add pt-scotch32 Paul Garlick
@ 2017-08-31 10:27   ` Ludovic Courtès
  0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-08-31 10:27 UTC (permalink / raw)
  To: Paul Garlick; +Cc: 28221-done

Paul Garlick <pgarlick@tourbillion-technology.com> skribis:

> *gnu/packages/maths.scm: Add pt-scotch32

Applied, thanks!

Ludo'.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-08-31 10:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-24 14:56 [bug#28220] [PATCH 1/2] gnu: add scotch32 Paul Garlick
2017-08-24 14:56 ` [bug#28221] [PATCH 2/2] gnu: Add pt-scotch32 Paul Garlick
2017-08-31 10:27   ` bug#28221: " Ludovic Courtès
2017-08-31 10:21 ` bug#28220: [PATCH 1/2] gnu: add scotch32 Ludovic Courtès

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.