Last change
on this file since b30245b was 0feae05, checked in by Valentin Volkl <valentin.volkl@…>, 4 years ago |
relocatable headers for dictionaries: workaround for ROOT 5
|
-
Property mode
set to
100644
|
File size:
1.2 KB
|
Line | |
---|
1 | include_directories(
|
---|
2 | ${CMAKE_SOURCE_DIR}
|
---|
3 | ${ROOT_INCLUDE_DIRS}
|
---|
4 | ${DelphesExternals_INCLUDE_DIR}
|
---|
5 | )
|
---|
6 |
|
---|
7 | file(GLOB sources *.cc)
|
---|
8 | file(GLOB headers *.h)
|
---|
9 | list(REMOVE_ITEM headers ${CMAKE_CURRENT_SOURCE_DIR}/ClassesLinkDef.h)
|
---|
10 |
|
---|
11 | # the macro invocation for ROOT6 ensures that the headers are relocatable
|
---|
12 | if (NOT ${ROOT_VERSION} VERSION_LESS "6.0.0")
|
---|
13 | DELPHES_GENERATE_DICTIONARY(ClassesDict
|
---|
14 | classes/DelphesModule.h
|
---|
15 | classes/DelphesFactory.h
|
---|
16 | classes/SortableObject.h
|
---|
17 | classes/DelphesClasses.h
|
---|
18 | LINKDEF ClassesLinkDef.h
|
---|
19 | )
|
---|
20 | else()
|
---|
21 | # for ROOT5 the above fails, keep the following as workaround
|
---|
22 | DELPHES_GENERATE_DICTIONARY(ClassesDict
|
---|
23 | ${CMAKE_CURRENT_SOURCE_DIR}/DelphesModule.h
|
---|
24 | ${CMAKE_CURRENT_SOURCE_DIR}/DelphesFactory.h
|
---|
25 | ${CMAKE_CURRENT_SOURCE_DIR}/SortableObject.h
|
---|
26 | ${CMAKE_CURRENT_SOURCE_DIR}/DelphesClasses.h
|
---|
27 | LINKDEF ClassesLinkDef.h
|
---|
28 | )
|
---|
29 | endif()
|
---|
30 |
|
---|
31 | add_library(classes OBJECT ${sources} ClassesDict.cxx)
|
---|
32 |
|
---|
33 | # install public headers
|
---|
34 | install(FILES ${headers} DESTINATION include/classes)
|
---|
35 |
|
---|
36 | # install pcms if they are created
|
---|
37 | if (NOT ${ROOT_VERSION} VERSION_LESS "6.0.0")
|
---|
38 | install(FILES
|
---|
39 | ${PROJECT_BINARY_DIR}/classes/libClassesDict_rdict.pcm
|
---|
40 | DESTINATION lib)
|
---|
41 | endif()
|
---|
Note:
See
TracBrowser
for help on using the repository browser.