X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Install%2Fscripts%2Fmake.sh;h=1f2214a46aeae81f0144c24490d02c8e80040149;hb=a5fce6cfe871e7dee66e6e7c064ef9e632a5c192;hp=0be85d92b774faea22ca45764aa8e3f8143c9eb2;hpb=1e6fb2a6d9f7121744d84bebd763a8c5932a5fea;p=creaToolsTools.git diff --git a/Install/scripts/make.sh b/Install/scripts/make.sh index 0be85d9..1f2214a 100644 --- a/Install/scripts/make.sh +++ b/Install/scripts/make.sh @@ -1,81 +1,36 @@ #!/bin/sh -if [ $# = 0 ] -then -echo "Use it as :" -echo "sh make-install.sh " -echo "with 'installPrefix' : /usr/local or /creatools_install" -echo "with 'GDCM Version' : GDCM1 / GDCM2" -echo "with 'creaTools sources' : where do you want to get them from ? CVS / HTML" -echo " " -echo "ex : sh make-install.sh /tmp/gendir OFF jpr /tmp/gendir/creatools_install Debug GDCM2 HTML" -exit 0 -fi +# Set all local variables + + +source $PWD/configure.sh +echo "------" +echo $PWD/configure.sh +echo generationdir +echo $generationdir +echo docgeneration +echo $docgeneration +echo installPrefix +echo $installPrefix +echo buildType +echo $buildType +echo gdcmVersion +echo $gdcmVersion +echo sourcesFrom +echo $sourcesFrom +echo scriptDir +echo $scriptDir +echo start_point +echo $start_point +echo "------" -echo $# -echo "----------" -echo $0 -echo $1 -echo $2 -echo $3 -echo $4 -echo $5 -echo $6 -echo $7 -echo "----------" - -if [ $# != 6 ] -then -echo "Use it as :" -echo "sh make-install.sh " -echo "with 'installPrefix' : /usr/local or /creatools_install" -echo "with 'GDCM Version' : GDCM1 / GDCM2" -echo "with 'creaTools sources' : where do you want to get them from ? CVS / HTML" -echo " " -echo "ex : sh make-install.sh /tmp/gendir OFF jpr /tmp/gendir/creatools_install Debug GDCM2 HTML" -exit 0 -fi -# @echo off - -#allow user to choose the generation dir -#allow user to choose to generate the doc or not -#allow user to choose where he wants to get the sources from : CVS / HTML - -generationdir=$1 -docGeneration=$2 -cvsUserName=$3 -installPrefix=$4 -buildType=$5 -gdcmVersion=$6 -sourcesFrom=$7 - -scriptDir=$PWD - - creasource=crea - bbtksource=bbtk - creamaracassource=creaMaracasVisu - creaenvironmentsource=creaEnvironment - creabrukersource=creaBruker - creaimagesource=creaImageIO - creacontourssource=creaContours - crearigidregistrationssource=creaRigidRegistration - bbtkgeditorsource=bbtkGEditor - creatoolssource=creaTools - mkdir $generationdir mkdir $generationdir/creatools_source mkdir $generationdir/creatools_bin cd $generationdir -# start_point : used at debug time : start point of the script -# ex : if everything is OK, but bbtkGEditor, -# cvs upate bbtkGEditor manually,and use : -# start_point=10 -# in order not to cvs co everything, nor recompile everything. - -start_point=0 # -------------------------------- # start_point = 0 : remove everything that was created before @@ -96,6 +51,8 @@ fi # ---------------------------------- # start_point = 1 : Load all sources #----------------------------------- + + if [ $start_point -le 1 ] then if [ true = true ] @@ -118,22 +75,36 @@ then if [ $sourcesFrom = HTML ] then - echo - echo - echo - echo "Fix the name of the place with tar.gz file " - echo - echo - echo - exit 0 - wget http://www.creatis.insa-lyon.fr/~davila/CreaTools/XXXXXXXX.tgz - tar xvzf XXXXXXX.tgz - + cd $generationdir/creatools_source + wwwtargz=http://www.creatis.insa-lyon.fr/software/public/creatools/creaTools/nightly/ + + wget $wwwtargz/crea.tgz + wget $wwwtargz/bbtk.tgz + wget $wwwtargz/creaMaracasVisu.tgz + wget $wwwtargz/creaEnvironment.tgz + wget $wwwtargz/creaBruker.tgz + wget $wwwtargz/creaImageIO.tgz + wget $wwwtargz/creaContours.tgz + wget $wwwtargz/creaRigidRegistration.tgz + wget $wwwtargz/bbtkGEditor.tgz + wget $wwwtargz/creaTools.tgz + + tar xvzf crea.tgz + tar xvzf bbtk.tgz + tar xvzf creaMaracasVisu.tgz + tar xvzf creaEnvironment.tgz + tar xvzf creaBruker.tgz + tar xvzf creaImageIO.tgz + tar xvzf creaContours.tgz + tar xvzf creaRigidRegistration.tgz + tar xvzf bbtkGEditor.tgz + tar xvzf creaTools.tgz + + rm -f *.tgz fi fi fi - cd $scriptDir # ------------------------- @@ -146,17 +117,16 @@ then #if [ true = false ] if [ true = true ] then - sh cmakemod.sh $creasource $generationdir $installPrefix $buildType - sh creaVariables.sh $creasource $generationdir $docgeneration - sh compilemod.sh $buildType $creasource $generationdir - sh ctestmod.sh $creasource $generationdir + sh $scriptDir/cmakemod.sh $creasource $generationdir $installPrefix $buildType + sh $scriptDir/creaVariables.sh $creasource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $creasource $generationdir + sh $scriptDir/ctestmod.sh $creasource $generationdir fi fi creadll=$generationdir/creatools_bin/creaBin LD_LIBRARY_PATH=$creadll:LD_LIBRARY_$PATH - # ------------------------- # start_point = 3 : BBTK #------------------------- @@ -167,10 +137,10 @@ then if [ true = true ] then # BBTK - sh cmakemod.sh $bbtksource $generationdir $installPrefix $buildType - sh bbtkVariables.sh $bbtksource $generationdir $docgeneration $gdcmVersion - sh compilemod.sh $buildType $bbtksource $generationdir - sh ctestmod.sh $bbtksource $generationdir + sh $scriptDir/cmakemod.sh $bbtksource $generationdir $installPrefix $buildType + sh $scriptDir/bbtkVariables.sh $bbtksource $generationdir $docgeneration $gdcmVersion + sh $scriptDir/compilemod.sh $buildType $bbtksource $generationdir + sh $scriptDir/ctestmod.sh $bbtksource $generationdir fi fi bbtkdll=$generationdir/creatools_bin/bbtkBin @@ -187,10 +157,10 @@ then if [ true = true ] then # creaMaracasVisu - sh cmakemod.sh $creamaracassource $generationdir $installPrefix $buildType - sh creaMaracasVariables.sh $creamaracassource $generationdir $docgeneration - sh compilemod.sh $buildType $creamaracassource $generationdir - sh ctestmod.sh $creamaracassource $generationdir + sh $scriptDir/cmakemod.sh $creamaracassource $generationdir $installPrefix $buildType + sh $scriptDir/creaMaracasVariables.sh $creamaracassource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $creamaracassource $generationdir + sh $scriptDir/ctestmod.sh $creamaracassource $generationdir fi fi creamaracasdll=$generationdir/creatools_bin/creamaracasBin @@ -207,10 +177,10 @@ then if [ true = true ] then # creaEnvironment - sh cmakemod.sh $creaenvironmentsource $generationdir $installPrefix $buildType - sh creaenvironmentVariables.sh $creaenvironmentsource $generationdir $docgeneration - sh compilemod.sh $buildType $creaenvironmentsource $generationdir - sh ctestmod.sh $creaenvironmentsource $generationdir + sh $scriptDir/cmakemod.sh $creaenvironmentsource $generationdir $installPrefix $buildType + sh $scriptDir/creaenvironmentVariables.sh $creaenvironmentsource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $creaenvironmentsource $generationdir + sh $scriptDir/ctestmod.sh $creaenvironmentsource $generationdir fi fi creaenvironmentdll=$generationdir/creatools_bin/creaenvironmentBin @@ -227,10 +197,10 @@ then if [ true = true ] then # creaBruker - sh cmakemod.sh $creabrukersource $generationdir $installPrefix $buildType - sh creaBrukerVariables.sh $creabrukersource $generationdir $docgeneration $gdcmVersion - sh compilemod.sh $buildType $creabrukersource $generationdir - sh ctestmod.sh $creabrukersource $generationdir + sh $scriptDir/cmakemod.sh $creabrukersource $generationdir $installPrefix $buildType + sh $scriptDir/creaBrukerVariables.sh $creabrukersource $generationdir $docgeneration $gdcmVersion + sh $scriptDir/compilemod.sh $buildType $creabrukersource $generationdir + sh $scriptDir/ctestmod.sh $creabrukersource $generationdir fi fi creabrukerdll=$generationdir/creatools_bin/creabrukerBin @@ -247,10 +217,10 @@ then if [ true = true ] then # creaImageIO - sh cmakemod.sh $creaimagesource $generationdir $installPrefix $buildType - sh creaImageIOVariables.sh $creaimagesource $generationdir $docgeneration $gdcmVersion - sh compilemod.sh $buildType $creaimagesource $generationdir - sh ctestmod.sh $creaimagesource $generationdir + sh $scriptDir/cmakemod.sh $creaimagesource $generationdir $installPrefix $buildType + sh $scriptDir/creaImageIOVariables.sh $creaimagesource $generationdir $docgeneration $gdcmVersion + sh $scriptDir/compilemod.sh $buildType $creaimagesource $generationdir + sh $scriptDir/ctestmod.sh $creaimagesource $generationdir fi fi creaimagedll=$generationdir/creatools_bin/creaimageBin @@ -267,10 +237,10 @@ then if [ true = true ] then # creaContours - sh cmakemod.sh $creacontourssource $generationdir $installPrefix $buildType - sh creaContoursVariables.sh $creacontourssource $generationdir $docgeneration - sh compilemod.sh $buildType $creacontourssource $generationdir - sh ctestmod.sh $creacontourssource $generationdir + sh $scriptDir/cmakemod.sh $creacontourssource $generationdir $installPrefix $buildType + sh $scriptDir/creaContoursVariables.sh $creacontourssource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $creacontourssource $generationdir + sh $scriptDir/ctestmod.sh $creacontourssource $generationdir fi fi # creacontourdll=$generationdir/creatools_bin/creacontoursBin @@ -286,10 +256,10 @@ then #if [ true = false ] if [ true = true ] then - sh cmakemod.sh $crearigidregistrationssource $generationdir $installPrefix $buildType - sh creaRigidRegistrationVariables.sh $crearigidregistrationssource $generationdir $docgeneration - sh compilemod.sh $buildType $crearigidregistrationssource $generationdir - sh ctestmod.sh $crearigidregistrationssource $generationdir + sh $scriptDir/cmakemod.sh $crearigidregistrationssource $generationdir $installPrefix $buildType + sh $scriptDir/creaRigidRegistrationVariables.sh $crearigidregistrationssource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $crearigidregistrationssource $generationdir + sh $scriptDir/ctestmod.sh $crearigidregistrationssource $generationdir fi fi # crearigidregistrationdll=$generationdir/creatools_bin/crearigidregistrationBin @@ -306,10 +276,10 @@ then if [ true = true ] then # bbtkGEditor - sh cmakemod.sh $bbtkgeditorsource $generationdir $installPrefix $buildType - sh bbtkGEditorVariables.sh $bbtkgeditorsource $generationdir $docgeneration - sh compilemod.sh $buildType $bbtkgeditorsource $generationdir - sh ctestmod.sh $bbtkgeditorsource $generationdir + sh $scriptDir/cmakemod.sh $bbtkgeditorsource $generationdir $installPrefix $buildType + sh $scriptDir/bbtkGEditorVariables.sh $bbtkgeditorsource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $bbtkgeditorsource $generationdir + sh $scriptDir/ctestmod.sh $bbtkgeditorsource $generationdir fi fi # bbtkgeditordll=$generationdir/creatools_bin/bbtkgeditorBin @@ -326,9 +296,9 @@ then if [ true = true ] then # creaTools - sh cmakemod.sh $creatoolssource $generationdir $installPrefix $buildType - sh creaToolsVariables.sh $creatoolssource $generationdir $docgeneration - sh compilemod.sh $buildType $creatoolssource $generationdir + sh $scriptDir/cmakemod.sh $creatoolssource $generationdir $installPrefix $buildType + sh $scriptDir/creaToolsVariables.sh $creatoolssource $generationdir $docgeneration + sh $scriptDir/compilemod.sh $buildType $creatoolssource $generationdir fi fi