-
Notifications
You must be signed in to change notification settings - Fork 7
/
CMakeLists.txt
58 lines (44 loc) · 2.74 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
project(h-tautau)
cmake_minimum_required(VERSION 3.6)
get_filename_component(AnalysisTools_DIR "${PROJECT_SOURCE_DIR}/../AnalysisTools" ABSOLUTE)
include("${AnalysisTools_DIR}/cmake/include/common.cmake")
file(GLOB_RECURSE ANA_TOOLS_SRC "${AnalysisTools_DIR}/*.cpp")
add_library(AnalysisTools STATIC ${ANA_TOOLS_SRC} "${RootDict}")
add_dependencies(AnalysisTools GenerateRootDict)
file(GLOB_RECURSE HTT_UTILITIES_SRC "${CMSSW_BASE_SRC}/HTT-utilities/*.cc")
add_library(HTT-utilities STATIC ${HTT_UTILITIES_SRC})
set_source_files_properties(${HTT_UTILITIES_SRC} PROPERTIES COMPILE_FLAGS "-w")
file(GLOB_RECURSE TauAnalysisTool_SRC "${CMSSW_BASE_SRC}/TauAnalysisTools/TauTriggerSFs/src/*.cc")
add_library(TauAnalysisTools STATIC ${TauAnalysisTool_SRC})
file(GLOB_RECURSE VBFTriggerSFs_SRC "${CMSSW_BASE_SRC}/VBFTriggerSFs/VBFTriggerSFs/src/*.cc")
add_library(VBFTriggerSFs STATIC ${VBFTriggerSFs_SRC})
target_include_directories(VBFTriggerSFs PRIVATE "${CMSSW_BASE_SRC}/VBFTriggerSFs/VBFTriggerSFs/interface")
target_include_directories(VBFTriggerSFs PRIVATE "${CMSSW_BASE_SRC}/VBFTriggerSFs/")
set_source_files_properties(${VBFTriggerSFs_SRC} PROPERTIES COMPILE_FLAGS "-w")
file(GLOB_RECURSE TauPOG_SRC "${CMSSW_BASE_SRC}/TauPOG/TauIDSFs/src/*.cc")
add_library(TauPOG STATIC ${TauPOG_SRC})
set_source_files_properties(${TauPOG_SRC} PROPERTIES COMPILE_FLAGS "-w")
file(GLOB_RECURSE HH_KINFIT2_SRC "${CMSSW_BASE_SRC}/HHKinFit2/*.cpp")
add_library(HHKinFit2 STATIC ${HH_KINFIT2_SRC})
target_include_directories(HHKinFit2 PRIVATE "${CMSSW_BASE_SRC}/HHKinFit2/HHKinFit2/interface")
set_source_files_properties(${HH_KINFIT2_SRC} PROPERTIES COMPILE_FLAGS "-w")
file(GLOB_RECURSE SVFIT_SRC "${CMSSW_BASE_SRC}/TauAnalysis/ClassicSVfit/src/*.cc")
add_library(SVfit STATIC ${SVFIT_SRC})
target_compile_definitions(SVfit PRIVATE USE_SVFITTF=1)
set_source_files_properties(${SVFIT_SRC} PROPERTIES COMPILE_FLAGS "-w")
include("${AnalysisTools_DIR}/cmake/include/tensorflow.cmake")
if(${TF_AVAILABLE})
file(GLOB_RECURSE HHbtag_SRC "${CMSSW_BASE_SRC}/HHTools/HHbtag/src/*.cpp")
add_library(HHbtag STATIC ${HHbtag_SRC})
target_link_libraries(HHbtag ${TF_LIBRARIES})
target_include_directories(HHbtag PRIVATE ${TF_INCLUDES})
target_link_libraries(CacheTupleProducer ${TF_LIBRARIES} HHbtag)
target_include_directories(CacheTupleProducer PRIVATE ${TF_INCLUDES})
else()
set_target_properties(CacheTupleProducer PROPERTIES EXCLUDE_FROM_ALL 1)
endif()
add_library(h-tautau STATIC ${SOURCE_LIST})
foreach(exe_name ${EXE_LIST})
target_link_libraries("${exe_name}" h-tautau AnalysisTools HTT-utilities SVfit HHKinFit2 TauAnalysisTools VBFTriggerSFs TauPOG)
endforeach()
set_target_properties(Print_Graph Print_Graph_2 Print_Graph_3 Print_TreeBranch2D PROPERTIES EXCLUDE_FROM_ALL 1)