pika: add sanitizers variant (#42778)

This commit is contained in:
Mikael Simberg 2024-02-22 05:54:33 +01:00 committed by GitHub
parent ad70b88d5f
commit be4eae3fa8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -78,6 +78,12 @@ class Pika(CMakePackage, CudaPackage, ROCmPackage):
variant("mpi", default=False, description="Enable MPI support")
variant("apex", default=False, description="Enable APEX support", when="@0.2:")
variant("tracy", default=False, description="Enable Tracy support", when="@0.7:")
variant(
"sanitizers",
default=False,
description="Enable support for sanitizers. "
"Specific sanitizers must be explicitly enabled with -fsanitize=*.",
)
variant(
"stdexec",
default=False,
@ -185,6 +191,7 @@ def cmake_args(self):
self.define_from_variant("PIKA_WITH_MPI", "mpi"),
self.define_from_variant("PIKA_WITH_APEX", "apex"),
self.define_from_variant("PIKA_WITH_TRACY", "tracy"),
self.define_from_variant("PIKA_WITH_SANITIZERS", "sanitizers"),
self.define("PIKA_WITH_TESTS", self.run_tests),
self.define_from_variant("PIKA_WITH_GENERIC_CONTEXT_COROUTINES", "generic_coroutines"),
self.define("BOOST_ROOT", spec["boost"].prefix),