From 802a6b0121955aec9ccee64134e20b3a085d8ec2 Mon Sep 17 00:00:00 2001 From: lintao <lintao51@gmail.com> Date: Tue, 22 Dec 2020 23:56:19 +0800 Subject: [PATCH] WIP: migrate DetSimCore --- Simulation/CMakeLists.txt | 2 +- Simulation/DetSimCore/CMakeLists.txt | 38 +++++++++++---------------- Simulation/DetSimCore/src/DetSimAlg.h | 2 +- 3 files changed, 18 insertions(+), 24 deletions(-) diff --git a/Simulation/CMakeLists.txt b/Simulation/CMakeLists.txt index 6cb2318c..cfb46bf8 100644 --- a/Simulation/CMakeLists.txt +++ b/Simulation/CMakeLists.txt @@ -1,6 +1,6 @@ #add_subdirectory(DetSimAna) -#add_subdirectory(DetSimCore) +add_subdirectory(DetSimCore) #add_subdirectory(DetSimDedx) #add_subdirectory(DetSimFastModel) #add_subdirectory(DetSimGeom) diff --git a/Simulation/DetSimCore/CMakeLists.txt b/Simulation/DetSimCore/CMakeLists.txt index 49ee4777..92e5dfda 100644 --- a/Simulation/DetSimCore/CMakeLists.txt +++ b/Simulation/DetSimCore/CMakeLists.txt @@ -1,14 +1,7 @@ -gaudi_subdir(DetSimCore v0r0) - -gaudi_depends_on_subdirs( - k4FWCore - Simulation/DetSimInterface -) - find_package(Geant4 REQUIRED ui_all vis_all) include(${Geant4_USE_FILE}) -find_package(podio REQUIRED) + find_package(EDM4HEP REQUIRED) find_package(DD4hep COMPONENTS DDG4 REQUIRED) @@ -27,18 +20,19 @@ set(DetSimCore_srcs message(" Geant4_LIBRARIES: ${Geant4_LIBRARIES}") -gaudi_add_module(DetSimCore ${DetSimCore_srcs} - INCLUDE_DIRS - # DetSimInterface - # GaudiKernel - # Geant4 - # plcio ${plcio_INCLUDE_DIRS} ${podio_INCLUDE_DIRS} - LINK_LIBRARIES - DetSimInterface - GaudiKernel - # Geant4 - # ${Geant4_LIBRARIES} - DD4hep ${DD4hep_COMPONENT_LIBRARIES} - EDM4HEP::edm4hep EDM4HEP::edm4hepDict - # podio +gaudi_add_module(DetSimCore + SOURCES ${DetSimCore_srcs} + LINK DetSimInterface + Gaudi::GaudiKernel + ${Geant4_LIBRARIES} + ${DD4hep_COMPONENT_LIBRARIES} + EDM4HEP::edm4hep EDM4HEP::edm4hepDict ) + +install(TARGETS DetSimCore + EXPORT CEPCSWTargets + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT bin + LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" COMPONENT shlib + COMPONENT dev) + + diff --git a/Simulation/DetSimCore/src/DetSimAlg.h b/Simulation/DetSimCore/src/DetSimAlg.h index 86754631..36646d9e 100644 --- a/Simulation/DetSimCore/src/DetSimAlg.h +++ b/Simulation/DetSimCore/src/DetSimAlg.h @@ -5,7 +5,7 @@ #include <vector> #include <GaudiKernel/Algorithm.h> -#include <GaudiKernel/Property.h> +#include <Gaudi/Property.h> #include <GaudiKernel/ToolHandle.h> #include <DetSimInterface/IDetSimSvc.h> -- GitLab