diff options
author | snehring <7978778+snehring@users.noreply.github.com> | 2023-07-27 14:26:25 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-27 12:26:25 -0700 |
commit | 9d9e4a52f501238c4fd4732ae5fcd34ffdcee53c (patch) | |
tree | 81ed3656fe5d97e4460e2a02c666b4ca0f5f8ffc /var | |
parent | 9e0629213cb4b43a2c333c044fc964c98000d899 (diff) | |
download | spack-9d9e4a52f501238c4fd4732ae5fcd34ffdcee53c.tar.gz spack-9d9e4a52f501238c4fd4732ae5fcd34ffdcee53c.tar.bz2 spack-9d9e4a52f501238c4fd4732ae5fcd34ffdcee53c.tar.xz spack-9d9e4a52f501238c4fd4732ae5fcd34ffdcee53c.zip |
tecio: adding new package tecio (#39099)
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/tecio/package.py | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/tecio/package.py b/var/spack/repos/builtin/packages/tecio/package.py new file mode 100644 index 0000000000..d54636eefb --- /dev/null +++ b/var/spack/repos/builtin/packages/tecio/package.py @@ -0,0 +1,59 @@ +# Copyright 2013-2023 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 Tecio(CMakePackage): + """The TecIO library allows third-party applications to read and write + Tecplot file format.""" + + homepage = "https://www.tecplot.com/products/tecio-library/" + url = "file://{}/tecio.tgz".format(os.getcwd()) + + manual_download = True + + maintainers("snehring") + + version("2022R2", sha256="35a8137800611da3a413da09223e2d1683b54e195bc52f8fc4ec131cfce7cb23") + + depends_on("cmake@3.0.2:", type="build") + + depends_on("boost@1.69.0:+system", type="build") + depends_on("mpi", when="+mpi") + + variant("mpi", default=False, description="Build tecio with mpi support.") + + @property + def root_cmakelists_dir(self): + if self.spec.satisfies("+mpi"): + return "teciompisrc" + else: + return "teciosrc" + + def install(self, spec, prefix): + includes = [ + "StandardIntegralTypes.h", + "TECIO.h", + "tecio_Exports.h", + "tecio.inc", + "tecio.for", + "tecio.f90", + ] + mkdirp(join_path(prefix, "include")) + mkdirp(join_path(prefix, "lib")) + mkdirp(join_path(prefix, "bin")) + with working_dir(self.root_cmakelists_dir): + for f in includes: + install(f, prefix.include) + install("tecio_license_agreement.txt", prefix) + with working_dir(self.build_directory): + install("szcombine", prefix.bin) + if spec.satisfies("+mpi"): + install("libteciompi.a", prefix.lib) + else: + install("libtecio.a", prefix.lib) |