Skip to content

Commit

Permalink
Enable PandoraMonitoring and add variants for the packages that use it
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell committed Dec 5, 2024
1 parent c555d49 commit e70c836
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 2 deletions.
6 changes: 6 additions & 0 deletions environments/key4hep-common/packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ packages:
buildable: true
curl:
require: +gssapi
ddmarlinpandora:
require: +monitoring
dd4hep:
require: +edm4hep+lcio+xercesc+hepmc3
gaudi:
Expand All @@ -26,8 +28,12 @@ packages:
hepmc3:
require: +python+rootio
# https://github.com/key4hep/key4hep-spack/issues/517
larcontent:
require: +monitoring
lccd:
require: +conddbmysql
lccontent:
require: +monitoring
llvm:
variants: ~flang~lldb~lld~lua~mlir~internal_unwind~polly~libomptarget~libomptarget_debug~gold~split_dwarf~llvm_dylib~link_llvm_dylib~omp_tsan~omp_as_runtime~code_signing~python~version_suffix~shlib_symbol_version~z3~zstd compiler-rt="none" libcxx="none" targets="x86"
marlin:
Expand Down
7 changes: 7 additions & 0 deletions packages/ddmarlinpandora/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,13 @@ class Ddmarlinpandora(CMakePackage, Ilcsoftpackage):
depends_on("larcontent")
depends_on("dd4hep")
depends_on("marlintrk")
depends_on("pandoramonitoring", when="+monitoring")

variant("monitoring", default=False, description="Enable Pandora Monitoring")

def setup_build_environment(self, env):
if "+monitoring" in self.spec:
env.set('PANDORA_MONITORING', 'ON')

def setup_run_environment(self, env):
env.prepend_path("MARLIN_DLL", self.prefix.lib + "/libDDMarlinPandora.so")
Expand Down
1 change: 1 addition & 0 deletions packages/ilcsoft/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ class Ilcsoft(BundlePackage, Key4hepPackage):
depends_on("marlinmlflavortagging")
depends_on("overlay")
depends_on("pandoraanalysis")
depends_on("pandoramonitoring")
depends_on("pandorapfa")
depends_on("physsim")
depends_on("raida")
Expand Down
10 changes: 9 additions & 1 deletion packages/larcontent/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,18 @@ class Larcontent(CMakePackage):
depends_on("pandorasdk")
depends_on("eigen")

depends_on("pandoramonitoring", when="+monitoring")

variant("monitoring", default=False, description="Enable Pandora Monitoring")

def setup_build_environment(self, env):
if "+monitoring" in self.spec:
env.set('PANDORA_MONITORING', 'ON')

def cmake_args(self):
args = [
"-DCMAKE_MODULE_PATH=%s" % self.spec["pandorapfa"].prefix.cmakemodules,
"-DCMAKE_CXX_FLAGS=-std=c++17 -Wno-error",
"-DCMAKE_CXX_FLAGS=-std=c++20 -Wno-error",
]
return args

Expand Down
10 changes: 9 additions & 1 deletion packages/lccontent/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,17 @@ class Lccontent(CMakePackage):
depends_on("pandorapfa")
depends_on("pandorasdk")

depends_on("pandoramonitoring", when="+monitoring")

variant("monitoring", default=False, description="Enable Pandora Monitoring")

def setup_build_environment(self, env):
if "+monitoring" in self.spec:
env.set('PANDORA_MONITORING', 'ON')

def cmake_args(self):
args = [
"-DCMAKE_CXX_STANDARD=17",
"-DCMAKE_CXX_STANDARD=20",
"-DCMAKE_MODULE_PATH=%s" % self.spec["pandorapfa"].prefix.cmakemodules,
"-DCMAKE_CXX_FLAGS=-Wno-error",
]
Expand Down

0 comments on commit e70c836

Please sign in to comment.