Skip to content
Snippets Groups Projects
Commit 32bd1779 authored by Pierre Morfouace's avatar Pierre Morfouace
Browse files

Merge branch 'NPTool.2.dev' of https://github.com/adrien-matta/nptool into NPTool.2.dev

parents 30193dd9 57f9e1d7
No related branches found
No related tags found
No related merge requests found
...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR}) ...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR})
include_directories( ${NPTOOL_INCLUDE_DIR}) include_directories( ${NPTOOL_INCLUDE_DIR})
link_directories( ${NPTOOL_LIB_DIR}) link_directories( ${NPTOOL_LIB_DIR})
# Get the compilator flag from root to assure consistancy
EXEC_PROGRAM(${ROOT_CONFIG_EXECUTABLE}
ARGS "--cflags"
OUTPUT_VARIABLE root_cflags )
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${root_cflags}")
# If the compiler is Clang, silence the unrecognised flags # If the compiler is Clang, silence the unrecognised flags
if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*") if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup")
......
...@@ -2,4 +2,4 @@ CalibrationFilePath ...@@ -2,4 +2,4 @@ CalibrationFilePath
SharcCalibration.txt SharcCalibration.txt
SharcPixelCalibration.txt SharcPixelCalibration.txt
SharcPixelDeadLayer.txt SharcPixelDeadLayer.txt
TigressCalibration.txt TigressCalibration_Ryan.txt
...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR}) ...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR})
include_directories( ${NPTOOL_INCLUDE_DIR}) include_directories( ${NPTOOL_INCLUDE_DIR})
link_directories( ${NPTOOL_LIB_DIR}) link_directories( ${NPTOOL_LIB_DIR})
# Get the compilator flag from root to assure consistancy
EXEC_PROGRAM(${ROOT_CONFIG_EXECUTABLE}
ARGS "--cflags"
OUTPUT_VARIABLE root_cflags )
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${root_cflags}")
# If the compiler is Clang, silence the unrecognised flags # If the compiler is Clang, silence the unrecognised flags
if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*") if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup")
......
...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR}) ...@@ -15,13 +15,6 @@ link_directories( ${ROOT_LIBRARY_DIR})
include_directories( ${NPTOOL_INCLUDE_DIR}) include_directories( ${NPTOOL_INCLUDE_DIR})
link_directories( ${NPTOOL_LIB_DIR}) link_directories( ${NPTOOL_LIB_DIR})
# Get the compilator flag from root to assure consistancy
EXEC_PROGRAM(${ROOT_CONFIG_EXECUTABLE}
ARGS "--cflags"
OUTPUT_VARIABLE root_cflags )
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${root_cflags}")
# If the compiler is Clang, silence the unrecognised flags # If the compiler is Clang, silence the unrecognised flags
if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*") if(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang.*")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -undefined dynamic_lookup")
......
add_custom_command(OUTPUT TAsciiFileDict.cxx COMMAND ../scripts/build_dict.sh TAsciiFile.h TAsciiFileDict.cxx TAsciiFile.rootmap libNPCore.so) add_custom_command(OUTPUT TAsciiFileDict.cxx COMMAND ../scripts/build_dict.sh TAsciiFile.h TAsciiFileDict.cxx TAsciiFile.rootmap libNPCore.so)
add_custom_command(OUTPUT NPVDetectorDict.cxx COMMAND ../scripts/build_dict.sh NPVDetector.h NPVDetectorDict.cxx NPVDetector.rootmap libNPCore.so NPCoreLinkdef.h) add_custom_command(OUTPUT NPVDetectorDict.cxx COMMAND ../scripts/build_dict.sh NPVDetector.h NPVDetectorDict.cxx NPVDetector.rootmap libNPCore.so NPCoreLinkdef.h)
add_library(NPCore SHARED NPVAnalysis.cxx NPAnalysisFactory.cxx NPCalibrationManager.cxx NPOptionManager.cxx RootOutput.cxx RootInput.cxx TAsciiFile.cxx TAsciiFileDict.cxx NPDetectorManager.cxx NPVDetector.cxx NPVDetectorDict.cxx NPVSpectra.cxx NPDetectorFactory.cxx NPSpectraServer.cxx ) add_library(NPCore SHARED NPVAnalysis.cxx NPAnalysisFactory.cxx NPCalibrationManager.cxx NPOptionManager.cxx RootOutput.cxx RootInput.cxx TAsciiFile.cxx TAsciiFileDict.cxx NPDetectorManager.cxx NPVDetector.cxx NPVDetectorDict.cxx NPVSpectra.cxx NPDetectorFactory.cxx NPSpectraServer.cxx )
target_link_libraries(NPCore ${ROOT_LIBRARIES} -lGpad) target_link_libraries(NPCore ${ROOT_LIBRARIES})
install(FILES NPVAnalysis.h NPAnalysisFactory.h NPCalibrationManager.h NPOptionManager.h RootInput.h RootOutput.h TAsciiFile.h NPDetectorManager.h NPVDetector.h NPGlobalSystemOfUnits.h NPPhysicalConstants.h NPSystemOfUnits.h NPVSpectra.h NPDetectorFactory.h NPSpectraServer.h DESTINATION ${CMAKE_INCLUDE_OUTPUT_DIRECTORY}) install(FILES NPVAnalysis.h NPAnalysisFactory.h NPCalibrationManager.h NPOptionManager.h RootInput.h RootOutput.h TAsciiFile.h NPDetectorManager.h NPVDetector.h NPGlobalSystemOfUnits.h NPPhysicalConstants.h NPSystemOfUnits.h NPVSpectra.h NPDetectorFactory.h NPSpectraServer.h DESTINATION ${CMAKE_INCLUDE_OUTPUT_DIRECTORY})
...@@ -4,7 +4,7 @@ add_custom_command(OUTPUT TMayaHistoDict.cxx COMMAND ../scripts/build_dict.sh TM ...@@ -4,7 +4,7 @@ add_custom_command(OUTPUT TMayaHistoDict.cxx COMMAND ../scripts/build_dict.sh TM
add_library(NPMaya SHARED TMayaData.cxx TMayaHisto.cxx TMayaDataDict.cxx TMayaHistoDict.cxx ConfigReader.cxx) add_library(NPMaya SHARED TMayaData.cxx TMayaHisto.cxx TMayaDataDict.cxx TMayaHistoDict.cxx ConfigReader.cxx)
target_link_libraries(NPMaya ${ROOT_LIBRARIES} NPCore) target_link_libraries(NPMaya ${ROOT_LIBRARIES} -lGraf NPCore)
install(FILES TMayaData.h TMayaHisto.h ConfigReader.h DESTINATION ${CMAKE_INCLUDE_OUTPUT_DIRECTORY}) install(FILES TMayaData.h TMayaHisto.h ConfigReader.h DESTINATION ${CMAKE_INCLUDE_OUTPUT_DIRECTORY})
endif() endif()
...@@ -43,17 +43,18 @@ string(REPLACE "-lGui" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") ...@@ -43,17 +43,18 @@ string(REPLACE "-lGui" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lRIO" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lRIO" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lNet" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lNet" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lHist" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lHist" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lGraf " " " ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lGraf " " " ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lGraf3d" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lGraf3d" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lGpad" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lGpad" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lTree" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lTree" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lRint" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lRint" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lPostScript" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lPostscript" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lMatrix" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lMatrix" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lPhysics" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lPhysics" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
#string(REPLACE "-lMathCore" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") #string(REPLACE "-lMathCore" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lThread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lThread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
string(REPLACE "-lpthread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}") string(REPLACE "-lpthread" "" ROOT_LIBRARIES "${ROOT_LIBRARIES}")
message("${ROOT_LIBRARIES}")
# Lib directories # Lib directories
exec_program(${NPTOOL_ROOT_CONFIG} ARGS "--libdir" OUTPUT_VARIABLE ROOT_LIBRARY_DIR) exec_program(${NPTOOL_ROOT_CONFIG} ARGS "--libdir" OUTPUT_VARIABLE ROOT_LIBRARY_DIR)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment