Skip to content

Commit

Permalink
Remove a CMake warning and make it easier to build with ROOT
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarcell committed Sep 12, 2023
1 parent 1882557 commit f18857d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.3)
cmake_minimum_required(VERSION 3.5)

project(k4SimDelphes)

Expand Down Expand Up @@ -78,6 +78,7 @@ endif()
#--- Non-optional Dependencies ------------------------------------------------
find_package(Delphes REQUIRED)
find_package(EDM4HEP REQUIRED)
find_package(ROOT REQUIRED)

#--- optional dependencies
if(BUILD_PYTHIA_READER OR BUILD_EVTGEN_READER)
Expand Down
4 changes: 2 additions & 2 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ target_include_directories(compare_delphes_converter_outputs
${PROJECT_SOURCE_DIR}/converter/src #for delphesHelpers
${PROJECT_SOURCE_DIR}/converter/include
)
target_link_libraries(compare_delphes_converter_outputs PRIVATE EDM4HEP::edm4hep ${DELPHES_LIBRARY} podio::podioRootIO ROOT::Physics)
target_link_libraries(compare_delphes_converter_outputs PRIVATE EDM4HEP::edm4hep EDM4HEP::kinematics ${DELPHES_LIBRARY} podio::podioRootIO ROOT::Core ROOT::MathCore ROOT::Physics)

function(ADD_COMPARISON_TEST name converter)
# Check if we have the standalone Delphes application available for the
Expand All @@ -29,7 +29,7 @@ function(ADD_COMPARISON_TEST name converter)
COMMAND bash -x ${PROJECT_SOURCE_DIR}/tests/testDriver.sh ${converter} ${ARGN})

set_property(TEST ${name} PROPERTY ENVIRONMENT
LD_LIBRARY_PATH=$<TARGET_FILE_DIR:DelphesEDM4HepConverter>:$<TARGET_FILE_DIR:EDM4HEP::edm4hepDict>:$<TARGET_FILE_DIR:podio::podioDict>:$<TARGET_FILE_DIR:ROOT::RIO>:$ENV{LD_LIBRARY_PATH}
LD_LIBRARY_PATH=$<TARGET_FILE_DIR:DelphesEDM4HepConverter>:$<TARGET_FILE_DIR:EDM4HEP::edm4hep>:$<TARGET_FILE_DIR:podio::podio>:$<TARGET_FILE_DIR:ROOT::RIO>:$ENV{LD_LIBRARY_PATH}
PATH=$<TARGET_FILE_DIR:${converter}>:${DELPHES_BINARY_DIR}:$ENV{PATH}
COMPARE=$<TARGET_FILE:compare_delphes_converter_outputs>
)
Expand Down

0 comments on commit f18857d

Please sign in to comment.