diff --git a/NPLib/Online/CMakeLists.txt b/NPLib/Online/CMakeLists.txt index e84c1298319b7cc456a6e145caec58d534b2b5c7..c2fd4526eca9e3365699f4372c02f087e87f1e2d 100644 --- a/NPLib/Online/CMakeLists.txt +++ b/NPLib/Online/CMakeLists.txt @@ -1,4 +1,4 @@ add_custom_command(OUTPUT NPOnlineDict.cxx COMMAND ../scripts/build_dict.sh NPOnline.h NPOnlineDict.cxx NPOnline.rootmap libNPCore.dylib NPOnlineLinkDef.h DEPENDS NPOnline.h) add_library(NPOnline SHARED NPOnline.cxx NPOnlineDict.cxx ) -target_link_libraries(NPOnline ${ROOT_LIBRARIES} -lGui -lGpad -lThread -lGraf -lHist -lMatrix NPCore) +target_link_libraries(NPOnline ${ROOT_LIBRARIES} Net Thread NPCore) install(FILES NPOnline.h DESTINATION ${CMAKE_INCLUDE_OUTPUT_DIRECTORY}) diff --git a/NPLib/Physics/CMakeLists.txt b/NPLib/Physics/CMakeLists.txt index 71610f68cd97cb12a0b56db2a744175070c1c087..06d6713640464d23bb452541b91deaa5921414f8 100644 --- a/NPLib/Physics/CMakeLists.txt +++ b/NPLib/Physics/CMakeLists.txt @@ -4,10 +4,10 @@ add_custom_command(OUTPUT TInitialConditionsDict.cxx COMMAND ../scripts/build_di add_custom_command(OUTPUT TInteractionCoordinatesDict.cxx COMMAND ../scripts/build_dict.sh TInteractionCoordinates.h TInteractionCoordinatesDict.cxx TInteractionCoordinates.rootmap libNPInteractionCoordinates.so DEPENDS TInteractionCoordinates.h) add_library(NPPhysics SHARED NPBeam.cxx NPEnergyLoss.cxx NPFunction.cxx NPNucleus.cxx NPReaction.cxx NPReactionDict.cxx NPEnergyLossDict.cxx ) -target_link_libraries(NPPhysics ${ROOT_LIBRARIES} NPCore) +target_link_libraries(NPPhysics ${ROOT_LIBRARIES} Physics NPCore) add_library(NPInitialConditions SHARED TInitialConditions.cxx TInitialConditionsDict.cxx ) -target_link_libraries(NPInitialConditions ${ROOT_LIBRARIES} NPCore) +target_link_libraries(NPInitialConditions ${ROOT_LIBRARIES} ) add_library(NPInteractionCoordinates SHARED TInteractionCoordinates.cxx TInteractionCoordinatesDict.cxx) target_link_libraries(NPInteractionCoordinates ${ROOT_LIBRARIES} ) diff --git a/NPLib/ressources/CMake/Root.cmake b/NPLib/ressources/CMake/Root.cmake index 9f7c5ec2e5d965b07504e4e6f3b6964181e3c219..1a2b5808959ef38cee94f5ddc8b0ca66e65402f3 100644 --- a/NPLib/ressources/CMake/Root.cmake +++ b/NPLib/ressources/CMake/Root.cmake @@ -34,27 +34,9 @@ endif() ## Collect the different information ## -# Lib -exec_program(${NPTOOL_ROOT_CONFIG} ARGS "--glibs" OUTPUT_VARIABLE ROOT_LIBRARIES) - -# Remove unnecessary dependencies from the list return by root -# This actually improve slightly performances -string(REPLACE "-lGui" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lCore" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lRIO" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lNet" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lHist" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lGraf " " " ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lGraf3d" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lGpad" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lTree" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lRint" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lPostscript" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lMatrix" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lPhysics" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -#string(REPLACE "-lMathCore" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lThread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") -string(REPLACE "-lpthread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") +# List of Root dependencies +#set(ROOT_LIBRARIES dl Gui Core RIO Net Hist Gpad Tree Physics MathCore Thread ) +set(ROOT_LIBRARIES dl Gui Core Gpad Hist Physics Tree ) # Lib directories exec_program(${NPTOOL_ROOT_CONFIG} ARGS "--libdir" OUTPUT_VARIABLE ROOT_LIBRARY_DIR)