Skip to content
Snippets Groups Projects
Commit d348512f authored by zoujh@ihep.ac.cn's avatar zoujh@ihep.ac.cn
Browse files

generate dictionary for plcio

parent 92c6b5fa
No related branches found
No related tags found
No related merge requests found
gaudi_subdir(Event v0r0)
# Declare PODIO dependency
find_package(podio REQUIRED HINTS $ENV{PODIO})
# Make sure the library is found.
# Not the case if LD_LIBRARY_PATH is wrong
## Make sure the library is found.
## Not the case if LD_LIBRARY_PATH is wrong
find_library(PODIOLIB podio PATHS ${podio_DIR}/../lib)
if (NOT PODIOLIB)
message(FATAL_ERROR "libpodio.so(dylib) cannot be found dynamically. Make sure you have set up your environment to use PODIO")
......@@ -16,18 +17,32 @@ include_directories(
${podio_INCLUDE_DIRS}
)
set(Event_srcs
src/*.cc
)
# Declare ROOT dependency
list(APPEND CMAKE_PREFIX_PATH $ENV{ROOTSYS})
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
find_package(ROOT REQUIRED COMPONENTS RIO Tree)
include_directories(${ROOT_INCLUDE_DIR})
include(${ROOT_USE_FILE})
# Settings
file(GLOB sources src/*.cc)
file(GLOB headers Event/*.h)
include_directories(Event)
# Dictionary and Modules
REFLEX_GENERATE_DICTIONARY(Event ${headers} SELECTION src/selection.xml)
add_library(EventDict SHARED Event.cxx)
add_dependencies(EventDict Event-dictgen)
target_link_libraries(EventDict Event ROOT::Core)
add_library(Event SHARED ${sources} ${headers})
target_link_libraries(Event podio ROOT::RIO ROOT::Tree)
# Headers and Libraries
gaudi_install_headers(Event)
# Modules
gaudi_add_module(Event ${Event_srcs}
INCLUDE_DIRS Event
#LINK_LIBRARIES GaudiKernel
)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/EventDict.rootmap DESTINATION lib)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/Event_rdict.pcm DESTINATION lib)
# Unit tests
#gaudi_add_test(HelloAlg
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment