dd4hep: cleanup recipe, remove deprecated versions and patches (#44110)
Co-authored-by: jmcarcell <jmcarcell@users.noreply.github.com>
This commit is contained in:
		 Juan Miguel Carceller
					Juan Miguel Carceller
				
			
				
					committed by
					
						 GitHub
						GitHub
					
				
			
			
				
	
			
			
			 GitHub
						GitHub
					
				
			
						parent
						
							567566da08
						
					
				
				
					commit
					f73d7d2dce
				
			| @@ -44,76 +44,9 @@ class Dd4hep(CMakePackage): | |||||||
|     version("1.18", sha256="1e909a42b969dfd966224fa8ab1eca5aa05136baf3c00a140f2f6d812b497152") |     version("1.18", sha256="1e909a42b969dfd966224fa8ab1eca5aa05136baf3c00a140f2f6d812b497152") | ||||||
|     version("1.17", sha256="036a9908aaf1e13eaf5f2f43b6f5f4a8bdda8183ddc5befa77a4448dbb485826") |     version("1.17", sha256="036a9908aaf1e13eaf5f2f43b6f5f4a8bdda8183ddc5befa77a4448dbb485826") | ||||||
|     version("1.16.1", sha256="c8b1312aa88283986f89cc008d317b3476027fd146fdb586f9f1fbbb47763f1a") |     version("1.16.1", sha256="c8b1312aa88283986f89cc008d317b3476027fd146fdb586f9f1fbbb47763f1a") | ||||||
|     # versions older than 1.16.1 are no longer supported |  | ||||||
|     # (they need several patches like https://github.com/AIDASoft/DD4hep/pull/796) |  | ||||||
|     version( |  | ||||||
|         "1.16", |  | ||||||
|         sha256="ea9755cd255cf1b058e0e3cd743101ca9ca5ff79f4c60be89f9ba72b1ae5ec69", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.15", |  | ||||||
|         sha256="992a24bd4b3dfaffecec9d1c09e8cde2c7f89d38756879a47b23208242f4e352", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.14.1", |  | ||||||
|         sha256="5b5742f1e23c2b36d3174cca95f810ce909c0eb66f3d6d7acb0ba657819e6717", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.14", |  | ||||||
|         sha256="b603aa3c0db8dda392253aa71fa4a0f0c3c9715d47df0b895d45c1e8849f4895", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.13.1", |  | ||||||
|         sha256="83fa70cd74ce93b2f52f098388dff58d179f05ace5b50aea3f408bb8abf7cb73", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.13", |  | ||||||
|         sha256="0b1f9d902ebe21a9178c1e41204c066b29f68c8836fd1d03a9ce979811ddb295", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.12.1", |  | ||||||
|         sha256="85e8c775ec03c499ce10911e228342e757c81ce9ef2a9195cb253b85175a2e93", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     # these version won't build with +ddcad as the subpackage doesn't exit yet |  | ||||||
|     version( |  | ||||||
|         "1.12", |  | ||||||
|         sha256="133a1fb8ce0466d2482f3ebb03e60b3bebb9b2d3e33d14ba15c8fbb91706b398", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.11.2", |  | ||||||
|         sha256="96a53dd26cb8df11c6dae54669fbc9cc3c90dd47c67e07b24be9a1341c95abc4", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.11.1", |  | ||||||
|         sha256="d7902dd7f6744bbda92f6e303ad5a3410eec4a0d2195cdc86f6c1167e72893f0", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.11", |  | ||||||
|         sha256="25643296f15f9d11ad4ad550b7c3b92e8974fc56f1ee8e4455501010789ae7b6", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
|     version( |  | ||||||
|         "1.10", |  | ||||||
|         sha256="1d6b5d1c368dc8bcedd9c61b7c7e1a44bad427f8bd34932516aff47c88a31d95", |  | ||||||
|         deprecated=True, |  | ||||||
|     ) |  | ||||||
| 
 | 
 | ||||||
|     generator("ninja") |     generator("ninja") | ||||||
| 
 | 
 | ||||||
|     # Workarounds for various TBB issues in DD4hep v1.11 |  | ||||||
|     # See https://github.com/AIDASoft/DD4hep/pull/613 . |  | ||||||
|     patch("tbb-workarounds.patch", when="@1.11") |  | ||||||
|     patch("tbb2.patch", when="@1.12.1") |  | ||||||
|     # Workaround for failing build file generation in some cases |     # Workaround for failing build file generation in some cases | ||||||
|     # See https://github.com/spack/spack/issues/24232 |     # See https://github.com/spack/spack/issues/24232 | ||||||
|     patch("cmake_language.patch", when="@:1.17") |     patch("cmake_language.patch", when="@:1.17") | ||||||
| @@ -189,7 +122,7 @@ class Dd4hep(CMakePackage): | |||||||
|     # See https://github.com/AIDASoft/DD4hep/pull/771 and https://github.com/AIDASoft/DD4hep/pull/876 |     # See https://github.com/AIDASoft/DD4hep/pull/771 and https://github.com/AIDASoft/DD4hep/pull/876 | ||||||
|     conflicts( |     conflicts( | ||||||
|         "^cmake@3.16:3.17.2", |         "^cmake@3.16:3.17.2", | ||||||
|         when="@1.15:1.18", |         when="@:1.18", | ||||||
|         msg="cmake version with buggy FindPython breaks dd4hep cmake config", |         msg="cmake version with buggy FindPython breaks dd4hep cmake config", | ||||||
|     ) |     ) | ||||||
|     conflicts("~ddrec+dddetectors", msg="Need to enable +ddrec to build +dddetectors.") |     conflicts("~ddrec+dddetectors", msg="Need to enable +ddrec to build +dddetectors.") | ||||||
|   | |||||||
| @@ -1,41 +0,0 @@ | |||||||
| diff --git a/DDDigi/CMakeLists.txt b/DDDigi/CMakeLists.txt |  | ||||||
| index e6fb1096..88eb5c92 100644 |  | ||||||
| --- a/DDDigi/CMakeLists.txt |  | ||||||
| +++ b/DDDigi/CMakeLists.txt |  | ||||||
| @@ -34,12 +34,10 @@ target_include_directories(DDDigi |  | ||||||
|   |  | ||||||
|  FIND_PACKAGE(TBB QUIET) |  | ||||||
|  if(TBB_FOUND) |  | ||||||
| -  dd4hep_print( "|++> TBB_INCLUDE_DIR -->  ${TBB_INCLUDE_DIR}") |  | ||||||
| -  dd4hep_print( "|++> TBB_LIBRARY     -->  ${TBB_LIBRARY}") |  | ||||||
| +  dd4hep_print( "|++> TBB_IMPORTED_TARGETS -->  ${TBB_IMPORTED_TARGETS}") |  | ||||||
|    dd4hep_print( "|++> TBB found. DDDigi will run multi threaded.") |  | ||||||
|    target_compile_definitions(DDDigi PUBLIC DD4HEP_USE_TBB) |  | ||||||
| -  target_link_libraries(DDDigi ${TBB_LIBRARY}) |  | ||||||
| -  target_include_directories(DDDigi ${TBB_INCLUDE_DIRS}) |  | ||||||
| +  target_link_libraries(DDDigi PUBLIC ${TBB_IMPORTED_TARGETS}) |  | ||||||
|  else() |  | ||||||
|    dd4hep_print( "|++> TBB not found. DDDigi will only work single threaded.") |  | ||||||
|  endif() |  | ||||||
| diff --git a/DDDigi/src/DigiKernel.cpp b/DDDigi/src/DigiKernel.cpp |  | ||||||
| index d62c6694..f2c2e86c 100644 |  | ||||||
| --- a/DDDigi/src/DigiKernel.cpp |  | ||||||
| +++ b/DDDigi/src/DigiKernel.cpp |  | ||||||
| @@ -91,7 +91,7 @@ public: |  | ||||||
|    DigiEventAction*  action = 0; |  | ||||||
|    Wrapper(DigiContext& c, DigiEventAction* a) |  | ||||||
|      : context(c), action(a) {} |  | ||||||
| -  Wrapper(Wrapper&& copy) = delete; |  | ||||||
| +  Wrapper(Wrapper&& copy) = default; |  | ||||||
|    Wrapper(const Wrapper& copy) = default; |  | ||||||
|    Wrapper& operator=(Wrapper&& copy) = delete; |  | ||||||
|    Wrapper& operator=(const Wrapper& copy) = delete; |  | ||||||
| @@ -111,7 +111,7 @@ class DigiKernel::Processor { |  | ||||||
|    DigiKernel& kernel; |  | ||||||
|  public:  |  | ||||||
|    Processor(DigiKernel& k) : kernel(k) {} |  | ||||||
| -  Processor(Processor&& l) = delete; |  | ||||||
| +  Processor(Processor&& l) = default; |  | ||||||
|    Processor(const Processor& l) = default; |  | ||||||
|    void operator()()  const { |  | ||||||
|      int todo = 1; |  | ||||||
| @@ -1,14 +0,0 @@ | |||||||
| diff --git a/DDDigi/src/DigiKernel.cpp b/DDDigi/src/DigiKernel.cpp |  | ||||||
| index f2c2e86c..f168ef9b 100644 |  | ||||||
| --- a/DDDigi/src/DigiKernel.cpp |  | ||||||
| +++ b/DDDigi/src/DigiKernel.cpp |  | ||||||
| @@ -273,7 +273,7 @@ void DigiKernel::submit(const DigiAction::Actors<DigiEventAction>& actions, Digi |  | ||||||
|    if ( parallel )   { |  | ||||||
|      tbb::task_group que; |  | ||||||
|      for ( auto* i : actions ) |  | ||||||
| -      que.run(Wrapper(context, *i)); |  | ||||||
| +      que.run(Wrapper(context, i)); |  | ||||||
|      que.wait(); |  | ||||||
|      goto print_stamp; |  | ||||||
|    } |  | ||||||
|  |  | ||||||
		Reference in New Issue
	
	Block a user