]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
Add auto-downloading libtiff to spandsp build
authorMichael Jerris <mike@jerris.com>
Sat, 21 Feb 2009 00:03:22 +0000 (00:03 +0000)
committerMichael Jerris <mike@jerris.com>
Sat, 21 Feb 2009 00:03:22 +0000 (00:03 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@12212 d0543943-73ff-0310-b7d9-9358b9ac24b2

libs/spandsp/src/Makefile.am
libs/spandsp/src/libspandsp.2005.sln
libs/spandsp/src/libspandsp.2008.sln
libs/spandsp/src/msvc/Download_TIFF.2005.vcproj [new file with mode: 0644]
libs/spandsp/src/msvc/Download_TIFF.2008.vcproj [new file with mode: 0644]
libs/spandsp/src/msvc/tiff/cleancount [new file with mode: 0644]
libs/spandsp/src/msvc/util.vbs [new file with mode: 0644]

index 8ce5d9e123e34a649309a3ef419bb0a47990c6a6..1169b3bb57a698fc94380f529c784068062e0d77 100644 (file)
@@ -44,6 +44,9 @@ EXTRA_DIST = floating_fudge.h \
              msvc/make_modem_filter.2008.vcproj \\r
              msvc/make_at_dictionary.2005.vcproj \\r
              msvc/make_modem_filter.2005.vcproj \\r
+             msvc/Download_TIFF.2008.vcproj \\r
+             msvc/Download_TIFF.2005.vcproj \\r
+             msvc/tiff/cleancout \\r
              msvc/msvcproj.head \\r
              msvc/msvcproj.foot \\r
              msvc/vc8proj.head \\r
index 5efdaf04543e89ae6e5c491375ac3769c76aaa2b..b78079b0c3660fb0511cfd04e50290c5ef2475c1 100644 (file)
@@ -11,25 +11,45 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libspandsp", "libspandsp.20
        EndProjectSection\r
 EndProject\r
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libtiff", "libtiff.2005.vcproj", "{401A40CD-5DB4-4E34-AC68-FA99E9FAC014}"\r
+       ProjectSection(ProjectDependencies) = postProject\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917} = {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}\r
+       EndProjectSection\r
+EndProject\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Download TIFF", "msvc\Download_TIFF.2005.vcproj", "{2B8A45C9-FEB4-4734-AB37-8DB9DB899917}"\r
 EndProject\r
 Global\r
        GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
+               All|Win32 = All|Win32\r
                Debug|Win32 = Debug|Win32\r
                Release|Win32 = Release|Win32\r
        EndGlobalSection\r
        GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
+               {DEE932AB-5911-4700-9EEB-8C7090A0A330}.All|Win32.ActiveCfg = All|Win32\r
+               {DEE932AB-5911-4700-9EEB-8C7090A0A330}.All|Win32.Build.0 = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Debug|Win32.ActiveCfg = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Release|Win32.ActiveCfg = All|Win32\r
+               {329A6FA0-0FCC-4435-A950-E670AEFA9838}.All|Win32.ActiveCfg = All|Win32\r
+               {329A6FA0-0FCC-4435-A950-E670AEFA9838}.All|Win32.Build.0 = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Debug|Win32.ActiveCfg = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Release|Win32.ActiveCfg = All|Win32\r
+               {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.All|Win32.ActiveCfg = Release|Win32\r
+               {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.All|Win32.Build.0 = Release|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Debug|Win32.Build.0 = Debug|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Release|Win32.ActiveCfg = Release|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Release|Win32.Build.0 = Release|Win32\r
+               {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.All|Win32.ActiveCfg = Release|Win32\r
+               {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.All|Win32.Build.0 = Release|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Debug|Win32.Build.0 = Debug|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Release|Win32.ActiveCfg = Release|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Release|Win32.Build.0 = Release|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.All|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.All|Win32.Build.0 = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Debug|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Debug|Win32.Build.0 = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Release|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Release|Win32.Build.0 = All|Win32\r
        EndGlobalSection\r
        GlobalSection(SolutionProperties) = preSolution\r
                HideSolutionNode = FALSE\r
index fd9bc745d6b27f54eed64181f14eca06aa737db2..2602184d38454bcef1202286cf6bb4e66b51d444 100644 (file)
@@ -11,25 +11,41 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libspandsp", "libspandsp.20
        EndProjectSection\r
 EndProject\r
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libtiff", "libtiff.2008.vcproj", "{401A40CD-5DB4-4E34-AC68-FA99E9FAC014}"\r
+       ProjectSection(ProjectDependencies) = postProject\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917} = {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}\r
+       EndProjectSection\r
+EndProject\r
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Download TIFF", "msvc\Download_TIFF.2008.vcproj", "{2B8A45C9-FEB4-4734-AB37-8DB9DB899917}"\r
 EndProject\r
 Global\r
        GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
+               All|Win32 = All|Win32\r
+               All|x64 = All|x64\r
                Debug|Win32 = Debug|Win32\r
                Debug|x64 = Debug|x64\r
                Release|Win32 = Release|Win32\r
                Release|x64 = Release|x64\r
        EndGlobalSection\r
        GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
+               {DEE932AB-5911-4700-9EEB-8C7090A0A330}.All|Win32.ActiveCfg = All|Win32\r
+               {DEE932AB-5911-4700-9EEB-8C7090A0A330}.All|Win32.Build.0 = All|Win32\r
+               {DEE932AB-5911-4700-9EEB-8C7090A0A330}.All|x64.ActiveCfg = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Debug|Win32.ActiveCfg = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Debug|Win32.Build.0 = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Debug|x64.ActiveCfg = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Release|Win32.ActiveCfg = All|Win32\r
                {DEE932AB-5911-4700-9EEB-8C7090A0A330}.Release|x64.ActiveCfg = All|Win32\r
+               {329A6FA0-0FCC-4435-A950-E670AEFA9838}.All|Win32.ActiveCfg = All|Win32\r
+               {329A6FA0-0FCC-4435-A950-E670AEFA9838}.All|Win32.Build.0 = All|Win32\r
+               {329A6FA0-0FCC-4435-A950-E670AEFA9838}.All|x64.ActiveCfg = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Debug|Win32.ActiveCfg = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Debug|Win32.Build.0 = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Debug|x64.ActiveCfg = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Release|Win32.ActiveCfg = All|Win32\r
                {329A6FA0-0FCC-4435-A950-E670AEFA9838}.Release|x64.ActiveCfg = All|Win32\r
+               {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.All|Win32.ActiveCfg = Release|x64\r
+               {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.All|x64.ActiveCfg = Release|x64\r
+               {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.All|x64.Build.0 = Release|x64\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Debug|Win32.Build.0 = Debug|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Debug|x64.ActiveCfg = Debug|x64\r
@@ -38,6 +54,9 @@ Global
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Release|Win32.Build.0 = Release|Win32\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Release|x64.ActiveCfg = Release|x64\r
                {1CBB0077-18C5-455F-801C-0A0CE7B0BBF5}.Release|x64.Build.0 = Release|x64\r
+               {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.All|Win32.ActiveCfg = Release|x64\r
+               {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.All|x64.ActiveCfg = Release|x64\r
+               {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.All|x64.Build.0 = Release|x64\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Debug|Win32.ActiveCfg = Debug|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Debug|Win32.Build.0 = Debug|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Debug|x64.ActiveCfg = Debug|x64\r
@@ -46,6 +65,15 @@ Global
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Release|Win32.Build.0 = Release|Win32\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Release|x64.ActiveCfg = Release|x64\r
                {401A40CD-5DB4-4E34-AC68-FA99E9FAC014}.Release|x64.Build.0 = Release|x64\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.All|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.All|Win32.Build.0 = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.All|x64.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Debug|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Debug|Win32.Build.0 = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Debug|x64.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Release|Win32.ActiveCfg = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Release|Win32.Build.0 = All|Win32\r
+               {2B8A45C9-FEB4-4734-AB37-8DB9DB899917}.Release|x64.ActiveCfg = All|Win32\r
        EndGlobalSection\r
        GlobalSection(SolutionProperties) = preSolution\r
                HideSolutionNode = FALSE\r
diff --git a/libs/spandsp/src/msvc/Download_TIFF.2005.vcproj b/libs/spandsp/src/msvc/Download_TIFF.2005.vcproj
new file mode 100644 (file)
index 0000000..d585351
--- /dev/null
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="Windows-1252"?>\r
+<VisualStudioProject\r
+       ProjectType="Visual C++"\r
+       Version="8.00"\r
+       Name="Download TIFF"\r
+       ProjectGUID="{2B8A45C9-FEB4-4734-AB37-8DB9DB899917}"\r
+       RootNamespace="Download TIFF"\r
+       Keyword="Win32Proj"\r
+       TargetFrameworkVersion="131072"\r
+       >\r
+       <Platforms>\r
+               <Platform\r
+                       Name="Win32"\r
+               />\r
+       </Platforms>\r
+       <ToolFiles>\r
+       </ToolFiles>\r
+       <Configurations>\r
+               <Configuration\r
+                       Name="All|Win32"\r
+                       OutputDirectory="$(SolutionDir)$(ConfigurationName)"\r
+                       IntermediateDirectory="$(ConfigurationName)"\r
+                       ConfigurationType="10"\r
+                       CharacterSet="2"\r
+                       BuildLogFile="$(IntDir)\BuildLog $(ProjectName).htm"\r
+                       >\r
+               </Configuration>\r
+       </Configurations>\r
+       <References>\r
+       </References>\r
+       <Files>\r
+               <File\r
+                       RelativePath=".\tiff\cleancount"\r
+                       >\r
+                       <FileConfiguration\r
+                               Name="All|Win32"\r
+                               >\r
+                               <Tool\r
+                                       Name="VCCustomBuildTool"\r
+                                       Description="Downloading Tiff."\r
+                                       CommandLine="if not exist &quot;$(ProjectDir)..\..\..\tiff-3.8.2&quot; cscript /nologo &quot;$(ProjectDir)util.vbs&quot; GetUnzip http://svn.freeswitch.org/downloads/libs/tiff-3.8.2.tar.gz &quot;$(ProjectDir)..\..\..&quot;&#x0D;&#x0A;"\r
+                                       Outputs="$(ProjectDir)..\..\..\tiff-3.8.2"\r
+                               />\r
+                       </FileConfiguration>\r
+               </File>\r
+       </Files>\r
+       <Globals>\r
+       </Globals>\r
+</VisualStudioProject>\r
diff --git a/libs/spandsp/src/msvc/Download_TIFF.2008.vcproj b/libs/spandsp/src/msvc/Download_TIFF.2008.vcproj
new file mode 100644 (file)
index 0000000..a7bc466
--- /dev/null
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="Windows-1252"?>\r
+<VisualStudioProject\r
+       ProjectType="Visual C++"\r
+       Version="9.00"\r
+       Name="Download TIFF"\r
+       ProjectGUID="{2B8A45C9-FEB4-4734-AB37-8DB9DB899917}"\r
+       RootNamespace="Download TIFF"\r
+       Keyword="Win32Proj"\r
+       TargetFrameworkVersion="131072"\r
+       >\r
+       <Platforms>\r
+               <Platform\r
+                       Name="Win32"\r
+               />\r
+       </Platforms>\r
+       <ToolFiles>\r
+       </ToolFiles>\r
+       <Configurations>\r
+               <Configuration\r
+                       Name="All|Win32"\r
+                       OutputDirectory="$(SolutionDir)$(ConfigurationName)"\r
+                       IntermediateDirectory="$(ConfigurationName)"\r
+                       ConfigurationType="10"\r
+                       CharacterSet="2"\r
+                       BuildLogFile="$(IntDir)\BuildLog $(ProjectName).htm"\r
+                       >\r
+               </Configuration>\r
+       </Configurations>\r
+       <References>\r
+       </References>\r
+       <Files>\r
+               <File\r
+                       RelativePath=".\tiff\cleancount"\r
+                       >\r
+                       <FileConfiguration\r
+                               Name="All|Win32"\r
+                               >\r
+                               <Tool\r
+                                       Name="VCCustomBuildTool"\r
+                                       Description="Downloading Tiff."\r
+                                       CommandLine="if not exist &quot;$(ProjectDir)..\..\..\tiff-3.8.2&quot; cscript /nologo &quot;$(ProjectDir)util.vbs&quot; GetUnzip http://svn.freeswitch.org/downloads/libs/tiff-3.8.2.tar.gz &quot;$(ProjectDir)..\..\..&quot;&#x0D;&#x0A;"\r
+                                       Outputs="$(ProjectDir)..\..\..\tiff-3.8.2"\r
+                               />\r
+                       </FileConfiguration>\r
+               </File>\r
+       </Files>\r
+       <Globals>\r
+       </Globals>\r
+</VisualStudioProject>\r
diff --git a/libs/spandsp/src/msvc/tiff/cleancount b/libs/spandsp/src/msvc/tiff/cleancount
new file mode 100644 (file)
index 0000000..56a6051
--- /dev/null
@@ -0,0 +1 @@
+1
\ No newline at end of file
diff --git a/libs/spandsp/src/msvc/util.vbs b/libs/spandsp/src/msvc/util.vbs
new file mode 100644 (file)
index 0000000..c866885
--- /dev/null
@@ -0,0 +1,199 @@
+'\r
+' Contributor(s):\r
+' Michael Jerris <mike@jerris.com>\r
+' David A. Horner http://dave.thehorners.com\r
+'----------------------------------------------\r
+\r
+'On Error Resume Next\r
+' **************\r
+' Initialization\r
+' **************\r
+\r
+Set WshShell = CreateObject("WScript.Shell")\r
+Set FSO = CreateObject("Scripting.FileSystemObject")\r
+Set WshSysEnv = WshShell.Environment("SYSTEM")\r
+Set xml = CreateObject("Microsoft.XMLHTTP")\r
+Dim UseWgetEXE\r
+\r
+On Error Resume Next\r
+Set oStream = CreateObject("Adodb.Stream")\r
+On Error Goto 0\r
+\r
+If Not IsObject(oStream)  Then\r
+       wscript.echo("Failed to create Adodb.Stream, using alternative download method.")\r
+       UseWgetEXE=true\r
+Else\r
+       UseWgetEXE=false\r
+End If\r
+Randomize\r
+Set objArgs = WScript.Arguments\r
+quote=Chr(34)\r
+ScriptDir=Left(WScript.ScriptFullName,Len(WScript.ScriptFullName)-Len(WScript.ScriptName))\r
+UtilsDir=Showpath(ScriptDir)\r
+ToolsBase="http://svn.freeswitch.org/downloads/win32/"\r
+\r
+If UseWgetEXE Then\r
+       GetWgetEXE UtilsDir\r
+End If\r
+\r
+GetCompressionTools UtilsDir\r
+\r
+\r
+If objArgs.Count >=3 Then\r
+       Select Case objArgs(0)\r
+               Case "Get"              \r
+                       Wget objArgs(1), Showpath(objArgs(2))\r
+               Case "GetUnzip"         \r
+                       WgetUnCompress objArgs(1), Showpath(objArgs(2))\r
+       End Select\r
+End If\r
+\r
+\r
+' *******************\r
+' Utility Subroutines\r
+' *******************\r
+\r
+\r
+Sub WgetUnCompress(URL, DestFolder)\r
+       If Right(DestFolder, 1) <> "\" Then DestFolder = DestFolder & "\" End If\r
+       StartPos = InstrRev(URL, "/", -1, 1) \r
+       strlength = Len(URL)\r
+       filename=Right(URL,strlength-StartPos)\r
+       NameEnd = InstrRev(filename, ".",-1, 1)\r
+       filestrlength = Len(filename)\r
+       filebase = Left(filename,NameEnd)\r
+       fileext = Right(filename, Len(filename) - NameEnd)\r
+       Wget URL, DestFolder\r
+       If fileext = "zip" Then\r
+               UnCompress Destfolder & filename, DestFolder & filebase\r
+       Else\r
+               UnCompress Destfolder & filename, DestFolder    \r
+       End If\r
+End Sub\r
+\r
+Sub GetCompressionTools(DestFolder)\r
+       Dim oExec\r
+       If Right(DestFolder, 1) <> "\" Then DestFolder = DestFolder & "\" End If\r
+       If Not FSO.FileExists(DestFolder & "7za.exe") Then \r
+               If Not FSO.FileExists(DestFolder & "7za.tag") Then \r
+                       Set MyFile = fso.CreateTextFile(DestFolder & "7za.tag", True)\r
+                       MyFile.WriteLine("This file marks a pending download for 7za.exe so we don't download it twice at the same time")\r
+                       MyFile.Close\r
+                               \r
+                               Wget ToolsBase & "7za.exe", DestFolder\r
+                       \r
+                       FSO.DeleteFile DestFolder & "7za.tag" ,true \r
+               Else\r
+                       WScript.Sleep(5000)\r
+               End If  \r
+       End If  \r
+End Sub\r
+\r
+Sub GetWgetEXE(DestFolder)\r
+       Dim oExec\r
+       If Right(DestFolder, 1) <> "\" Then DestFolder = DestFolder & "\" End If\r
+       If Not FSO.FileExists(DestFolder & "wget.exe") Then \r
+               Slow_Wget ToolsBase & "wget.exe", DestFolder\r
+       End If  \r
+End Sub\r
+\r
+Sub UnCompress(Archive, DestFolder)\r
+       batname = "tmp" & CStr(Int(10000*Rnd)) & ".bat"\r
+       wscript.echo("Extracting: " & Archive)\r
+       Set MyFile = fso.CreateTextFile(UtilsDir & batname, True)\r
+       MyFile.WriteLine("@" & quote & UtilsDir & "7za.exe" & quote & " x " & quote & Archive & quote & " -y -o" & quote & DestFolder & quote )\r
+       MyFile.Close\r
+       Set oExec = WshShell.Exec(UtilsDir & batname)\r
+       Do\r
+               WScript.Echo OExec.StdOut.ReadLine()\r
+       Loop While Not OExec.StdOut.atEndOfStream\r
+       If FSO.FileExists(Left(Archive, Len(Archive)-3))Then  \r
+               Set MyFile = fso.CreateTextFile(UtilsDir & batname, True)\r
+               MyFile.WriteLine("@" & quote & UtilsDir & "7za.exe" & quote & " x " & quote & Left(Archive, Len(Archive)-3) & quote & " -y -o" & quote & DestFolder & quote )\r
+               MyFile.Close\r
+               Set oExec = WshShell.Exec(UtilsDir & batname)\r
+               Do\r
+                       WScript.Echo OExec.StdOut.ReadLine()\r
+               Loop While Not OExec.StdOut.atEndOfStream\r
+               WScript.Sleep(500)\r
+               FSO.DeleteFile Left(Archive, Len(Archive)-3) ,true \r
+       End If\r
+       If FSO.FileExists(Left(Archive, Len(Archive)-3) & "tar")Then  \r
+               Set MyFile = fso.CreateTextFile(UtilsDir & batname, True)\r
+               MyFile.WriteLine("@" & quote & UtilsDir & "7za.exe" & quote & " x " & quote & Left(Archive, Len(Archive)-3) & "tar" & quote & " -y -o" & quote & DestFolder & quote )\r
+               MyFile.Close\r
+               Set oExec = WshShell.Exec(UtilsDir & batname)\r
+               Do\r
+                       WScript.Echo OExec.StdOut.ReadLine()\r
+               Loop While Not OExec.StdOut.atEndOfStream\r
+               WScript.Sleep(500)\r
+               FSO.DeleteFile Left(Archive, Len(Archive)-3) & "tar",true \r
+       End If\r
+       \r
+       WScript.Sleep(500)\r
+       If FSO.FileExists(UtilsDir & batname)Then  \r
+               FSO.DeleteFile UtilsDir & batname, True\r
+       End If\r
+End Sub\r
+\r
+Sub Wget(URL, DestFolder)\r
+       StartPos = InstrRev(URL, "/", -1, 1)   \r
+       strlength = Len(URL)\r
+       filename=Right(URL,strlength-StartPos)\r
+       If Right(DestFolder, 1) <> "\" Then DestFolder = DestFolder & "\" End If\r
+\r
+       Wscript.echo("Downloading: " & URL)\r
+       \r
+If UseWgetEXE Then\r
+       batname = "tmp" & CStr(Int(10000*Rnd)) & ".bat"\r
+       Set MyFile = fso.CreateTextFile(UtilsDir & batname, True)\r
+       MyFile.WriteLine("@cd " & quote & DestFolder & quote)\r
+       MyFile.WriteLine("@" & quote & UtilsDir & "wget.exe" & quote & " " & URL)\r
+       MyFile.Close\r
+       Set oExec = WshShell.Exec(UtilsDir & batname)\r
+       Do\r
+               WScript.Echo OExec.StdOut.ReadLine()\r
+       Loop While Not OExec.StdOut.atEndOfStream\r
+\r
+Else\r
+       xml.Open "GET", URL, False\r
+       xml.Send\r
+       \r
+       Const adTypeBinary = 1\r
+       Const adSaveCreateOverWrite = 2\r
+       Const adSaveCreateNotExist = 1 \r
+\r
+       oStream.type = adTypeBinary\r
+       oStream.open\r
+       oStream.write xml.responseBody\r
+       oStream.savetofile DestFolder & filename, adSaveCreateOverWrite\r
+       oStream.close\r
+End If\r
+\r
+End Sub\r
+\r
+Sub Slow_Wget(URL, DestFolder)\r
+       StartPos = InstrRev(URL, "/", -1, 1)   \r
+       strlength = Len(URL)\r
+       filename=Right(URL,strlength-StartPos)\r
+       If Right(DestFolder, 1) <> "\" Then DestFolder = DestFolder & "\" End If\r
+\r
+       Wscript.echo("Downloading: " & URL)\r
+       xml.Open "GET", URL, False\r
+       xml.Send\r
+       \r
+       const ForReading = 1 , ForWriting = 2 , ForAppending = 8 \r
+       Set MyFile = fso.OpenTextFile(DestFolder & filename ,ForWriting, True)\r
+       For i = 1 to lenb(xml.responseBody)\r
+        MyFile.write Chr(Ascb(midb(xml.responseBody,i,1)))\r
+       Next\r
+       MyFile.Close()\r
+\r
+End Sub\r
+\r
+Function Showpath(folderspec)\r
+       Set f = FSO.GetFolder(folderspec)\r
+       showpath = f.path & "\"\r
+End Function\r
+\r
+\r