Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update nightly builds #618

Merged
merged 59 commits into from
Aug 5, 2024
Merged
Changes from 1 commit
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
ed14dbd
Update .cherry-pick .last-commit and add opt and dbg environments
jmcarcell Jul 24, 2024
2f247f1
Use release for all the packages in opt
jmcarcell Jul 24, 2024
296fa57
Remove the cherry pick for FCCAnalyses
jmcarcell Jul 24, 2024
ecb3990
Add a cherry pick for sherpa
jmcarcell Jul 24, 2024
4d3555b
Don't build geant4 with debug symbols
jmcarcell Jul 24, 2024
7ecbc5d
Try to add a newer version of python
jmcarcell Jul 24, 2024
63c1d52
Don't require python 3.11 or newer
jmcarcell Jul 24, 2024
32b9177
Add a sherpa2 package
jmcarcell Jul 24, 2024
d6c2c29
Try not requiring a version of ROOT
jmcarcell Jul 24, 2024
a153bc7
Require a version for ROOT
jmcarcell Jul 24, 2024
ecfa59e
Add gosam to whizard, see #581
jmcarcell Jul 24, 2024
ce9394c
Remove the pythia6 variant
jmcarcell Jul 24, 2024
1a97365
Remove pandorapfa and pandoraska
jmcarcell Jul 24, 2024
fc1e9a0
Slightly update ROOT requirements
jmcarcell Jul 24, 2024
cf7dbd0
Add a comment about ROOT
jmcarcell Jul 24, 2024
634c2b1
Add a cherry pick for ROOT
jmcarcell Jul 25, 2024
14a5446
Add and update cherry picks for geant4
jmcarcell Jul 26, 2024
f4938c6
Add a cherry pick for Gaudi
jmcarcell Jul 26, 2024
82471ce
Don't build gaudialg
jmcarcell Jul 29, 2024
461aeef
Have the two geant4 changes in a single commit
jmcarcell Jul 29, 2024
402ff8c
Fix the commit
jmcarcell Jul 29, 2024
4d4b2b2
Add a patch for babayaga
jmcarcell Jul 29, 2024
be8077d
Fix patch
jmcarcell Jul 29, 2024
33cef85
Fix patch
jmcarcell Jul 29, 2024
e52724c
Fix patch
jmcarcell Jul 29, 2024
aafbec9
Fix patch
jmcarcell Jul 29, 2024
f4f1221
Remove a cherry pick for gaudi
jmcarcell Jul 30, 2024
f6bfa00
Add a patch for acts and py-onnx
jmcarcell Jul 30, 2024
6a9ff18
Update dependencies for k4reccalorimeter
jmcarcell Jul 30, 2024
0eed4d4
Add a new package for k4GeneratorsConfig
jmcarcell Jul 30, 2024
4ef8381
Build k4generatorsconfig only with +generators
jmcarcell Jul 31, 2024
e5d687a
Add k4generatorsconfig to the debug builds
jmcarcell Jul 31, 2024
7a25416
Fix mistake with k4generatorsconfig
jmcarcell Jul 31, 2024
4a59587
Add a new instalaltion name for the debug builds
jmcarcell Jul 31, 2024
35a3f2c
Change variants to require for Debug builds
jmcarcell Jul 31, 2024
3cb4f55
Remove non-allowed config in spack.yaml
jmcarcell Jul 31, 2024
d32b926
Add a space when merging configs
jmcarcell Jul 31, 2024
f4d0882
Remove cxxstd=20 for gear
jmcarcell Jul 31, 2024
0d52804
Add marlinmlflavortagging to the list of packages to build with Debug
jmcarcell Jul 31, 2024
05e34b4
Remove unnecessary block for all packages since this is in common alr…
jmcarcell Jul 31, 2024
814dc79
Add the key4hep-stack to be built "Debug" so that it appears
jmcarcell Jul 31, 2024
4441548
Try using a variant
jmcarcell Jul 31, 2024
65d3188
Move back to require
jmcarcell Jul 31, 2024
037637c
Fix the fetch_nightly_versions for the debug nightlies
jmcarcell Jul 31, 2024
124e7db
Fix fetch_nightly_versions for the debug builds
jmcarcell Jul 31, 2024
3792971
Remove whizard from common
jmcarcell Jul 31, 2024
4c10da2
Temporarily make sure some packages are built with Release
jmcarcell Aug 1, 2024
7ead84d
Change a few comments
jmcarcell Aug 2, 2024
ac7fef1
Add a dependency on m4 for groff
jmcarcell Aug 2, 2024
ee412fa
Change the URL for xrootd
jmcarcell Aug 2, 2024
1d2432f
Add a comment about removing a cherry pick
jmcarcell Aug 2, 2024
7a5122b
Add the date for the key4hep-stack so that there aren't empty builds
jmcarcell Aug 3, 2024
0a42a60
Fix pre-commit
jmcarcell Aug 5, 2024
bca93f5
Update setup scripts
jmcarcell Aug 5, 2024
029a453
Do not forget PopOS
jmcarcell Aug 5, 2024
39dd45e
Make sure the build type is set at the beginning
jmcarcell Aug 5, 2024
5486319
Don't advertise the flag for the releases since there isn't a debug b…
jmcarcell Aug 5, 2024
5664059
Remove the Release requirement since this is the default
jmcarcell Aug 5, 2024
3073fca
Fix wrong function name
jmcarcell Aug 5, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add a sherpa2 package
  • Loading branch information
jmcarcell committed Aug 5, 2024
commit 32b9177f0db77de96fbc750c4b20435f25d5c764
2 changes: 2 additions & 0 deletions packages/key4hep-stack/package.py
Original file line number Diff line number Diff line change
@@ -79,7 +79,9 @@ class Key4hepStack(BundlePackage, Key4hepPackage):
depends_on("lhapdf", when="+generators")
depends_on("madgraph5amc", when="+generators")
depends_on("photos+hepmc3", when="+generators")
# Sherpa3
depends_on("sherpa", when="+generators")
depends_on("sherpa2", when="+generators")

depends_on("ilcsoft")

287 changes: 287 additions & 0 deletions packages/sherpa2/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,287 @@
# Copyright 2013-2024 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)


# This is the sherpa recipe before the introduction of sherpa3
# It is added here so that both sherpa2 and sherpa3 can be installed as different packages
# and can live together. This recipe can be removed once we don't need sherpa2 anymore.

from spack.package import *


class Sherpa2(AutotoolsPackage):
"""Sherpa is a Monte Carlo event generator for the Simulation of
High-Energy Reactions of PArticles in lepton-lepton, lepton-photon,
photon-photon, lepton-hadron and hadron-hadron collisions."""

homepage = "https://sherpa-team.gitlab.io"
url = "https://gitlab.com/sherpa-team/sherpa/-/archive/v2.2.11/sherpa-v2.2.11.tar.gz"
list_url = "https://gitlab.com/sherpa-team/sherpa/-/tags"
git = "https://gitlab.com/sherpa-team/sherpa.git"

tags = ["hep", "eic"]

maintainers("wdconinc", "vvolkl")

license("GPL-3.0-only")

version("2.2.15", sha256="0300fd719bf6a089b7dc5441f720e669ac1cb030045d87034a4733bee98e7bbc")
version("2.2.14", sha256="f17d88d7f3bc4234a9db3872e8a3c1f3ef99e1e2dc881ada5ddf848715dc82da")
version("2.2.13", sha256="ed1fd1372923c191ca44897802d950702b810382260e7464d36ac3234c5c8a64")
version("2.2.12", sha256="4ba78098e45aaac0bc303d1b5abdc15809f30b407abf9457d99b55e63384c83d")
version("2.2.11", sha256="5e12761988b41429f1d104f84fdf352775d233cde7a165eb64e14dcc20c3e1bd")
version(
"2.2.10",
sha256="ae23bc8fdcc9f8c26becc41692822233b62203cd72a7e0dab2ca19316aa0aad7",
deprecated=True,
)
version(
"2.2.9",
sha256="ebc836d42269a0c4049d3fc439a983d19d12595d9a06db2d18765bd1e301923e",
deprecated=True,
)
version(
"2.2.8",
sha256="ff198cbae5de445e6fe383151021ef24b1628dffc0da6bf3737753f6672a0091",
deprecated=True,
)
version(
"2.0.0",
sha256="0e873b27bb1be46ca5ed451d1b8514ca84c10221057b11be5952180076e6f848",
deprecated=True,
)
version(
"1.3.1",
sha256="31881207838d341358db64e3fdadfeee1ea2f6d1cb42f370014f622f579159ae",
deprecated=True,
)
version(
"1.3.0",
sha256="08b13c65b66f2edde6996d2a06762a12a0682ffb64bca43654df47321e5039a0",
deprecated=True,
)
version(
"1.2.3",
sha256="029727337a430d6675a1a12dce3ced0411041e79ddaf4ce3b9466035cf6c8804",
deprecated=True,
)
version(
"1.2.2",
sha256="6e7b5ea80b99f1378519009e494030d6cf4c4491f91218d749eabb8ffaad9ac1",
deprecated=True,
)
version(
"1.2.1",
sha256="838462f4a1e8768135363aa6b8532fd8f5e5789a269b858f8e3728ab37f6a1d1",
deprecated=True,
)
version(
"1.2.0",
sha256="509508fd0ad72aaf55ab484da8b6bc0b31688c955adcda62a3e8f94689cebf99",
deprecated=True,
)
version(
"1.1.3",
sha256="6335e5eb1fc304e9618496d3ddb198b3591e57b27db6e876af8fd649a8b98c93",
deprecated=True,
)
version(
"1.1.2",
sha256="e1689cad6700dc013af0afb0d33729ac2b5e9841d2f325c85b10d773e7f8a80e",
deprecated=True,
)
version(
"1.1.1",
sha256="b80e1d75934be79b73400d2c95d96e88651626ea29ddcb9d8fde9c1812039e29",
deprecated=True,
)
version(
"1.1.0",
sha256="8052d137d668353dc710f8691b921e772820d39e20361f0d616ee2da1ac798f2",
deprecated=True,
)
version(
"1.0.9",
sha256="fe28db91ea8264364395c7e5efeeae3e5c01ea1343e0db7fe13924c6f17fb963",
deprecated=True,
)
version(
"1.0.8",
sha256="6e346bafd13b5b05ad566a73759da6d5e64d65c5036780cc4911d93277e891fa",
deprecated=True,
)
version(
"1.0.7",
sha256="d1eeefd96c6822ea8eb926447ca91ec4a1c714e4746323e92b1e17764e51ff0b",
deprecated=True,
)
version(
"1.0.6",
sha256="358d417ec3afde24618c222bc9b742bc5102d435622b3cd6f2e3f72d03656255",
deprecated=True,
)

depends_on("c", type="build") # generated
depends_on("cxx", type="build") # generated
depends_on("fortran", type="build") # generated

_cxxstd_values = ("11", "14", "17")
variant(
"cxxstd",
default="11",
values=_cxxstd_values,
multi=False,
description="Use the specified C++ standard when building",
)

variant("analysis", default=True, description="Enable analysis components")
variant("mpi", default=False, description="Enable MPI")
variant("python", default=False, description="Enable Python API")
variant("hepmc2", default=True, description="Enable HepMC (version 2.x) support")
variant("hepmc3", default=True, description="Enable HepMC (version 3.x) support")
variant("hepmc3root", default=False, description="Enable HepMC (version 3.1+) ROOT support")
variant("rivet", default=False, description="Enable Rivet support")
variant("fastjet", default=True, description="Enable FASTJET")
variant("openloops", default=False, description="Enable OpenLoops")
variant("recola", default=False, description="Enable Recola")
variant("lhole", default=False, description="Enable Les Houches One-Loop Generator interface")
variant("root", default=False, description="Enable ROOT support")
variant("lhapdf", default=True, description="Enable LHAPDF support")
variant("gzip", default=False, description="Enable gzip support")
variant("pythia", default=True, description="Enable fragmentation/decay interface to Pythia")
variant("blackhat", default=False, description="Enable BLACKHAT support")
variant("ufo", default=False, description="Enable UFO support")
variant("hztool", default=False, description="Enable HZTOOL support")
variant(
"libs",
default="shared,static",
values=("shared", "static"),
multi=True,
description="Build shared libs, static libs or both",
)
# cernlib not yet in spack
# variant('cernlib', default=False, description='Enable CERNLIB support')

variant("cms", default=False, description="Append CXXFLAGS used by CMS experiment")

# Note that the delphes integration seems utterly broken: https://sherpa.hepforge.org/trac/ticket/305

# autotools dependencies are needed at runtime to compile processes
# at least as long as sherpa is an autotools package
depends_on("autoconf")
depends_on("automake")
depends_on("libtool")
depends_on("m4")
depends_on("texinfo", type="build")
depends_on("sqlite")

depends_on("mpi", when="+mpi")
depends_on("python", when="+python")
depends_on("swig", when="+python", type="build")
depends_on("hepmc", when="+hepmc2")
depends_on("hepmc3", when="+hepmc3")
depends_on("hepmc3 +rootio", when="+hepmc3root")
depends_on("rivet", when="+rivet")
depends_on("fastjet", when="+fastjet")
depends_on("openloops", when="+openloops")
# sherpa builds with recola2 with the patch below,
# but the authors have validated only recola1
# see https://gitlab.com/sherpa-team/sherpa/-/issues/356
depends_on("recola@1", when="+recola")
depends_on("root", when="+root")
depends_on("lhapdf", when="+lhapdf")
depends_on("gzip", when="+gzip")
depends_on("pythia6", when="+pythia")
depends_on("blackhat", when="+blackhat")
depends_on("hztool", when="+hztool")
# depends_on('cernlib', when='+cernlib')

filter_compiler_wrappers("share/SHERPA-MC/makelibs")

for std in _cxxstd_values:
depends_on("root cxxstd=" + std, when="+root cxxstd=" + std)

def patch(self):
filter_file(
r"#include <sys/sysctl.h>",
"#ifdef ARCH_DARWIN\n#include <sys/sysctl.h>\n#endif",
"ATOOLS/Org/Run_Parameter.C",
)

if self.spec.satisfies("^recola@2:"):
filter_file(
r'#include "recola.h"',
'#include "recola.hpp"',
"AddOns/Recola/Recola_Interface.H",
string=True,
)

def configure_args(self):
args = []
args.append("--enable-binreloc")
args.append("--enable-hepevtsize=200000")
args.append("--with-sqlite3=" + self.spec["sqlite"].prefix)
args.extend(self.enable_or_disable("libs"))
args.extend(self.enable_or_disable("mpi"))
args.extend(self.enable_or_disable("pyext", variant="python"))
args.extend(self.enable_or_disable("analysis"))
args.extend(self.enable_or_disable("lhole"))
args.extend(self.enable_or_disable("gzip"))
args.extend(self.enable_or_disable("pythia"))
hepmc_root = lambda x: self.spec["hepmc"].prefix
args.extend(self.enable_or_disable("hepmc2", activation_value=hepmc_root))
if self.spec.satisfies("@3:"):
args.extend(self.enable_or_disable("hepmc3", activation_value="prefix"))
args.extend(self.enable_or_disable("rivet", activation_value="prefix"))
args.extend(self.enable_or_disable("lhapdf", activation_value="prefix"))
else:
# See https://gitlab.com/sherpa-team/sherpa/-/issues/348
if self.spec.satisfies("+hepmc3"):
args.append("--enable-hepmc3=" + self.spec["hepmc3"].prefix)
if self.spec.satisfies("+rivet"):
args.append("--enable-rivet=" + self.spec["rivet"].prefix)
if self.spec.satisfies("+lhapdf"):
args.append("--enable-lhapdf=" + self.spec["lhapdf"].prefix)

args.extend(self.enable_or_disable("fastjet", activation_value="prefix"))
args.extend(self.enable_or_disable("openloops", activation_value="prefix"))
args.extend(self.enable_or_disable("recola", activation_value="prefix"))
args.extend(self.enable_or_disable("root", activation_value="prefix"))

args.extend(self.enable_or_disable("hztool", activation_value="prefix"))
# args.extend(self.enable_or_disable('cernlib', activation_value='prefix'))
args.extend(self.enable_or_disable("blackhat", activation_value="prefix"))
args.extend(self.enable_or_disable("ufo"))

if self.spec.satisfies("+mpi"):
args.append("CC=" + self.spec["mpi"].mpicc)
args.append("MPICXX=" + self.spec["mpi"].mpicxx)
args.append("CXX=" + self.spec["mpi"].mpicxx)
args.append("FC=" + self.spec["mpi"].mpifc)

return args

def flag_handler(self, name, flags):
flags = list(flags)
if name == "cxxflags":
flags.append("-std=c++" + self.spec.variants["cxxstd"].value)

if "+cms" in self.spec:
flags.extend(["-fuse-cxa-atexit", "-O2"])
if self.spec.target.family == "x86_64":
flags.append("-m64")

return (None, None, flags)

# This may not be needed when this package is changed to be a CMake package
# since it's specific to makelibs
def install(self, spec, prefix):
# Make sure the path to the provided libtool is used instead of the system one
filter_file(
r"autoreconf -fi",
f"autoreconf -fi -I {self.spec['libtool'].prefix.share.aclocal}",
"AMEGIC++/Main/makelibs",
)
make("install")