Skip to content

Commit

Permalink
Add the new k4Reco package (#532)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell authored Apr 23, 2024
1 parent f1cc1d4 commit 928447c
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 0 deletions.
40 changes: 40 additions & 0 deletions packages/k4reco/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
from spack.pkg.k4.key4hep_stack import Key4hepPackage
from spack.pkg.k4.key4hep_stack import k4_setup_env_for_framework_tests


class K4reco(CMakePackage, Key4hepPackage):
"""Reconstruction algorithms using Gaudi in native key4hep"""

homepage = "https://github.com/key4hep/k4Reco"
url = "https://github.com/key4hep/k4Reco/archive/v00-01.tar.gz"
git = "https://github.com/key4hep/k4Reco.git"

version("master", branch="main")

depends_on("root")
depends_on("edm4hep")
depends_on("k4fwcore")
depends_on("gaudi")
depends_on("dd4hep")
depends_on("k4simgeant4")

def cmake_args(self):
args = []
# C++ Standard
args.append(
self.define(
"CMAKE_CXX_STANDARD", self.spec["root"].variants["cxxstd"].value
)
)
return args

def setup_dependent_build_environment(self, env, dependent_spec):
# needed to set up the runtime dependencies for tests
env.prepend_path("PYTHONPATH", self.prefix.python)
env.prepend_path("LD_LIBRARY_PATH", self.spec["k4reco"].prefix.lib)
env.prepend_path("LD_LIBRARY_PATH", self.spec["k4reco"].prefix.lib64)

def setup_run_environment(self, env):
env.prepend_path("PYTHONPATH", self.prefix.python)
env.prepend_path("LD_LIBRARY_PATH", self.spec["k4reco"].prefix.lib)
env.prepend_path("LD_LIBRARY_PATH", self.spec["k4reco"].prefix.lib64)
1 change: 1 addition & 0 deletions packages/key4hep-stack/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ class Key4hepStack(BundlePackage, Key4hepPackage):
depends_on("k4fwcore")
depends_on("k4gen")
depends_on("k4projecttemplate")
depends_on("k4reco")
depends_on("k4simdelphes")
depends_on("k4simgeant4")
depends_on("kkmcee")
Expand Down
1 change: 1 addition & 0 deletions scripts/fetch_nightly_versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ def get_latest_commit(
("k4fwcore", "key4hep/k4fwcore"),
("k4gen", "hep-fcc/k4Gen"),
("k4geo", "key4hep/k4geo"),
("k4reco", "key4hep/k4reco"),
("k4marlinwrapper", "key4hep/k4marlinwrapper"),
("k4projecttemplate", "key4hep/k4-project-template"),
("k4reccalorimeter", "hep-fcc/k4reccalorimeter"),
Expand Down

0 comments on commit 928447c

Please sign in to comment.