Skip to content

Commit

Permalink
fix: only compile edm4eic_merge for podio < 0.17.4
Browse files Browse the repository at this point in the history
  • Loading branch information
wdconinc committed Jan 19, 2024
1 parent 6904444 commit c950b88
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 35 deletions.
75 changes: 40 additions & 35 deletions utils/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,40 +36,45 @@ install(TARGETS edm4eic_utils

if(CLI11_FOUND)

add_executable(edm4eic_merge src/merge.cpp)

target_compile_features(edm4eic_merge
PUBLIC cxx_auto_type
PUBLIC cxx_trailing_return_types
PUBLIC cxx_std_17
PRIVATE cxx_variadic_templates
)

target_compile_options(edm4eic_merge PRIVATE
-Wno-extra
-Wno-ignored-qualifiers
-Wno-overloaded-virtual
-Wno-shadow
)

target_include_directories(edm4eic_merge
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
PUBLIC $<INSTALL_INTERFACE:include>
)

target_link_libraries(edm4eic_merge
PUBLIC edm4eic
PUBLIC EDM4HEP::edm4hep
PUBLIC podio::podio podio::podioRootIO
PUBLIC ROOT::GenVector ROOT::MathCore)

install(TARGETS edm4eic_merge
EXPORT ${PROJECT_NAME}Targets
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
RUNTIME DESTINATION bin
INCLUDES DESTINATION include
)
if(${podio_VERSION} VERSION_LESS 0.17.4)

# EventStore-based merging
add_executable(edm4eic_event_merge src/event_merge.cpp)

target_compile_features(edm4eic_event_merge
PUBLIC cxx_auto_type
PUBLIC cxx_trailing_return_types
PUBLIC cxx_std_17
PRIVATE cxx_variadic_templates
)

target_compile_options(edm4eic_event_merge PRIVATE
-Wno-extra
-Wno-ignored-qualifiers
-Wno-overloaded-virtual
-Wno-shadow
)

target_include_directories(edm4eic_event_merge
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
PUBLIC $<INSTALL_INTERFACE:include>
)

target_link_libraries(edm4eic_event_merge
PUBLIC edm4eic
PUBLIC EDM4HEP::edm4hep
PUBLIC podio::podio podio::podioRootIO
PUBLIC ROOT::GenVector ROOT::MathCore)

install(TARGETS edm4eic_event_merge
EXPORT ${PROJECT_NAME}Targets
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
RUNTIME DESTINATION bin
INCLUDES DESTINATION include
)

endif()

endif()
File renamed without changes.

0 comments on commit c950b88

Please sign in to comment.