]> Creatis software - creaToolsTools.git/blobdiff - Install_ThirdParty/scripts/download_ThirdPartySW.bat
DFCH: Install_ThirdParty script is now working in windows x64 =)
[creaToolsTools.git] / Install_ThirdParty / scripts / download_ThirdPartySW.bat
index 7c96b27e3c4c084e17b90c4ab5e091677bf6b9b4..a5745d32dd1b77a3a0304ec23b42ca0ba9186772 100644 (file)
@@ -9,8 +9,9 @@ echo -----------------------------------
 
 set thirdpartyGeneration=%1
 set buildType=%2
+set wxStable=%3
 
-set urlCreatisSource=http://www.creatis.insa-lyon.fr/software/public/creatools/crea_ThirdParty_Libraries/source
+:: set urlCreatisSource=http://www.creatis.insa-lyon.fr/software/public/creatools/crea_ThirdParty_Libraries/source
 set urlCreatisSource=http://www.creatis.insa-lyon.fr/~caceres/software
 
 if %PROCESSOR_ARCHITECTURE%==x86 (
@@ -54,14 +55,24 @@ if not exist %wgetPath% (
 set installpath=%thirdpartyGeneration%\thirdparty_install\%buildType%
 set binpath=%thirdpartyGeneration%\thirdparty_bin\%buildType%
 set sourcepath=%thirdpartyGeneration%\thirdparty_source\%buildType%
+set LogFolder=%thirdpartyGeneration%\installLog
 
 set QTFNAME=qt-everywhere-opensource-src-4.8.2.zip
-set WXFNAME=wxWidgets-2.9.3.7z
+
+if %wxStable%==ON (
+       set WXFNAME=wxWidgets-2.8.12.zip
+       set WXVERSION=2.8.12
+) else (
+       set WXFNAME=wxWidgets-2.9.3.zip
+       set WXVERSION=2.9.2
+)
+else
 set BOOSTFNAME=boost_1_49_0.7z
 set XERCESFNAME=xerces-c-3.1.1.zip
 set ITKFNAME=InsightToolkit-3.20.1.zip
 set VTKFNAME=vtk-5.10.0.zip
-set GDCMFNAME=gdcm_11_Oct_2011.tar.gz
+set GDCMFNAME=gdcm_11_Oct_2011.tar
+::set GDCMFNAME=gdcm_05_Mai_2011.tar
 set TTHFNAME=tth_exe.zip
 set JOMFNAME=jom.zip
 
@@ -79,22 +90,6 @@ echo InstallPath=%installpath%
 echo BinPath=%binpath%
 echo SourcePath=%sourcepath%
 
-echo -----------------------------------
-echo -------Removing Folders------------
-echo -----------------------------------
-
-rmdir /S /Q %thirdpartyGeneration%
-
-echo -----------------------------------
-echo -------Creating Folders------------
-echo -----------------------------------
-
-mkdir %thirdpartyGeneration%
-cd  %thirdpartyGeneration%
-mkdir %sourcepath%
-mkdir %binpath%
-mkdir %installpath%
-
 echo -----------------------------------
 echo ------Downloading Sources----------
 echo -----------------------------------
@@ -102,12 +97,12 @@ echo -----------------------------------
 cd %sourcepath%\
 
 %wgetPath% "http://releases.qt-project.org/qt4/source/%QTFNAME%"
-%wgetPath% "http://sourceforge.net/projects/wxwindows/files/2.9.3/%WXFNAME%/download"
+%wgetPath% "http://sourceforge.net/projects/wxwindows/files/%WXVERSION%/%WXFNAME%/download"
 %wgetPath% "http://sourceforge.net/projects/boost/files/boost/1.49.0/%BOOSTFNAME%/download"
 %wgetPath% "http://mirror.ibcp.fr/pub/apache//xerces/c/3/sources/%XERCESFNAME%"
 %wgetPath% "http://sourceforge.net/projects/itk/files/itk/3.20/%ITKFNAME%/download"
 %wgetPath% "http://www.vtk.org/files/release/5.10/%VTKFNAME%"
-%wgetPath% "%urlCreatisSource%/%GDCMFNAME%"
+%wgetPath% "%urlCreatisSource%/%GDCMFNAME%.gz"
 %wgetPath% "http://hutchinson.belmont.ma.us/tth/tth-noncom/%TTHFNAME%"
 %wgetPath% "ftp://ftp.qt.nokia.com/jom/%JOMFNAME%"
 
@@ -134,7 +129,7 @@ echo -----------------------------------
 echo ----------Extracting---------------
 
 cd %sourcepath%
-%zipPath% x %sourcepath%\%WXFNAME% -o*
+%zipPath% x %sourcepath%\%WXFNAME%
   del %sourcepath%\%WXFNAME%
 
 echo -----------------------------------
@@ -153,6 +148,16 @@ cd %sourcepath%
 %zipPath% x %sourcepath%\%VTKFNAME%
 del %sourcepath%\%VTKFNAME%
 
+echo -----------------------------------
+echo ------------GDCM ------------------
+echo -----------------------------------
+
+cd %sourcepath%
+%zipPath% x %GDCMFNAME%.gz
+%zipPath% x %GDCMFNAME%
+del %GDCMFNAME%.gz
+del %GDCMFNAME%
+
 echo -----------------------------------
 echo -------------ITK-------------------
 echo -----------------------------------
@@ -169,16 +174,6 @@ cd %sourcepath%
 %zipPath% x %XERCESFNAME%
 del %XERCESFNAME%
 
-echo -----------------------------------
-echo ------------GDCM ------------------
-echo -----------------------------------
-
-cd %sourcepath%
-%zipPath% x gdcm_11_Oct_2011.tar.gz
-%zipPath% x gdcm_11_Oct_2011.tar
-del gdcm_11_Oct_2011.tar.gz
-del gdcm_11_Oct_2011.tar
-
 echo -----------------------------------
 echo --------------TTH------------------
 echo -----------------------------------
@@ -196,7 +191,7 @@ echo --------Renaming Folders-----------
 echo -----------------------------------
 cd %sourcepath%
 rename qt-everywhere-opensource-src-4.8.2 qt
-rename wxWidgets-2.9.3 wxWidgets
+rename wxWidgets-%WXVERSION% wxWidgets
 rename boost_1_49_0 boost
 rename InsightToolkit-3.20.1 itk
 rename VTK vtk
@@ -206,5 +201,6 @@ rename xerces-c-3.1.1 xerces
 
 echo -----End of Download Libraries-----
 echo -----------------------------------
+echo -----------------------------------
 
 exit /B
\ No newline at end of file