From 42f64d710fb25af363e2ed9a18b94bae1537a20f Mon Sep 17 00:00:00 2001 From: Valentin Volkl <valentin.volkl@cern.ch> Date: Fri, 17 Sep 2021 13:29:21 +0200 Subject: [PATCH] fixes for compilation with clang12 --- .gitignore | 1 + Analysis/TrackInspect/CMakeLists.txt | 1 + Detector/GeomSvc/src/GeomSvc.cpp | 4 ++-- Detector/GeomSvc/src/GeomSvc.h | 1 - Reconstruction/RecGenfitAlg/CMakeLists.txt | 1 + Reconstruction/Tracking/CMakeLists.txt | 1 + Service/GearSvc/src/GearSvc.h | 1 - Simulation/DetSimAna/CMakeLists.txt | 1 + Simulation/DetSimCore/CMakeLists.txt | 1 + Utilities/KalDet/CMakeLists.txt | 2 ++ 10 files changed, 10 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index f3b5a1fd..ff3f1269 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ build.* +spack* ./Generator/output/ ./Generator/options/ diff --git a/Analysis/TrackInspect/CMakeLists.txt b/Analysis/TrackInspect/CMakeLists.txt index fa42c050..a004d010 100644 --- a/Analysis/TrackInspect/CMakeLists.txt +++ b/Analysis/TrackInspect/CMakeLists.txt @@ -5,6 +5,7 @@ gaudi_add_module(TrackInspect LINK DataHelperLib Gaudi::GaudiKernel EDM4HEP::edm4hep + k4FWCore::k4FWCore ${ROOT_LIBRARIES} ${CLHEP_LIBRARIES} ) diff --git a/Detector/GeomSvc/src/GeomSvc.cpp b/Detector/GeomSvc/src/GeomSvc.cpp index 878d60c8..54736e6c 100644 --- a/Detector/GeomSvc/src/GeomSvc.cpp +++ b/Detector/GeomSvc/src/GeomSvc.cpp @@ -125,7 +125,7 @@ const std::map<std::string,double>& GeomSvc::getDetParameters(std::string name){ if(m_detParameters.find(name)!=m_detParameters.end()) return m_detParameters[name]; else{ char message[200]; - sprintf(message,"GeomSvc has not the parameter set named %s", name); + sprintf(message,"GeomSvc has not the parameter set named %s", name.c_str()); throw std::runtime_error(message); } } @@ -136,7 +136,7 @@ double GeomSvc::getDetParameter(std::string set_name, std::string par_name){ if(it->second.find(par_name)!=it->second.end()) return it->second[par_name]; } char message[200]; - sprintf(message,"GeomSvc has not the parameter named %s in set %s", par_name, set_name); + sprintf(message,"GeomSvc has not the parameter named %s in set %s", par_name.c_str(), set_name.c_str()); throw std::runtime_error(message); } diff --git a/Detector/GeomSvc/src/GeomSvc.h b/Detector/GeomSvc/src/GeomSvc.h index 379d5b08..4ef39d2f 100644 --- a/Detector/GeomSvc/src/GeomSvc.h +++ b/Detector/GeomSvc/src/GeomSvc.h @@ -19,7 +19,6 @@ #include <gearimpl/ZPlanarParametersImpl.h> #include <gearimpl/GearParametersImpl.h> -class dd4hep::DetElement; class TGeoNode; class GeomSvc: public extends<Service, IGeomSvc> { diff --git a/Reconstruction/RecGenfitAlg/CMakeLists.txt b/Reconstruction/RecGenfitAlg/CMakeLists.txt index 86615603..566801d1 100644 --- a/Reconstruction/RecGenfitAlg/CMakeLists.txt +++ b/Reconstruction/RecGenfitAlg/CMakeLists.txt @@ -19,6 +19,7 @@ gaudi_add_module(RecGenfitAlg EDM4HEP::edm4hep EDM4HEP::edm4hepDict GenFit::genfit2 + k4FWCore::k4FWCore ) target_include_directories(RecGenfitAlg PUBLIC diff --git a/Reconstruction/Tracking/CMakeLists.txt b/Reconstruction/Tracking/CMakeLists.txt index 5123c292..f3e77b47 100644 --- a/Reconstruction/Tracking/CMakeLists.txt +++ b/Reconstruction/Tracking/CMakeLists.txt @@ -15,6 +15,7 @@ gaudi_add_module(Tracking ${LCIO_LIBRARIES} DetSegmentation EDM4HEP::edm4hep EDM4HEP::edm4hepDict + k4FWCore::k4FWCore ) target_include_directories(Tracking PUBLIC diff --git a/Service/GearSvc/src/GearSvc.h b/Service/GearSvc/src/GearSvc.h index ad0e82b6..3048526c 100644 --- a/Service/GearSvc/src/GearSvc.h +++ b/Service/GearSvc/src/GearSvc.h @@ -4,7 +4,6 @@ #include "GearSvc/IGearSvc.h" #include <GaudiKernel/Service.h> #include "DD4hep/Detector.h" -class dd4hep::DetElement; class TGeoNode; class GearSvc : public extends<Service, IGearSvc> diff --git a/Simulation/DetSimAna/CMakeLists.txt b/Simulation/DetSimAna/CMakeLists.txt index 794bcc2f..883dfd82 100644 --- a/Simulation/DetSimAna/CMakeLists.txt +++ b/Simulation/DetSimAna/CMakeLists.txt @@ -8,6 +8,7 @@ gaudi_add_module(DetSimAna ${DD4hep_COMPONENT_LIBRARIES} Gaudi::GaudiKernel EDM4HEP::edm4hep EDM4HEP::edm4hepDict + k4FWCore::k4FWCore ) install(TARGETS DetSimAna diff --git a/Simulation/DetSimCore/CMakeLists.txt b/Simulation/DetSimCore/CMakeLists.txt index 9c225fc7..933406ce 100644 --- a/Simulation/DetSimCore/CMakeLists.txt +++ b/Simulation/DetSimCore/CMakeLists.txt @@ -20,6 +20,7 @@ gaudi_add_module(DetSimCore Gaudi::GaudiKernel ${Geant4_LIBRARIES} ${DD4hep_COMPONENT_LIBRARIES} + k4FWCore::k4FWCore EDM4HEP::edm4hep EDM4HEP::edm4hepDict ) diff --git a/Utilities/KalDet/CMakeLists.txt b/Utilities/KalDet/CMakeLists.txt index 12fbb253..3b749771 100644 --- a/Utilities/KalDet/CMakeLists.txt +++ b/Utilities/KalDet/CMakeLists.txt @@ -72,6 +72,8 @@ gaudi_add_library(KalDetLib ${GEAR_LIBRARIES} EDM4HEP::edm4hep EDM4HEP::edm4hepDict ${DD4hep_COMPONENT_LIBRARIES} + GenFit::genfit2 + ) install(TARGETS KalDetLib -- GitLab