summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErik Schnetter <schnetter@gmail.com>2020-10-06 01:12:11 -0400
committerGitHub <noreply@github.com>2020-10-05 22:12:11 -0700
commit630f1fe2b8204ae3ec9ee12bd264309a314bf690 (patch)
tree1eef89647401c3a8ed1fb6ad977ea26300baba52
parenteabfea2e49f6db473401b29ca80966f41a7e7c23 (diff)
downloadspack-630f1fe2b8204ae3ec9ee12bd264309a314bf690.tar.gz
spack-630f1fe2b8204ae3ec9ee12bd264309a314bf690.tar.bz2
spack-630f1fe2b8204ae3ec9ee12bd264309a314bf690.tar.xz
spack-630f1fe2b8204ae3ec9ee12bd264309a314bf690.zip
New package: FastTransforms (#19160)
-rw-r--r--var/spack/repos/builtin/packages/fasttransforms/package.py40
1 files changed, 40 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/fasttransforms/package.py b/var/spack/repos/builtin/packages/fasttransforms/package.py
new file mode 100644
index 0000000000..ca33a50428
--- /dev/null
+++ b/var/spack/repos/builtin/packages/fasttransforms/package.py
@@ -0,0 +1,40 @@
+# Copyright 2013-2020 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+from spack import *
+
+
+class Fasttransforms(MakefilePackage):
+ """FastTransforms provides computational kernels and driver routines for
+ orthogonal polynomial transforms. The univariate algorithms have a runtime
+ complexity of O(n log n), while the multivariate algorithms are 2-normwise
+ backward stable with a runtime complexity of O(nd+1), where n is the
+ polynomial degree and d is the spatial dimension of the problem."""
+
+ homepage = "https://github.com/MikaelSlevinsky/FastTransforms"
+ url = "https://github.com/MikaelSlevinsky/FastTransforms/archive/v0.3.4.tar.gz"
+
+ version('0.3.4', sha256='a5c8b5aedbdb40218521d061a7df65ef32ce153d4e19d232957db7e3e63c7e9b')
+
+ variant('quadmath', default=False, description="Support 128-bit floats")
+
+ depends_on('blas')
+ depends_on('fftw')
+ depends_on('mpfr')
+
+ def build(self, spec, prefix):
+ makeargs = ["CC=cc"]
+ if 'openblas' in spec:
+ makeargs += ["FT_BLAS=openblas"]
+ if 'quadmath' in spec:
+ makeargs += ["FT_QUADMATH=1"]
+ make('assembly', *makeargs)
+ make('lib', *makeargs)
+
+ def install(self, spec, prefix):
+ mkdirp(prefix.include)
+ install(join_path('src', '*.h'), prefix.include)
+ mkdirp(prefix.lib)
+ install('libfasttransforms.' + dso_suffix, prefix.lib)