Skip to content

Commit 82a87ff

Browse files
authored
cmake: avoid absolute paths to source headers being baked into dictionary (#178)
1 parent 2835abc commit 82a87ff

22 files changed

+6
-8
lines changed

analyzers/dataframe/CMakeLists.txt

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11

2-
find_package(ROOT REQUIRED COMPONENTS ROOTDataFrame ROOTVecOps TMVA)
2+
find_package(ROOT REQUIRED COMPONENTS ROOTDataFrame ROOTVecOps)
33
include(${ROOT_USE_FILE})
44
#include("${ROOT_DIR}/modules/RootNewMacros.cmake")
55

@@ -25,7 +25,7 @@ message(STATUS "includes-------------------------- dataframe fastjet: ${FASTJET_
2525

2626

2727
file(GLOB sources src/*.cc)
28-
file(GLOB headers include/FCCAnalyses/*.h)
28+
file(GLOB headers RELATIVE ${CMAKE_CURRENT_LIST_DIR} FCCAnalyses/*.h)
2929

3030
message(STATUS "includes headers ${headers}")
3131
message(STATUS "includes sources ${sources}")
@@ -40,11 +40,10 @@ endif()
4040
message(STATUS "CMAKE_CURRENT_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}")
4141
message(STATUS "CMAKE_INSTALL_INCLUDEDIR ${CMAKE_INSTALL_INCLUDEDIR}")
4242

43-
add_library(FCCAnalyses SHARED ${sources} ${headers} )
43+
add_library(FCCAnalyses SHARED ${sources} ${headers} )
4444
target_include_directories(FCCAnalyses PUBLIC
45-
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include>
46-
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
47-
${FCCEDM_INCLUDE_DIRS}
45+
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
46+
$<INSTALL_INTERFACE:include>
4847
${FASTJET_INCLUDE_DIR}
4948
${acts_INCLUDE_DIR}
5049
${AWKWARD_INCLUDE}
@@ -55,7 +54,6 @@ target_link_libraries(FCCAnalyses
5554
ROOT::MathCore
5655
ROOT::ROOTVecOps
5756
ROOT::ROOTDataFrame
58-
ROOT::TMVA
5957
EDM4HEP::edm4hep
6058
EDM4HEP::edm4hepDict
6159
podio::podio
@@ -81,7 +79,7 @@ set_target_properties(FCCAnalyses PROPERTIES
8179
ROOT_GENERATE_DICTIONARY(G__FCCAnalyses
8280
${headers}
8381
MODULE FCCAnalyses
84-
LINKDEF include/FCCAnalyses/LinkDef.h
82+
LINKDEF FCCAnalyses/LinkDef.h
8583
)
8684

8785
install(TARGETS FCCAnalyses
File renamed without changes.
File renamed without changes.

analyzers/dataframe/include/FCCAnalyses/ExternalRecombiner.h renamed to analyzers/dataframe/FCCAnalyses/ExternalRecombiner.h

File renamed without changes.
File renamed without changes.

analyzers/dataframe/include/FCCAnalyses/JetClusteringUtils.h renamed to analyzers/dataframe/FCCAnalyses/JetClusteringUtils.h

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

analyzers/dataframe/include/FCCAnalyses/ReconstructedParticle.h renamed to analyzers/dataframe/FCCAnalyses/ReconstructedParticle.h

File renamed without changes.

0 commit comments

Comments
 (0)