File indexing completed on 2025-07-15 08:16:09
0001 from spack.package import *
0002 from spack.pkg.builtin.acts import Acts as BuiltinActs
0003 from spack.spec import Spec
0004
0005
0006 class Acts(BuiltinActs):
0007 def __init__(self, spec):
0008 super(Acts, self).__init__(spec)
0009
0010 for _spec in ["@:35+edm4hep", "@:35+podio"]:
0011 if Spec(_spec) in Acts.dependencies:
0012 del Acts.dependencies[Spec(_spec)]
0013
0014
0015 patch("Plugins_Cuda_CMakeLists.patch", when="@38:39.0")
0016
0017
0018 patch(
0019 "https://github.com/acts-project/acts/pull/4380.patch?full_index=1",
0020 sha256="85e7b52a21c9933d503e47a4d02e20fee61cb9d41fbe8c1471070d42a20d8ec8",
0021 when="@30.3.0:41",
0022 )
0023
0024
0025 patch(
0026 "https://github.com/acts-project/acts/commit/50dcda3890ce75b28b1485131b8da698603a73be.patch?full_index=1",
0027 sha256="4826f9718dba083cb67583ec7751550e9d39980649404272aa1b1c78247e4050",
0028 when="@35",
0029 )
0030 conflicts("^geant4@11.3:", when="@:34")
0031
0032
0033 patch(
0034 "https://github.com/acts-project/acts/commit/8fce1a7b32aa39f967919adc4cabebbfde2a7a97.patch?full_index=1",
0035 sha256="78d4fac4235f7659c674a267f11e2d5bcad82af0d9df2036ef620d64997497d0",
0036 when="@30.3.0:34.0",
0037 )
0038
0039
0040 patch(
0041 "https://github.com/acts-project/acts/pull/3132.patch?full_index=1",
0042 sha256="e0c97940abc2b4eab50834f76dcfcf2e651b7bf961ad3dd6e124a56d4d5e1779",
0043 when="@30.3.0:34.0",
0044 )
0045 patch(
0046 "https://github.com/acts-project/acts/commit/3255dfc3dddf9c7a82aaddb041d4a6f095d19124.patch?full_index=1",
0047 sha256="60317f6a09a7d57721c1234fcf087ae85aeab27653976d1d3ac7a846c3b85a89",
0048 when="@20.1.0:26",
0049 )
0050
0051 @when("@33:35")
0052 def patch(self):
0053
0054 filter_file("_acts_podio_version 0.16", "_acts_podio_version 1.0", "CMakeLists.txt")
0055
0056 def cmake_args(self):
0057 args = super().cmake_args()
0058 if self.spec.satisfies("^python"):
0059 args.append(self.define("Python_EXECUTABLE", self.spec["python"].command.path))
0060 return args
0061
0062
0063
0064 _acts = Acts(Spec("acts"))