summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
authorsnehring <7978778+snehring@users.noreply.github.com>2024-11-18 17:01:59 -0500
committerGitHub <noreply@github.com>2024-11-18 14:01:59 -0800
commit89d2b9553de79f6a8a03e2730ee04d4b63ca7144 (patch)
tree52e5017483b441e0bec433ac0bb8d400ac46bd29 /var
parent278326b4d942ac73e74511a214df82f9cf564b40 (diff)
downloadspack-89d2b9553de79f6a8a03e2730ee04d4b63ca7144.tar.gz
spack-89d2b9553de79f6a8a03e2730ee04d4b63ca7144.tar.bz2
spack-89d2b9553de79f6a8a03e2730ee04d4b63ca7144.tar.xz
spack-89d2b9553de79f6a8a03e2730ee04d4b63ca7144.zip
tb-lmto: new package (#47482)
* tb-lmto: adding new package tb-lmto * tb-lmto: update copyright year
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/tb-lmto/package.py66
1 files changed, 66 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/tb-lmto/package.py b/var/spack/repos/builtin/packages/tb-lmto/package.py
new file mode 100644
index 0000000000..57612427e9
--- /dev/null
+++ b/var/spack/repos/builtin/packages/tb-lmto/package.py
@@ -0,0 +1,66 @@
+# Copyright 2013-2024 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)
+
+import os
+
+from spack.package import *
+
+
+class TbLmto(MakefilePackage):
+ """
+ The STUTTGART TB-LMTO program. The linear muffin-tin orbital (LMTO) method has been described in numerous publications.
+ Use of this software is subject to the license at
+ https://www2.fkf.mpg.de/andersen/LMTODOC/node180.html#SECTION000130000000000000000
+ """
+
+ homepage = "https://www2.fkf.mpg.de/andersen/LMTODOC/LMTODOC.html"
+ manual_download = True
+
+ maintainers("snehring")
+
+ version(
+ "20240601-47.1d", sha256="5b24f2917cef85fe49d3a4ff6403294a44a9cf7c003234a0fd96d626c316bda0"
+ )
+ version(
+ "20240601-47c2.1d",
+ sha256="c80ef9b4aa725ad75ae07b0215671b3674a8f5dced9e87202dd0d486ffe1cb10",
+ )
+ version(
+ "20240601-47u.1d",
+ sha256="bbcc1c57005f33749f8ee6d33be3490071704bce11214544cc4f9c13c28a126e",
+ )
+
+ depends_on("c", type="build")
+ depends_on("fortran", type="build")
+ depends_on("gnuplot", type="run")
+
+ parallel = False
+
+ @property
+ def build_targets(self):
+ # something about the spack wrapper breaks this, it's extremely weird
+ return [
+ f"CC={self.compiler.cc}",
+ f"FC={self.compiler.fc} -finit-local-zero -fallow-argument-mismatch",
+ "all",
+ ]
+
+ def url_for_version(self, version):
+ return f"file://{os.getcwd()}/lmto{version.string.split('-')[1]}.tar.gz"
+
+ def edit(self, spec, prefix):
+ makefile = FileFilter("makefile")
+ makefile.filter("LMPATH = .*", "LMPATH = ./")
+ makefile.filter("^FFLAGS =.*", "")
+ makefile.filter("^CCFLAGS =.*", "")
+ makefile.filter("CC=.*", "")
+ makefile.filter("FC=.*", "")
+
+ def install(self, spec, prefix):
+ mkdirp(prefix)
+ install_tree(".", prefix)
+
+ def setup_run_environment(self, env):
+ env.prepend_path("PATH", self.prefix)