cmake: name the dictionary targets for the pcm/rootmap install rules.
root_generate_dictionary() attaches the rootcling outputs (*Dict.cxx, *_rdict.pcm, *.rootmap) to two targets: the '<name>Dict' target and the library compiling '<name>Dict.cxx'. Since cmake 4.5 an install(FILES) of such a non-unique output triggers an author warning, since the new install_prep/ targets cannot tell which target builds it. The new helper musrfit_dict_build_depends() names the producing dictionary targets via BUILD_DEPENDS, a keyword which only exists since cmake 4.5, hence it is only emitted there.
This commit is contained in:
1 parent
1dd5656ba2
commit
509be23fe9
21 files changed
+59
No files matched your search
@@ -40,6 +40,22 @@ if (UNIX AND NOT APPLE)
|
||||
"where the .desktop files and icons are installed (must be in the XDG search path)")
|
||||
endif (UNIX AND NOT APPLE)
|
||||
|
||||
#--- install rules for the rootcling generated *_rdict.pcm / *.rootmap files --
|
||||
#--- root_generate_dictionary() attaches these outputs to two targets (the
|
||||
#--- '<name>Dict' target and the library compiling '<name>Dict.cxx'). Since
|
||||
#--- cmake 4.5 an install(FILES) of such a non-unique output triggers an author
|
||||
#--- warning, unless the producing target is named via BUILD_DEPENDS. That
|
||||
#--- keyword does not exist before cmake 4.5, hence only emit it there.
|
||||
#--- Usage: musrfit_dict_build_depends(<var> <dict target>...) and add ${<var>}
|
||||
#--- to the install(FILES ...) call.
|
||||
function(musrfit_dict_build_depends var)
|
||||
if (CMAKE_VERSION VERSION_GREATER_EQUAL 4.5)
|
||||
set(${var} BUILD_DEPENDS ${ARGN} PARENT_SCOPE)
|
||||
else ()
|
||||
set(${var} "" PARENT_SCOPE)
|
||||
endif ()
|
||||
endfunction()
|
||||
|
||||
#--- musrfit specific options -------------------------------------------------
|
||||
option(nexus "build optional NeXus support. Needed for ISIS" OFF)
|
||||
#--- 'HAVE_HDF4' is the name the C++ sources (PNeXus, PRunDataHandler,
|
||||
|
||||
@@ -229,6 +229,10 @@ install(TARGETS PRgeHandler EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LI
|
||||
install(TARGETS PMusr EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps
|
||||
PFourierCanvasDict PMsgBoxDict PMusrT0Dict
|
||||
PRgeHandlerDict PStartupHandlerDict PUserFcnBaseDict
|
||||
)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPFourierCanvas_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPFourierCanvas.rootmap
|
||||
@@ -245,6 +249,7 @@ install(
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPUserFcnBase_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPUserFcnBase.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install headers ----------------------------------------------------------
|
||||
|
||||
Vendored
+2
@@ -61,10 +61,12 @@ target_link_libraries(BMWtools ${ROOT_LIBRARIES} cuba)
|
||||
install(TARGETS BMWtools EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps BMWStartupHandlerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libBMWStartupHandler_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libBMWStartupHandler.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install BMWtools header --------------------------------------------------
|
||||
|
||||
@@ -58,10 +58,12 @@ target_link_libraries(PDepthProfile FFTW3::FFTW3 ${ROOT_LIBRARIES} PRgeHandler P
|
||||
install(TARGETS PDepthProfile EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PDepthProfileDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPDepthProfile_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPDepthProfile.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install DepthProfile header ----------------------------------------------
|
||||
|
||||
@@ -54,10 +54,12 @@ target_link_libraries(PDummyUserFcn ${ROOT_LIBRARIES} PUserFcnBase)
|
||||
install(TARGETS PDummyUserFcn EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PDummyUserFcnDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPDummyUserFcn_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPDummyUserFcn.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PDummyUserFcn header ------------------------------------------------
|
||||
|
||||
+2
@@ -63,12 +63,14 @@ target_link_libraries(PMagProximityFitter FFTW3::FFTW3 ${ROOT_LIBRARIES} PRgeHan
|
||||
install(TARGETS PMagProximityFitter EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PMagProximityFitterDict PMPStartupHandlerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPMagProximityFitter_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMagProximityFitter.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMPStartupHandler_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMPStartupHandler.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PMagProximityFitter header ---------------------------------------
|
||||
|
||||
Vendored
+2
@@ -52,10 +52,12 @@ target_link_libraries(TMusrRunHeader ${ROOT_LIBRARIES})
|
||||
install(TARGETS TMusrRunHeader EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TMusrRunHeaderDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTMusrRunHeader_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTMusrRunHeader.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install TMusrRunHeader header --------------------------------------------
|
||||
|
||||
Vendored
+2
@@ -71,12 +71,14 @@ target_link_libraries(PNL_PippardFitter ${BOOST_LINK_LIBS} FFTW3::FFTW3 ${ROOT_L
|
||||
install(TARGETS PNL_PippardFitter EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PNL_PippardFitterDict PNL_StartupHandlerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPNL_PippardFitter_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPNL_PippardFitter.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPNL_StartupHandler_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPNL_StartupHandler.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PNL_PippardFitter header -----------------------------------------
|
||||
|
||||
+2
@@ -63,12 +63,14 @@ target_link_libraries(TLemRunHeader ${ROOT_LIBRARIES})
|
||||
install(TARGETS TLemRunHeader EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TLemRunHeaderDict TLemStatsDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTLemRunHeader_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTLemRunHeader.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTLemStats_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTLemStats.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install headers ----------------------------------------------------------
|
||||
|
||||
Vendored
+2
@@ -46,10 +46,12 @@ target_link_libraries(BNMR ${ROOT_LIBRARIES} PUserFcnBase)
|
||||
install(TARGETS BNMR EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TBNMRDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTBNMR_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTBNMR.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install libBNMR header ---------------------------------------------------
|
||||
|
||||
@@ -43,10 +43,12 @@ target_link_libraries(LineProfile ${ROOT_LIBRARIES} PUserFcnBase Boost::headers
|
||||
install(TARGETS LineProfile EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps LineProfileDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libLineProfile_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libLineProfile.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install libLineProfile header ---------------------------------------------------
|
||||
|
||||
@@ -65,10 +65,12 @@ target_link_libraries(CalcMeanFieldsLEM
|
||||
install(TARGETS CalcMeanFieldsLEM EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TCalcMeanFieldsLEMDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTCalcMeanFieldsLEM_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTCalcMeanFieldsLEM.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install CalcMeanFieldsLEM header -----------------------------------------
|
||||
|
||||
@@ -106,6 +106,7 @@ target_link_libraries(FitPofB
|
||||
install(TARGETS FitPofB EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TLondon1DDict TVortexDict TSkewedGssDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTLondon1D_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTLondon1D.rootmap
|
||||
@@ -114,6 +115,7 @@ install(
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTSkewedGss_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTSkewedGss.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install FitPofB header ---------------------------------------------------
|
||||
|
||||
+2
@@ -64,10 +64,12 @@ target_link_libraries(GapIntegrals
|
||||
install(TARGETS GapIntegrals EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TGapIntegralsDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTGapIntegrals_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTGapIntegrals.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install GapIntegrals header ----------------------------------------------
|
||||
|
||||
Vendored
+2
@@ -50,10 +50,12 @@ target_link_libraries(PGbGLF FFTW3::FFTW3 ${ROOT_LIBRARIES} PUserFcnBase)
|
||||
install(TARGETS PGbGLF EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PGbGLFDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPGbGLF_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPGbGLF.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PGbGLF header ----------------------------------------------------
|
||||
|
||||
+2
@@ -68,10 +68,12 @@ target_link_libraries(LFRelaxation
|
||||
install(TARGETS LFRelaxation EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps TLFRelaxationDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libTLFRelaxation_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libTLFRelaxation.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install TLFRelaxation header ---------------------------------------------
|
||||
|
||||
@@ -63,10 +63,12 @@ target_link_libraries(PPhotoMeissner
|
||||
install(TARGETS PPhotoMeissner EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PPhotoMeissnerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPPhotoMeissner_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPPhotoMeissner.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PPhotoMeissner header --------------------------------------------
|
||||
|
||||
@@ -68,12 +68,14 @@ target_link_libraries(PSpinValve FFTW3::FFTW3 ${ROOT_LIBRARIES} PUserFcnBase)
|
||||
install(TARGETS PSpinValve EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PSkewedLorentzianDict PStartupHandler_SVDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPSkewedLorentzian_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPSkewedLorentzian.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPStartupHandler_SV_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPStartupHandler_SV.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install PSpinValve header ------------------------------------------------
|
||||
|
||||
+2
@@ -66,10 +66,12 @@ target_link_libraries(ZFRelaxation
|
||||
install(TARGETS ZFRelaxation EXPORT musrfitTargets DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps ZFRelaxationDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libZFRelaxation_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libZFRelaxation.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install ZFRelaxation header ----------------------------------------------
|
||||
|
||||
@@ -127,12 +127,14 @@ if (UNIX AND NOT APPLE)
|
||||
endif ()
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PMuppCanvasDict PMuppStartupHandlerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPMuppCanvas_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppCanvas.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppStartupHandler_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppStartupHandler.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install headers ----------------------------------------------------------
|
||||
|
||||
@@ -127,12 +127,14 @@ if (UNIX AND NOT APPLE)
|
||||
endif ()
|
||||
|
||||
#--- install root pcm's and rootmaps ------------------------------------------
|
||||
musrfit_dict_build_depends(dict_deps PMuppCanvasDict PMuppStartupHandlerDict)
|
||||
install(
|
||||
FILES ${CMAKE_CURRENT_BINARY_DIR}/libPMuppCanvas_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppCanvas.rootmap
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppStartupHandler_rdict.pcm
|
||||
${CMAKE_CURRENT_BINARY_DIR}/libPMuppStartupHandler.rootmap
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
${dict_deps}
|
||||
)
|
||||
|
||||
#--- install headers ----------------------------------------------------------
|
||||
|
||||
Reference in new issue
Block a user