summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/chaparral/package.py
blob: 050ca651d4f5d710ea0bdffc0f7ce80a3ae85464 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# 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 Chaparral(CMakePackage):
    """Radiation view factor library"""

    homepage = "https://gitlab.com/truchas/tpl-forks/chaparral"
    git = "https://gitlab.com/truchas/tpl-forks/chaparral.git"

    maintainers("pbrady", "zjibben")

    license("LGPL-2.1-or-later")

    version("develop", branch="truchas")
    version("2020-08-28", commit="c8a190bb74ef33ad8b2f7b67d20590f393fde32a", preferred=True)

    variant("shared", default=True, description="Build shared library")
    variant("mpi", default=True, description="Build parallel library")

    depends_on("mpi", when="+mpi")
    depends_on("cmake@3.16:", type="build")

    def cmake_args(self):
        return [
            self.define_from_variant("BUILD_SHARED_LIBS", "shared"),
            self.define_from_variant("ENABLE_MPI", "mpi"),
        ]