]> Creatis software - creaToolsTools.git/blobdiff - ctest/dashboard/All.sh
Feature 2004 Windows generation creatools installer. Merging in one proces Debug...
[creaToolsTools.git] / ctest / dashboard / All.sh
index d3ad7a93ff6c917400f7393d940fb0ba950abbd4..4d3a9773771c219acb35cf57de4dd3f6f440a8cc 100644 (file)
+# ---------------------------------------------------------------------
+#
+# Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image 
+#                        pour la Santé)
+# Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
+#
+#  This software is governed by the CeCILL-B license under French law and 
+#  abiding by the rules of distribution of free software. You can  use, 
+#  modify and/ or redistribute the software under the terms of the CeCILL-B 
+#  license as circulated by CEA, CNRS and INRIA at the following URL 
+#  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html 
+#  or in the file LICENSE.txt.
+#
+#  As a counterpart to the access to the source code and  rights to copy,
+#  modify and redistribute granted by the license, users are provided only
+#  with a limited warranty  and the software's author,  the holder of the
+#  economic rights,  and the successive licensors  have only  limited
+#  liability. 
+#
+#  The fact that you are presently reading this means that you have had
+#  knowledge of the CeCILL-B license and that you accept its terms.
+# ------------------------------------------------------------------------  
+
 #!/bin/sh
 
+if [ $# = 0 ]
+then
+echo "Use it as :"
+echo "sh All.sh <nameOfTheGenerationDirectory> <BooleanForDocGeneration> <userNameForCVS> <VTKdir> <installPrefix> <buildType>"
+echo " "
+echo "ex : sh All.sh /tmp/gendir OFF jpr /usr/local/lib/vtk-5.4 /home/jpr/myInsallDirectory"
+exit 0
+fi
+
+if [ $# != 6 ]
+then 
+echo "use it as           sh All.sh /tmp/gendir OFF jpr /usr/local/lib/vtk-5.4 /home/jpr/myInsallDirectory Release"
+exit 0
+fi
+
 # @echo off
 
-# buildtype, useless for Linux; let here for compatiblitily purpose
- buildtype=Release
+#allow user to choose the generation dir
+#allow user to choose to generate the doc or not
+
+generationdir=$1
+cvsUserName=$3
+VTKdir=$4
+installPrefix=$5
+buildtype=$6
 
- creasourcefolder=crea
- creabinfolder=creaBin
- bbtksourcefolder=bbtk
- bbtkbinfolder=bbtkBin
- creamaracassourcefolder=creaMaracasVisu
- creamaracasbinary=creaMaracasVisuBin
+mkdir $generationdir
+mkdir $generationdir/tmpCreaToolsBIN
+
+ creasource=crea
+ bbtksource=bbtk
+ creamaracassource=creaMaracasVisu
  creaenvironmentsource=creaEnvironment
- creaenvironmentbinary=creaEnvironmentBin
  creabrukersource=creaBruker
- creabrukerbinary=creaBrukerBin
- creaimagesourcefolder=creaImageIO
- creaimagebinary=creaImageIOBin
+ creaimagesource=creaImageIO
  creacontourssource=creaContours
- creacontoursbinary=creaContoursBin
  crearigidregistrationssource=creaRigidRegistration
- crearigidregistrationbinary=creaRigidRegistrationBin
  bbtkgeditorsource=bbtkGEditor
- bbtkgeditorbinary=bbtkGEditorBin
  creatoolssource=creaTools
- creatoolsbinary=creaToolsBin
-
-
- sh cvscheckout.sh $creasourcefolder
- sh cvscheckout.sh $bbtksourcefolder
- sh cvscheckout.sh $creamaracassourcefolder
- sh cvscheckout.sh $creaenvironmentsource
- sh cvscheckout.sh $creabrukersource
- sh cvscheckout.sh $creaimagesourcefolder
- sh cvscheckout.sh $creacontourssource
- sh cvscheckout.sh $crearigidregistrationssource
- sh cvscheckout.sh $bbtkgeditorsource
- sh cvscheckout.sh $creatoolssource
 
+# the following stupid test is used at debug time; Please don't remove!
+if [ true = true ]
+then
+
+rm -rf $generationdir/creaBin
+rm -rf $generationdir/bbtkBin
+rm -rf $generationdir/creamaracasBin
+rm -rf $generationdir/creaEnvironmentBin
+rm -rf $generationdir/creaBrukerBin
+rm -rf $generationdir/creaImageIOBin
+rm -rf $generationdir/creaContoursBin
+rm -rf $generationdir/creaRigidRegistrationBin
+rm -rf $generationdir/bbtkGEditorBin
+rm -rf $generationdir/creaToolsBin
+
+sh cvscheckout.sh $creasource                   $generationdir $cvsUserName
+sh cvscheckout.sh $bbtksource                   $generationdir $cvsUserName
+sh cvscheckout.sh $creamaracassource            $generationdir $cvsUserName
+sh cvscheckout.sh $creaenvironmentsource        $generationdir $cvsUserName
+sh cvscheckout.sh $creabrukersource             $generationdir $cvsUserName
+sh cvscheckout.sh $creaimagesource              $generationdir $cvsUserName
+sh cvscheckout.sh $creacontourssource           $generationdir $cvsUserName
+sh cvscheckout.sh $crearigidregistrationssource $generationdir $cvsUserName
+sh cvscheckout.sh $bbtkgeditorsource            $generationdir $cvsUserName
+sh cvscheckout.sh $creatoolssource              $generationdir $cvsUserName
+
+fi
 
 # CREA
- sh cmakemod.sh $creasourcefolder $creabinfolder
- sh creaVariables.sh $creabinfolder $creasourcefolder
- sh compilemod.sh $buildtype $creabinfolder
- sh ctestmod.sh $creabinfolder
- creadll=`pwd`/$creabinfolder
- LD_LIBRARY_PATH=$creadll:LD_LIBRARY_PATH
-
+#if [ true = false ]
+#then
+ sh cmakemod.sh                    $creasource $generationdir $VTKdir $installPrefix $buildType
+ sh creaVariables.sh               $creasource $generationdir $docgeneration
+ sh compilemod.sh     $buildtype   $creasource $generationdir 
+ sh ctestmod.sh                    $creasource $generationdir
+#fi
+    
+ creadll=$generationdir/tmpCreaTools_INSTALL/creaBin
+ LD_LIBRARY_PATH=$creadll:LD_LIBRARY_$PATH
+# echo "=in All.sh, out of crea ============================================================================ $LD_LIBRARY_PATH"
+
+
+#if [ true = false ]
+#then
 # BBTK
- sh cmakemod.sh $bbtksourcefolder $bbtkbinfolder
- sh bbtkVariables.sh $bbtkbinfolder $creabinfolder
- sh compilemod.sh $buildtype $bbtkbinfolder
- sh ctestmod.sh $bbtkbinfolder
- bbtkdll=`pwd`/$bbtkbinfolder
+ sh cmakemod.sh              $bbtksource $generationdir $VTKdir $installPrefix $buildType
+# echo "============================BBTK out of cmakemod "
+ sh bbtkVariables.sh         $bbtksource $generationdir $docgeneration
+# echo "============================BBTK out of bbtkVariables " 
+ sh compilemod.sh $buildtype $bbtksource $generationdir 
+ echo "============================BBTK out of compilemod " 
+
+ sh ctestmod.sh              $bbtksource $generationdir
+#fi
+
+ bbtkdll=$generationdir/tmpCreaTools_INSTALL/bbtkBin
  LD_LIBRARY_PATH=$bbtkdll:$LD_LIBRARY_PATH
 
-# creaMaracasVisu
- sh cmakemod.sh $creamaracassourcefolder $creamaracasbinary
- sh creaMaracasVariables.sh $creamaracasbinary $creabinfolder $bbtkbinfolder
- sh compilemod.sh $buildtype $creamaracasbinary
- sh ctestmod.sh $creamaracasbinary
- creamaracasdll=`pwd`/$creamaracasbinary
+#if [ true = false ]
+#then
+ creaMaracasVisu
+# echo "========================================================================================start creaMaracasVisu " 
+ sh cmakemod.sh                        $creamaracassource $generationdir $VTKdir $installPrefix $buildType
+# echo "=======================================================================================creaMaracasVisu out of cmakemod "
+ sh creaMaracasVariables.sh            $creamaracassource $generationdir $docgeneration
+ sh compilemod.sh           $buildtype $creamaracassource $generationdir
+ sh ctestmod.sh                        $creamaracassource $generationdir
+#fi
+ creamaracasdll=$generationdir/tmpCreaTools_INSTALL/creamaracasBin
  LD_LIBRARY_PATH=$creamaracasdll:$LD_LIBRARY_PATH
 
+
+#if [ true = false ]
+#then
 # creaEnvironment
- sh cmakemod.sh $creaenvironmentsource $creaenvironmentbinary
- sh creaenvironmentVariables.sh $creaenvironmentbinary $creabinfolder
- sh compilemod.sh $buildtype $creaenvironmentbinary
- sh ctestmod.sh $creaenvironmentbinary
- creaenvironmentdll=`pwd`/$creaenvironmentbinary
+ sh cmakemod.sh                 $creaenvironmentsource $generationdir $VTKdir $installPrefix $buildType
+
+ sh creaenvironmentVariables.sh $creaenvironmentsource $generationdir $docgeneration
+ sh compilemod.sh $buildtype    $creaenvironmentsource $generationdir
+ sh ctestmod.sh                 $creaenvironmentsource $generationdir
+#fi
+ creaenvironmentdll=$generationdir/tmpCreaTools_INSTALL/creaenvironmentBin
  LD_LIBRARY_PATH=$creaenvironmentdll:$LD_LIBRARY_PATH
 
+#if [ true = false ]
+#then
 # creaBruker
- sh cmakemod.sh $creabrukersource $creabrukerbinary
- sh creaenvironmentVariables.sh $creabrukerbinary $creabinfolder
- sh compilemod.sh $buildtype $creabrukerbinary
- sh ctestmod.sh $creabrukerbinary
- creabrukerdll=`pwd`$creabrukerbinary
+ sh cmakemod.sh                 $creabrukersource $generationdir $VTKdir $installPrefix $buildType
+ sh creaBrukerVariables.sh $creabrukersource $generationdir $docgeneration
+#fi
+ sh compilemod.sh $buildtype    $creabrukersource  $generationdir
+# echo "creaBruker : out of compilemod.sh; stop here, now!"
+# exit 0
+ sh ctestmod.sh                 $creabrukersource $creabinfolder
+ creabrukerdll=$generationdir/tmpCreaTools_INSTALL/creabrukerBin
  LD_LIBRARY_PATH=$creabrukerdll:$LD_LIBRARY_PATH
 
 # creaImageIO
- sh cmakemod.sh $creaimagesourcefolder $creaimagebinary
- sh creaImageIOVariables.sh $creaimagebinary $creabinfolder $bbtkbinfolder $creabrukerbinary
- sh compilemod.sh $buildtype $creaimagebinary
- sh ctestmod.sh $creaimagebinary
- creaimagedll=`pwd`/$creaimagebinary
+ sh cmakemod.sh              $creaimagesource $generationdir $VTKdir $installPrefix $buildType
+ sh creaImageIOVariables.sh  $creaimagesource $generationdir $docgeneration
+ sh compilemod.sh $buildtype $creaimagesource $generationdir
+ sh ctestmod.sh              $creaimagesource $generationdir
+ creaimagedll=$generationdir/tmpCreaTools_INSTALL/creaimageBin
  LD_LIBRARY_PATH=$creaimagedll:$LD_LIBRARY_PATH
 
 # creaContours
- sh cmakemod.sh $creacontourssource $creacontoursbinary
- sh creaContoursVariables.sh $creacontoursbinary $creasourcefolder $creaenvironmentsource $creamaracassourcefolder $creaimagesourcefolder $bbtksourcefolder
- sh compilemod.sh $buildtype $creacontoursbinary
- sh ctestmod.sh $creacontoursbinary
-# creacontourdll=`pwd`/$creacontoursbinary
+ sh cmakemod.sh              $creacontourssource $generationdir $VTKdir $installPrefix $buildType
+ sh creaContoursVariables.sh $creacontourssource $generationdir $docgeneration
+ sh compilemod.sh $buildtype $creacontourssource $generationdir
+ sh ctestmod.sh              $creacontourssource $generationdir
+# creacontourdll=$generationdir/tmpCreaTools_INSTALL/creacontoursBin
 # LD_LIBRARY_PATH=$creacontoursdll:$LD_LIBRARY_PATH
 
 # creaRigidRegistration
- cmakemod.sh $crearigidregistrationssource $crearigidregistrationbinary
- creaRigidRegistrationVariables.sh $crearigidregistrationbinary $creabinfolder $bbtksourcefolder
- compilemod.sh $buildtype $crearigidregistrationbinary
- ctestmod.sh $crearigidregistrationbinary
-# crearigidregistrationdll=`pwd`/$crearigidregistrationbinary
+ sh cmakemod.sh                       $crearigidregistrationssource $generationdir $VTKdir $installPrefix $buildType
+ sh creaRigidRegistrationVariables.sh $crearigidregistrationssource $generationdir $docgeneration
+ sh compilemod.sh $buildtype          $crearigidregistrationssource $generationdir
+ sh ctestmod.sh                       $crearigidregistrationssource $generationdir
+# crearigidregistrationdll=$generationdir/tmpCreaTools_INSTALL/crearigidregistrationBin
 # LD_LIBRARY_PATH=$crearigidregistrationdll:$LD_LIBRARY_PATH
 
 # bbtkGEditor
- sh cmakemod.sh $bbtkgeditorsource $bbtkgeditorbinary
- sh bbtkGEditorVariables.sh $bbtkgeditorbinary $creasourcefolder $bbtksourcefolder $creamaracassourcefolder
- sh compilemod.sh $buildtype $bbtkgeditorbinary
- sh ctestmod.sh $bbtkgeditorbinary
-# bbtkgeditordll=`pwd`/$bbtkgeditorbinary
+ sh cmakemod.sh              $bbtkgeditorsource $generationdir $VTKdir $installPrefix $buildType
+ sh bbtkGEditorVariables.sh  $bbtkgeditorsource $generationdir $docgeneration
+ sh compilemod.sh $buildtype $bbtkgeditorsource $generationdir
+ sh ctestmod.sh              $bbtkgeditorsource $generationdir
+# bbtkgeditordll=$generationdir/tmpCreaTools_INSTALL/bbtkgeditorBin
 # LD_LIBRARY_PATH=$bbtkgeditordll:$LD_LIBRARY_PATH
 
 # creaTools
- sh cmakemod.sh $creatoolssource $creatoolsbinary
- sh creaToolsVariables.sh $creatoolsbinary
- sh compilemodCreaTools.sh $buildtype $creatoolsbinary
-# sh ctestmod.sh $creatoolsbinary
- creatoolsdll=`pwd`/$creatoolsbinary
- LD_LIBRARY_PATH=$creatoolssdll:$LD_LIBRARY_PATH
+ sh cmakemod.sh                    $creatoolssource $generationdir $VTKdir $installPrefix $buildType
+ sh creaToolsVariables.sh          $creatoolssource $generationdir $docgeneration
+ sh compilemod.sh $buildtype       $creatoolssource $generationdir
+# sh ctestmod.sh $creatoolsbinary $generationdir
+#  creatoolsdll=$generationdir/tmpCreaTools_INSTALL/creatoolsBin
+ LD_LIBRARY_PATH=$creatoolssdll:$LD_LIBRARY_PATH
 
 # shutdown /s
 # exit /b