]> Creatis software - creaToolsTools.git/commitdiff
Allow choosing OperatingSystem
authorjean-pierre roux <jean-pierre.roux@creatis.insa-lyon.fr>
Fri, 5 Nov 2010 11:38:51 +0000 (11:38 +0000)
committerjean-pierre roux <jean-pierre.roux@creatis.insa-lyon.fr>
Fri, 5 Nov 2010 11:38:51 +0000 (11:38 +0000)
Install_ThirdParty/Readme.txt
Install_ThirdParty/install_thirdparty.sh_TEMPLATE
Install_ThirdParty/scripts/install_thirdparty_all.sh

index 32570fbf55779e90f742960c9b13fdb93b449642..0722f602796b5c2bfc85d4d68ec8ec129b167109 100644 (file)
@@ -1,5 +1,34 @@
+=== === ===  UNIX / LINUX users === === ===
 
+1) Make sure you are a 'sudoer' :
 
 --sudo configuration--
 https://fedoraproject.org/wiki/Configuring_Sudo
 
+2) Make sure you got the last version of creaToolsTools.
+cvs update -dP creaToolsTools
+
+3)cd Install_ThirdParty
+cp install_thirdparty.sh_TEMPLATE install_thirdparty.sh
+
+4) modify the file install_thirdparty.sh, according to your preferences, modify (only once) creatools.sh
+vim install_thirdparty.sh
+as follows :
+
+-- install_thirdparty.sh ---------------------
+creatoolsGeneration=<directory where you want to generate>
+  installPrefix=$creatoolsGeneration/creatools_install
+       or
+  installPrefix=/usr/local
+buildType=<Release|Debug>
+OperatingSystem=<Fedora | Ubuntu | MacOS>
+cd scripts
+sh install_thirdparty_all.sh $creatoolsGeneration $installPrefix $buildType $OperatingSystem
+cd ..
+-----------------------
+
+5) Run the whole stuff :
+sh install_thirdparty.sh
+
+=== === === WINDOWS users === === ===
+
index fa44d18e3bbda9765a21164288e89463bb9fe914..7ee61f6b94b781d7229790ab3afa9db01b096329 100644 (file)
@@ -1,8 +1,24 @@
-creatoolsGeneration=~/Creatis/All/thirdParty_creatools
-installPrefix=$creatoolsGeneration/thirdparty_install
-buildType=Debug
+USER : Modify the following lines !
+
+creatoolsGeneration=<directory where you want to generate>
+
+installPrefix=$creatoolsGeneration/creatools_install
+#      or
+#installPrefix=/usr/local
+
+buildType=<Release|Debug>
+
+OperatingSystem=<Fedora | Ubuntu | MacOS>
+
+Example :
+
+#creatoolsGeneration=~/Creatis/All/thirdParty_creatools
+#installPrefix=$creatoolsGeneration/thirdparty_install
+#buildType=Debug
+#OperatingSystem=Linux
+
+USER : Hand off!
 
-#sudo pwd
 cd scripts
-sh install_thirdparty_all.sh $creatoolsGeneration $installPrefix $buildType
+sh install_thirdparty_all.sh $creatoolsGeneration $installPrefix $buildType $OperatingSystem
 cd ..
index a63a0b1f371e42f93d9e9f45d4e1d37b8080fa9b..a1537fd8abdfbc19e971d26864982805adba13bb 100644 (file)
@@ -4,9 +4,10 @@
 if [ $# = 0 ]
 then
   echo "Use it as :"
-  echo "sh install_thirdparty_fedora.sh <nameOfTheGenerationDirectory> <installPrefix> <buildType>"  
+  echo "sh install_thirdparty_all.sh <nameOfTheGenerationDirectory> <installPrefix> <buildType> <OperatingSystem>"
+  echo "with 'OperatingSystem' in {Fedora, Ubuntu, MacOS}" 
   echo " "
-  echo "ex : sh install_thirdparty_fedora.sh /tmp/gendir /home/jpr/myInstallDirectory Debug"
+  echo "ex : sh install_thirdparty_all.sh /tmp/gendir ~/Creatis/myInstallDirectory Debug Ubuntu"
   exit 0
 fi
 
@@ -16,14 +17,16 @@ echo $0
 echo $1
 echo $2
 echo $3
+echo $4
 echo "----------"
 
-if [ $# != 3 ]
+if [ $# != 4 ]
 then 
   echo "Use it as :"
-  echo "sh install_thirdparty_fedora.sh <nameOfTheGenerationDirectory> <installPrefix> <buildType>"
+  echo "sh install_thirdparty_all.sh <nameOfTheGenerationDirectory> <installPrefix> <buildType> <OperatingSystem>"
+  echo "with 'OperatingSystem' in {Fedora, Ubuntu, MacOS}" 
   echo " "
-  echo "ex : sh install_thirdparty_fedora.sh /tmp/gendir /home/jpr/myInstallDirectory Debug"
+  echo "ex : sh install_thirdparty_all.sh /tmp/gendir ~/Creatis/myInstallDirectory Debug Ubuntu"
   exit 0
 fi
 
@@ -31,6 +34,7 @@ fi
 generationdir=$1
 installPrefix=$2
 buildType=$3
+OS=$4
 
 scriptDir=$PWD
 sourcesDir=$generationdir/thirdparty_sources
@@ -43,17 +47,51 @@ mkdir $binDir
 # the following stupid test is used at debug time; Please don't remove!
 if [ true = true ]
 then
-  sudo yum install cmake -y 
-  sudo yum install cmake-gui -y 
-  sudo yum install doxygen -y
-  sudo yum install graphviz -y
-  sudo yum install texlive -y
-  sudo yum install latex2html -y
-  sudo yum install wxGTK-devel wxBase -y
-  sudo yum install boost-devel -y
-  sudo yum install sqlite-devel -y
-  sudo yum install qt-devel -y
-  sudo yum install mesa-libOSMesa-devel -y
+
+  case $OS in
+  Fedora)
+     sudo yum install cmake -y 
+     sudo yum install cmake-gui -y 
+     sudo yum install doxygen -y
+     sudo yum install graphviz -y
+     sudo yum install texlive -y
+     sudo yum install latex2html -y
+     sudo yum install wxGTK-devel wxBase -y
+     sudo yum install boost-devel -y
+     sudo yum install sqlite-devel -y
+     sudo yum install qt-devel -y
+     sudo yum install mesa-libOSMesa-devel -y
+     ;;
+  Ubuntu)  
+     sudo apt-get --yes install build-essential  # esta linea instala las librerias necesarias para compilar en ubuntu, g++ gcc etc etc etc.
+     sudo apt-get --yes install cmake
+     sudo apt-get --yes install cmake-gui
+     sudo apt-get --yes install cmake-curses-gui
+     sudo apt-get --yes install doxygen
+     sudo apt-get --yes install graphviz
+     sudo apt-get --yes install texlive
+     sudo apt-get --yes install latex2html
+     sudo apt-get --yes install libgtk2.0-dev #GTK
+     sudo apt-get --yes install libwxgtk2.8-dev #Wx GTK
+     sudo apt-get --yes install libwxbase2.8-dev #Wx solito
+     sudo apt-get --yes install libboost-dev  #Boost
+     sudo apt-get --yes install libboost-all-dev #Boost
+     sudo apt-get --yes install libqt4-dev #QT4
+     sudo apt-get --yes install sqlite
+     sudo apt-get --yes install libosmesa6-dev #Mesa6
+     sudo apt-get --yes install uuid-dev # uuid para la instalacion de itk
+     sudo apt-get --yes install libxaw7-dev # X11
+     ;;
+  MacOS)
+     echo "MacOS not yet dealt with ..."
+     exit 0
+     ;;
+  *)
+     echo " '$OS' : Unknown (for us...) Operating Sytem "
+     echo " Allowed values are (right now) Fedora, Ubuntu, MacOS "
+     exit 0
+     ;;
+  esac             
 fi