Serveral Corrections for PAR files
authorjjose <jjose@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 8 Nov 2010 13:54:21 +0000 (13:54 +0000)
committerjjose <jjose@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 8 Nov 2010 13:54:21 +0000 (13:54 +0000)
ANALYSIS/CMakelibTENDERSupplies.pkg
CMakeLists.txt
README_CMake
STEER/CMakelibESD.pkg
STEER/CMakelibSTEERBase.pkg
cmake/ALICE_CMake.cmake

index 4b908b1..d2537ab 100644 (file)
 # SHLIBS - Shared Libraries and objects for linking (Executables only)           #
 #--------------------------------------------------------------------------------#
 
-set ( SRCS  Tender/AliTenderSupply.cxx Tender/AliTender.cxx)
+set ( SRCS  TenderSupplies/AliTOFTenderSupply.cxx TenderSupplies/AliPIDTenderSupply.cxx   TenderSupplies/AliTPCTenderSupply.cxx TenderSupplies/AliTRDTenderSupply.cxx TenderSupplies/AliVtxTenderSupply.cxx TenderSupplies/AliVZEROTenderSupply.cxx)
 
 string ( REPLACE ".cxx" ".h"  HDRS "${SRCS}")
 
-set ( DHDR  TenderLinkDef.h)
+set ( DHDR  TenderSuppliesLinkDef.h)
 
-set ( EINCLUDE  ANALYSIS ANALYSIS/Tender)
+set ( EINCLUDE  ANALYSIS ANALYSIS/Tender STEER TOF TRD/Cal VZERO ANALYSIS/TenderSupplies)
 
 if( ALICE_TARGET STREQUAL "win32gcc")
        
index 0921601..c912988 100644 (file)
@@ -192,6 +192,7 @@ add_custom_target(include-headers)
 add_custom_target(DA-all)
 add_custom_target(check-all)
 add_custom_target(par-all)
+add_custom_target(test-par-all)
 
 # Add Modules
 # ------------------------------
@@ -200,6 +201,8 @@ foreach(MODULE ${MODDIRS})
   configure_file(${PROJECT_SOURCE_DIR}/cmake/Module.tmp ${PROJECT_SOURCE_DIR}/${MODULE}/CMakeLists.txt @ONLY)
   add_custom_target(${MODULE}-all ALL)
   add_custom_target(${MODULE}-check-all)
+  add_custom_target(${MODULE}-par-all)
+  add_custom_target(test-${MODULE}-par-all)
   add_dependencies(check-all "${MODULE}-check-all")
   add_custom_target(${MODULE}-all-static)
   add_dependencies(alilibs-static "${MODULE}-static")
index 1e41c3a..9e9eccb 100644 (file)
@@ -54,6 +54,13 @@ eg.  make STEERbase STEERbase-static
 
   make par-all 
   make <Package>.par
+  make <Module>-par-all   build all par packages in the module
+
+10. To test PARs after building run
+
+  make test-par-all
+  make test-<Package>
+  make test-<Module>-par-all
 
 !IMPORTANT! - Make sure your source folder is clean. If you used the old make system to build aliroot run make clean in the source directory before you run cmake
  
index d52e3d4..e370f78 100644 (file)
@@ -1,4 +1,4 @@
-set ( SRCS  AliESDEvent.cxx AliESDInputHandler.cxx AliESDInputHandlerRP.cxx AliESDfriend.cxx AliESD.cxx AliESDtrack.cxx AliESDfriendTrack.cxx AliESDMuonTrack.cxx AliESDPmdTrack.cxx AliESDTrdTrack.cxx AliESDHLTtrack.cxx AliESDv0.cxx AliESDcascade.cxx AliVertex.cxx AliESDVertex.cxx AliESDpid.cxx AliESDkink.cxx AliESDCaloCluster.cxx AliESDMuonCluster.cxx AliESDMuonPad.cxx AliKFParticleBase.cxx AliKFParticle.cxx AliKFVertex.cxx AliKalmanTrack.cxx AliVertexerTracks.cxx AliStrLine.cxx AliESDV0Params.cxx AliTrackPointArray.cxx AliESDFMD.cxx AliFMDMap.cxx AliFMDFloatMap.cxx AliESDMultITS.cxx AliESDVZERO.cxx AliMultiplicity.cxx AliSelector.cxx AliESDRun.cxx AliESDHeader.cxx AliESDHLTDecision.cxx AliESDZDC.cxx AliESDTZERO.cxx AliESDTZEROfriend.cxx AliESDCaloTrigger.cxx AliRawDataErrorLog.cxx AliMeanVertex.cxx AliESDCaloCells.cxx AliESDACORDE.cxx AliTriggerIR.cxx AliESDVZEROfriend.cxx AliTriggerScalersESD.cxx AliTriggerScalersRecordESD.cxx AliESDHandler.cxx AliTrackerBase.cxx  AliTOFHeader.cxx)
+set ( SRCS  AliESDEvent.cxx AliESDInputHandler.cxx AliESDInputHandlerRP.cxx AliESDfriend.cxx AliESD.cxx AliESDtrack.cxx AliESDfriendTrack.cxx AliESDMuonTrack.cxx AliESDPmdTrack.cxx AliESDTrdTrack.cxx AliESDHLTtrack.cxx AliESDv0.cxx AliESDcascade.cxx AliVertex.cxx AliESDVertex.cxx AliESDpid.cxx AliESDkink.cxx AliESDCaloCluster.cxx AliESDMuonCluster.cxx AliESDMuonPad.cxx AliKFParticleBase.cxx AliKFParticle.cxx AliKFVertex.cxx AliKalmanTrack.cxx AliVertexerTracks.cxx AliStrLine.cxx AliESDV0Params.cxx AliTrackPointArray.cxx AliESDFMD.cxx AliFMDMap.cxx AliFMDFloatMap.cxx AliESDMultITS.cxx AliESDVZERO.cxx AliMultiplicity.cxx AliSelector.cxx AliESDRun.cxx AliESDHeader.cxx AliESDHLTDecision.cxx AliESDZDC.cxx AliESDTZERO.cxx AliESDTZEROfriend.cxx AliESDCaloTrigger.cxx AliESDCentrality.cxx AliRawDataErrorLog.cxx AliMeanVertex.cxx AliESDCaloCells.cxx AliESDACORDE.cxx AliTriggerIR.cxx AliESDVZEROfriend.cxx AliTriggerScalersESD.cxx AliTriggerScalersRecordESD.cxx AliESDHandler.cxx AliTrackerBase.cxx  AliTOFHeader.cxx)
 
 string(REPLACE ".cxx" ".h" HDRS "${SRCS}")
 
index 0e4c430..637740d 100644 (file)
@@ -1,4 +1,4 @@
-set ( SRCS  AliVParticle.cxx AliVTrack.cxx AliVCluster.cxx AliVCaloCells.cxx AliVVertex.cxx AliVEvent.cxx AliMixedEvent.cxx AliVHeader.cxx AliVEventHandler.cxx AliVEventPool.cxx AliVCuts.cxx AliPID.cxx AliLog.cxx AliRunTag.cxx AliLHCTag.cxx AliDetectorTag.cxx AliEventTag.cxx AliFileTag.cxx AliEventTagCuts.cxx AliRunTagCuts.cxx AliLHCTagCuts.cxx AliDetectorTagCuts.cxx AliTagCreator.cxx AliHeader.cxx AliGenEventHeader.cxx AliDetectorEventHeader.cxx AliGenPythiaEventHeader.cxx AliGenCocktailEventHeader.cxx AliGenGeVSimEventHeader.cxx AliGenHijingEventHeader.cxx AliCollisionGeometry.cxx AliGenDPMjetEventHeader.cxx AliGenHerwigEventHeader.cxx AliGenEposEventHeader.cxx AliStack.cxx AliMCEventHandler.cxx AliInputEventHandler.cxx AliTrackReference.cxx AliSysInfo.cxx AliMCEvent.cxx AliMCParticle.cxx AliMCVertex.cxx AliMagF.cxx AliMagWrapCheb.cxx AliCheb3D.cxx AliCheb3DCalc.cxx AliNeutralTrackParam.cxx AliCodeTimer.cxx AliPDG.cxx AliTimeStamp.cxx AliTriggerScalers.cxx AliTriggerScalersRecord.cxx AliExternalTrackParam.cxx AliQA.cxx AliITSPidParams.cxx AliITSPIDResponse.cxx AliTPCPIDResponse.cxx AliTOFPIDResponse.cxx AliTRDPIDResponse.cxx AliDAQ.cxx)
+set ( SRCS  AliVParticle.cxx AliVTrack.cxx AliVCluster.cxx AliVCaloCells.cxx AliVVertex.cxx AliVEvent.cxx AliMixedEvent.cxx AliVHeader.cxx AliVEventHandler.cxx AliVEventPool.cxx AliVCuts.cxx AliPID.cxx AliLog.cxx AliRunTag.cxx AliLHCTag.cxx AliDetectorTag.cxx AliEventTag.cxx AliFileTag.cxx AliEventTagCuts.cxx AliRunTagCuts.cxx AliLHCTagCuts.cxx AliDetectorTagCuts.cxx AliTagCreator.cxx AliHeader.cxx AliGenEventHeader.cxx AliDetectorEventHeader.cxx AliGenPythiaEventHeader.cxx AliGenCocktailEventHeader.cxx AliGenGeVSimEventHeader.cxx AliGenHijingEventHeader.cxx AliCollisionGeometry.cxx AliGenDPMjetEventHeader.cxx AliGenHerwigEventHeader.cxx AliGenEposEventHeader.cxx AliStack.cxx AliMCEventHandler.cxx AliInputEventHandler.cxx AliTrackReference.cxx AliSysInfo.cxx AliMCEvent.cxx AliMCParticle.cxx AliMCVertex.cxx AliMagF.cxx AliMagWrapCheb.cxx AliCheb3D.cxx AliCheb3DCalc.cxx AliNeutralTrackParam.cxx AliCodeTimer.cxx AliPDG.cxx AliTimeStamp.cxx AliTriggerScalers.cxx AliTriggerScalersRecord.cxx AliExternalTrackParam.cxx AliQA.cxx AliITSPidParams.cxx AliITSPIDResponse.cxx AliTPCPIDResponse.cxx AliTOFPIDResponse.cxx AliTRDPIDResponse.cxx AliDAQ.cxx AliRefArray.cxx)
 
 string(REPLACE ".cxx" ".h" HDRS  "${SRCS}")
 
index e2fd328..8764f83 100644 (file)
@@ -579,16 +579,38 @@ endmacro(ALICE_GenerateLinkDef)
 macro(ALICE_BuildPAR)
   if(EXISTS ${ALICE_ROOT}/${MODULE}/PROOF-INF.${PACKAGE})
     add_custom_target(${PACKAGE}.par
-                      COMMAND mkdir -p ${PACKAGE}
-                      COMMAND cp -pR ${SRCS} ${HDRS} ${DHDR} ${PACKAGE}
                       COMMAND sed -e 's/include .\(ROOTSYS\)\\/test\\/Makefile.arch/include Makefile.arch/\; s/PACKAGE = .*/PACKAGE = ${PACKAGE}/' < Makefile > ${PACKAGE}/Makefile
                       COMMAND cp -pR ${ROOTSYS}/test/Makefile.arch ${PACKAGE}/Makefile.arch
                       COMMAND cp -pR PROOF-INF.${PACKAGE} ${PACKAGE}/PROOF-INF
                       COMMAND cp -pR lib${PACKAGE}.pkg ${PACKAGE}
                       COMMAND tar --exclude=.svn -czhf ${CMAKE_BINARY_DIR}/${PACKAGE}.par ${PACKAGE}
                       COMMAND ${CMAKE_COMMAND} -E remove_directory ${PACKAGE}
+                      COMMAND ${CMAKE_COMMAND} -E cmake_echo_color --red --bold "${PACKAGE}.par has been created in ${CMAKE_BINARY_DIR}"
+                      DEPENDS ${SRCS} ${HDRS} ${FSRCS} ${DHDR}
                       WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} )
+
+    foreach(file ${SRCS} ${HDRS} ${FSRCS} ${DHDR})
+      get_filename_component(srcdir ${file} PATH)
+      add_custom_command(OUTPUT ${file}                         
+                         COMMAND mkdir -p ${PACKAGE}/${srcdir}
+                         COMMAND cp -pR ${file} ${PACKAGE}/${file}
+                         WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} )
+    endforeach(file ${SRCS} ${HDRS} ${FSRCS} ${DHDR})
+
     add_dependencies(par-all ${PACKAGE}.par)
+    add_dependencies(${MODULE}-par-all ${PACKAGE}.par)
+
+    add_custom_target(test-${PACKAGE}.par
+                      COMMAND ${CMAKE_COMMAND} -E cmake_echo_color --red --bold "The file ${PACKAGE}.par is now being tested, in case of an error check in par-tmp/${PACKAGE}."
+                      COMMAND ${CMAKE_COMMAND} -E make_directory par-tmp
+                      COMMAND ${CMAKE_COMMAND} -E chdir par-tmp tar xfz ../${PACKAGE}.par && ${CMAKE_COMMAND} -E chdir par-tmp/${PACKAGE} PROOF-INF/BUILD.sh
+                      COMMAND ${CMAKE_COMMAND} -E remove_directory par-tmp
+                      COMMAND ${CMAKE_COMMAND} -E cmake_echo_color --green --bold "${PACKAGE}.par testing succeeded"
+                      WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
+
+    add_dependencies(test-par-all test-${PACKAGE}.par)
+    add_dependencies(test-${MODULE}-par-all test-${PACKAGE}.par)
+
   endif(EXISTS ${ALICE_ROOT}/${MODULE}/PROOF-INF.${PACKAGE})
 endmacro(ALICE_BuildPAR)