From: Efraim Flashner <efraim@flashner.co.il>
To: 43042@debbugs.gnu.org
Cc: Efraim Flashner <efraim@flashner.co.il>
Subject: [bug#43042] [PATCH] gnu: Add libflame.
Date: Tue, 25 Aug 2020 18:54:07 +0300 [thread overview]
Message-ID: <20200825155407.26089-1-efraim@flashner.co.il> (raw)
* gnu/packages/maths.scm (libflame): New variable.
---
gnu/packages/maths.scm | 81 +++++++++++++++++++++++++++++++++++++++++-
1 file changed, 80 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index e3209c1e50..c093b53f5d 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -135,7 +135,8 @@
#:use-module (gnu packages version-control)
#:use-module (gnu packages wxwidgets)
#:use-module (gnu packages xml)
- #:use-module (srfi srfi-1))
+ #:use-module (srfi srfi-1)
+ #:use-module (srfi srfi-26))
(define-public aris
(package
@@ -1748,6 +1749,84 @@ linear and quadratic objectives. There are limited facilities for nonlinear
and quadratic objectives using the Simplex algorithm.")
(license license:epl1.0)))
+(define-public libflame
+ (package
+ (name "libflame")
+ (version "5.2.0")
+ (outputs '("out" "static"))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/flame/libflame")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1n6lf0wvpp77lxqlr721h2jbfbzigphdp19wq8ajiccilcksh7ay"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:configure-flags
+ ;; Sensible defaults: https://github.com/flame/libflame/issues/28
+ (list "--enable-dynamic-build"
+ "--enable-max-arg-list-hack"
+ "--enable-lapack2flame"
+ "--enable-verbose-make-output"
+ "--enable-multithreading=pthreads" ; Openblas isn't built with openmp.
+ ,@(if (any (cute string-prefix? <> (or (%current-target-system)
+ (%current-system)))
+ '("x86_64" "i686"))
+ '("--enable-vector-intrinsics=sse")
+ '())
+ "--enable-supermatrix"
+ "--enable-memory-alignment=16"
+ "--enable-ldim-alignment")
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'patch-/usr/bin/env-bash
+ (lambda _
+ (substitute* "build/config.mk.in"
+ (("/usr/bin/env bash") (which "bash")))
+ #t))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (substitute* "test/Makefile"
+ (("LIBBLAS .*") "LIBBLAS = -lblas\n")
+ (("LIBLAPACK .*") "LIBLAPACK = -llapack\n"))
+ (if tests?
+ (with-directory-excursion "test"
+ (mkdir "obj")
+ (invoke "make")
+ (invoke "./test_libflame.x"))
+ #t)))
+ (add-after 'install 'install-static
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (static (assoc-ref outputs "static")))
+ (mkdir-p (string-append static "/lib"))
+ (rename-file (string-append out "/lib/libflame.a")
+ (string-append static "/lib/libflame.a"))
+ (install-file (string-append out "/include/FLAME.h")
+ (string-append static "/include"))
+ #t))))))
+ (inputs
+ `(("gfortran" ,gfortran)))
+ (native-inputs
+ `(("lapack" ,lapack)
+ ("openblas" ,openblas)
+ ("perl" ,perl)
+ ("python" ,python-wrapper)))
+ (home-page "https://github.com/flame/libflame")
+ (synopsis "High-performance object-based library for DLA computations")
+ (description "@code{libflame} is a portable library for dense matrix
+computations, providing much of the functionality present in LAPACK, developed
+by current and former members of the @acronym{SHPC, Science of High-Performance
+Computing} group in the @url{https://www.ices.utexas.edu/, Institute for
+Computational Engineering and Sciences} at The University of Texas at Austin.
+@code{libflame} includes a compatibility layer, @code{lapack2flame}, which
+includes a complete LAPACK implementation.")
+ (license license:bsd-3)))
+
(define-public ceres
(package
(name "ceres-solver")
--
2.28.0
next reply other threads:[~2020-08-25 15:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-25 15:54 Efraim Flashner [this message]
2020-08-27 8:27 ` [bug#43042] [PATCH] gnu: Add libflame Mathieu Othacehe
2020-08-27 15:20 ` bug#43042: " Efraim Flashner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200825155407.26089-1-efraim@flashner.co.il \
--to=efraim@flashner.co.il \
--cc=43042@debbugs.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.