summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniele Cesarini <d.cesarini@cineca.it>2024-04-05 05:14:27 +0200
committerGitHub <noreply@github.com>2024-04-04 21:14:27 -0600
commitcf11fab5ad054bc55dbfd1f103a9c5aec0eb6c63 (patch)
tree2abf85ceab296b121f6137de93477ec23b58059d
parent1d8b35c84074a846f8f48c59e6379b386b91b944 (diff)
downloadspack-cf11fab5ad054bc55dbfd1f103a9c5aec0eb6c63.tar.gz
spack-cf11fab5ad054bc55dbfd1f103a9c5aec0eb6c63.tar.bz2
spack-cf11fab5ad054bc55dbfd1f103a9c5aec0eb6c63.tar.xz
spack-cf11fab5ad054bc55dbfd1f103a9c5aec0eb6c63.zip
Added Libfort library (#43490)
-rw-r--r--var/spack/repos/builtin/packages/libfort/package.py36
1 files changed, 36 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/libfort/package.py b/var/spack/repos/builtin/packages/libfort/package.py
new file mode 100644
index 0000000000..aeabbd233e
--- /dev/null
+++ b/var/spack/repos/builtin/packages/libfort/package.py
@@ -0,0 +1,36 @@
+# 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)
+
+from spack.package import *
+
+
+class Libfort(CMakePackage):
+ """libfort is a simple crossplatform library to create formatted text tables."""
+
+ homepage = "https://github.com/seleznevae/libfort"
+ url = "https://github.com/seleznevae/libfort/archive/refs/tags/v0.4.2.tar.gz"
+
+ license("MIT")
+
+ version("0.4.2", sha256="8f7b03f1aa526e50c9828f09490f3c844b73d5f9ca72493fe81931746f75e489")
+
+ variant("enable_astyle", default=False, description="Enable astyle")
+ variant("enable_wchar", default=True, description="Enable wchar support")
+ variant("enable_utf8", default=True, description="Enable utf8 support")
+ variant("enable_testing", default=True, description="Enables building tests and examples")
+ variant("shared", default=False, description="Build shared library")
+
+ depends_on("cmake@3.0.0:", type="build")
+
+ def cmake_args(self):
+ args = [
+ self.define_from_variant("FORT_ENABLE_ASTYLE", "enable_astyle"),
+ self.define_from_variant("FORT_ENABLE_WCHAR", "enable_wchar"),
+ self.define_from_variant("FORT_ENABLE_UTF8", "enable_utf8"),
+ self.define_from_variant("FORT_ENABLE_TESTING", "enable_testing"),
+ self.define_from_variant("BUILD_SHARED_LIBS", "shared"),
+ ]
+
+ return args