From 2aa58bc053abc685e42b129f5287a49e4d13faa6 Mon Sep 17 00:00:00 2001 From: Kyle Knoepfel Date: Mon, 13 Nov 2023 11:28:03 -0600 Subject: [PATCH] Disallow C++17 for art-suite@develop, etc. --- packages/art-root-io/package.py | 7 ++++--- packages/art/package.py | 5 +++-- packages/canvas-root-io/package.py | 3 ++- packages/canvas/package.py | 3 ++- packages/cetlib-except/package.py | 3 ++- packages/cetlib/package.py | 5 +++-- packages/critic/package.py | 3 ++- packages/fhicl-cpp/package.py | 10 +++++++++- packages/gallery/package.py | 3 ++- packages/hep-concurrency/package.py | 3 ++- packages/messagefacility/package.py | 3 ++- 11 files changed, 33 insertions(+), 15 deletions(-) diff --git a/packages/art-root-io/package.py b/packages/art-root-io/package.py index a4a1b016..b209e329 100755 --- a/packages/art-root-io/package.py +++ b/packages/art-root-io/package.py @@ -25,7 +25,7 @@ class ArtRootIo(CMakePackage): version("1.12.04", sha256="912e01cb3f253de244548a52ee4f9e31b2eb6d1af9bd7cb33e48bab064651273") version("1.12.03", sha256="2281435aa910085902f9a8d14c90d69ee980a980637bbb4bb2e1aad1ab5f02af") version("1.12.02", sha256="f7fa60cad2947fa135cdd52cb5d39d3e871cca246181288734745067c7c3f555") - version("1.12.01", sha256="d6594b039567c5f4a7053678d70b82e543a19fef989f0957ca6a6e4862372511") + version("1.12.01", sha256="d6594b039567c5f4a7053678d70b82e543a19fef989f0957ca6a6e4862372511") version("1.11.03", sha256="a29b64b07709ac1560ccc1b9570cc8a4197a8834d2b9dfea5bbfd293231d4a20") version("1.11.00", sha256="1134d1c1e69045249bf678e6e07728f06035ee2ee982af5155184d1c271468ae") version("1.08.05", sha256="77f58e4200f699dcb324a3a9fc9e59562d2a1721a34a6db43fdb435853890d21") @@ -40,6 +40,7 @@ class ArtRootIo(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("art") depends_on("boost+filesystem+date_time+program_options") @@ -66,11 +67,11 @@ class ArtRootIo(CMakePackage): def url_for_version(self, version): url = "https://github.com/art-framework-suite/art-root-io/archive/refs/tags/v{0}.tar.gz" return url.format(version.underscored) - + def cmake_args(self): return [ "--trace-expand", - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/art/package.py b/packages/art/package.py index 3d97a94d..8e489856 100755 --- a/packages/art/package.py +++ b/packages/art/package.py @@ -46,9 +46,10 @@ class Art(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("boost+date_time+graph+program_options+regex") - depends_on("boost+filesystem+json+test+thread", type=("build")) + depends_on("boost+filesystem+json+test+thread cxxstd=11", type=("build")) depends_on("boost+graph+test", type=("test")) depends_on("canvas") depends_on("catch2@2.3.0", type=("build", "test"), when="@:3.11.99") @@ -77,7 +78,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/canvas-root-io/package.py b/packages/canvas-root-io/package.py index 548d552f..91f4c83d 100755 --- a/packages/canvas-root-io/package.py +++ b/packages/canvas-root-io/package.py @@ -39,6 +39,7 @@ class CanvasRootIo(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("boost+thread") depends_on("canvas") @@ -61,7 +62,7 @@ class CanvasRootIo(CMakePackage): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/canvas/package.py b/packages/canvas/package.py index 99af10ed..7bcfbc6c 100755 --- a/packages/canvas/package.py +++ b/packages/canvas/package.py @@ -40,6 +40,7 @@ class Canvas(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("boost+date_time+test") depends_on("cetlib") @@ -64,7 +65,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/cetlib-except/package.py b/packages/cetlib-except/package.py index 5356f07f..2006848a 100644 --- a/packages/cetlib-except/package.py +++ b/packages/cetlib-except/package.py @@ -36,6 +36,7 @@ class CetlibExcept(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("catch2@2.3.0:", type=("build", "test")) depends_on("cetmodules@3.19.02:", type="build") @@ -52,7 +53,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/cetlib/package.py b/packages/cetlib/package.py index dca6b881..003580cc 100644 --- a/packages/cetlib/package.py +++ b/packages/cetlib/package.py @@ -24,7 +24,7 @@ class Cetlib(CMakePackage): version("3.18.01", sha256="7e8b39e6ad0dce26d7fa41985d962fd2f97113403511bad0134c86ccee0e17ae") version("3.18.00", sha256="bf559b054af5881ef9e1b7ef91bb722fd255e178edbeca204d201584ee277fee") version("3.17.01", sha256="c29add5c9085e1fadc8f5fbdb1cd9b666d2290bd252022cef1feb0c30368d597") - version("3.17.00", sha256="04160b9607948b329465b60271ca735c449f3bf7d53e31a44ec3107cc6aafe26") + version("3.17.00", sha256="04160b9607948b329465b60271ca735c449f3bf7d53e31a44ec3107cc6aafe26") version("3.16.00", sha256="a0e670a5144b215c9a6641d0b9b35512790d9ba4b638e213651f5040417f4070") version("3.13.04", sha256="40ca829cfb172f6cbf516bd3427fc7b7e893f9c916d969800261194610c45edf") version("develop", branch="develop", get_full_repo=True) @@ -37,6 +37,7 @@ class Cetlib(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") patch("test_build.patch",when="@:3.16.00") @@ -64,7 +65,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/critic/package.py b/packages/critic/package.py index 74715a63..47993570 100644 --- a/packages/critic/package.py +++ b/packages/critic/package.py @@ -53,6 +53,7 @@ class Critic(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("art") depends_on("art-root-io") @@ -78,7 +79,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/fhicl-cpp/package.py b/packages/fhicl-cpp/package.py index 97a4fafa..ed8916f6 100644 --- a/packages/fhicl-cpp/package.py +++ b/packages/fhicl-cpp/package.py @@ -38,6 +38,7 @@ class FhiclCpp(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("boost+program_options+test") depends_on("cetlib") @@ -64,7 +65,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] @@ -74,3 +75,10 @@ def setup_build_environment(self, env): env.prepend_path("PATH", os.path.join(prefix, "bin")) # Cleanup sanitize_environments(env, "PATH") + + def setup_run_environment(self, env): + bindir = self.prefix.bin + # Bash completions. + env.from_sourcing_file(os.path.join(bindir, "fhicl-dump_completions")) + env.from_sourcing_file(os.path.join(bindir, "fhicl-expand_completions")) + env.from_sourcing_file(os.path.join(bindir, "fhicl-get_completions")) diff --git a/packages/gallery/package.py b/packages/gallery/package.py index ed215fff..3ddda937 100644 --- a/packages/gallery/package.py +++ b/packages/gallery/package.py @@ -39,6 +39,7 @@ class Gallery(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("canvas") depends_on("canvas-root-io") @@ -59,7 +60,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/hep-concurrency/package.py b/packages/hep-concurrency/package.py index 5b186fbf..8e667414 100644 --- a/packages/hep-concurrency/package.py +++ b/packages/hep-concurrency/package.py @@ -37,6 +37,7 @@ class HepConcurrency(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("catch2@3:", when="@1.09.00:", type=("build", "test")) depends_on("catch2@2.3.0", when="@:1.08.99", type=("build", "test")) @@ -58,7 +59,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ] diff --git a/packages/messagefacility/package.py b/packages/messagefacility/package.py index 12de2e30..9d35dca2 100644 --- a/packages/messagefacility/package.py +++ b/packages/messagefacility/package.py @@ -42,6 +42,7 @@ class Messagefacility(CMakePackage): sticky=True, description="C++ standard", ) + conflicts("cxxstd=17", when="@develop") depends_on("boost+filesystem+program_options+system") depends_on("catch2") @@ -65,7 +66,7 @@ def url_for_version(self, version): def cmake_args(self): return [ - "--preset", "default", + "--preset", "default", self.define_from_variant("CMAKE_CXX_STANDARD", "cxxstd"), ]