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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
# 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)
from spack.package import *
class PikaAlgorithms(CMakePackage):
"""C++ parallel algorithms built on pika."""
homepage = "https://github.com/pika-org/pika-algorithms/"
url = "https://github.com/pika-org/pika-algorithms/archive/0.0.0.tar.gz"
git = "https://github.com/pika-org/pika-algorithms.git"
maintainers("msimberg", "albestro", "teonnik", "aurianer")
version("0.1.3", sha256="53b79fcc0e5decc0a4d70abf0897a4f66141b85eea6d65013f51eec02ad123b7")
version("0.1.2", sha256="286cf5c4db06717fa66c681cec8c99207154dd07e72d72f2b5b4a3cb9ff698bf")
version("0.1.1", sha256="4aae88ac19864fd278bbdb49ae56348014c3d0d4b49a46ab3b9ba8a180f745f6")
version("0.1.0", sha256="64da008897dfa7373155595c46d2ce6b97a8a3cb5bea33ae7f2d1ff359f0d9b6")
version("main", branch="main")
generator("ninja")
map_cxxstd = lambda cxxstd: "2a" if cxxstd == "20" else cxxstd
cxxstds = ("17", "20")
variant(
"cxxstd",
default="17",
values=cxxstds,
description="Use the specified C++ standard when building",
)
# Build dependencies
depends_on("git", type="build")
depends_on("cmake@3.22:", type="build")
conflicts("%gcc@:8")
conflicts("%clang@:8")
# Other dependencies
depends_on("boost@1.71:")
depends_on("fmt@9:")
depends_on("pika@0.11:")
depends_on("pika@0.11", when="@0.1.0")
depends_on("pika@0.11:0.12", when="@0.1.1")
depends_on("pika@0.11:0.15", when="@0.1.2")
for cxxstd in cxxstds:
depends_on("boost cxxstd={0}".format(map_cxxstd(cxxstd)), when="cxxstd={0}".format(cxxstd))
depends_on("fmt cxxstd={0}".format(cxxstd), when="cxxstd={0}".format(cxxstd))
depends_on("pika cxxstd={0}".format(cxxstd), when="cxxstd={0}".format(cxxstd))
def cmake_args(self):
return [
self.define("PIKA_ALGORITHMS_WITH_CXX_STANDARD", self.spec.variants["cxxstd"].value)
]
|