Thứ Sáu, 5 tháng 10, 2007

WGET for Windows (win32) - current version: 1.10.2

WGET for Windows (win32) - current version: 1.10.2

updated February 16 2007




Read below to download wget.exe and
for some help with wget.

GNU wget

From the
official wget homepage
:

"GNU Wget is a free software package for retrieving files using
HTTP, HTTPS and FTP, the most widely-used Internet protocols. It is a
non-interactive commandline tool, so it may easily be called from scripts,
cron jobs, terminals without Xsupport, etc."




While you can get Windows binaries from
Heiko Herold's page,
the binaries here are tweaked a bit so they operate somewhat better on Windows.




The following changes, compared to the official distribution, were
retained/added since 1.8.2:

Statically linked with (masm optimized) OpenSSL 0.9.7i, which makes
wget.exe completely stand-alone.

Compressed with UPX 1.07 for smaller filesize



It seems the rfc1738 problems on Windows (see below) were fixed in wget 1.9,
so there is no longer a need to edit the source code.

OpenSSL



Wget now supports Secure Socket Layer (SSL, https://...) among other things.
Most available binaries are dynamically linked against OpenSSL, and require you
to have a couple of dll's in your path. The binary on this site is statically
linked with OpenSSL (which makes it larger in size, but stand-alone).


Note the license addendum:



"In addition, as a special exception, the Free Software Foundation
gives permission to link the code of its release of Wget with the
OpenSSL project's "OpenSSL" library (or with modified versions of it
that use the same license as the "OpenSSL" library), and distribute
the linked executables. You must obey the GNU General Public License
in all respects for all of the code used other than "OpenSSL". If you
modify this file, you may extend this exception to your version of the
file, but you are not obligated to do so. If you do not wish to do
so, delete this exception statement from your version."


Furthermore, compiling (statically) with OpenSSL is cumbersome in VC++.
If you were to try this yourself, necessary steps would include:


  • Getting the OpenSSL source
    and untarring it somewhere besides wget source.

  • Configuring for win32 - this involves Perl (e.g.
    ActivePerl).
    (ms\do_masm.bat will help)

  • Compiling static libraries (ms\nt.mak, not
    ms\ntdll.mak)...

  • ... however, after making sure you are compiling with the correct
    multithreaded runtime libraries (/MT, not
    /MD) to match wget configuration.

  • configure.bat --msvc in the wget tree.
  • Adding the inc32\... to the wget include path, and both
    libraries in out32 to the wget link step. (edit
    SSLLIBS and DEFS in src\Makefile)

Downloads!



Latest version is 1.10.2, compiled with MS Visual C++ and
linked with OpenSSL 0.9.7i. Page will be updated with new releases of wget.
Wget tends to see a couple of incremental bugfix releases (i.e. 1.10.x).
I am currently using wget 1.10.x on a daily basis.






>>

wget.exe (332800 bytes)
<< :
win32 binary with OpenSSL support.




MD5: dbe287eb8d58e6322e9fb67110ed7122

SHA1: 1cd5550de3a857540cbe79fda1c7186dd7721802






Older versions




wget 1.10 (Jul 2 2005)





wget-1.10.exe (324608 bytes):
win32 binary compiled with MS Visual C++ and with OpenSSL 0.9.7g support.






wget 1.9.1 (Jun 03 2004)





wget-1.9.1.exe (308736 bytes):
win32 binary compiled with MS Visual C++ 6.0 and with OpenSSL 0.9.7c support.





Large file support (FTP)


wget-lfs.exe (712704 bytes):
Alternative version of wget 1.9.1 which supports transfering large files
(+4 GB, for example, a dvd iso) over FTP (not over HTTP).
Incorporates the patch from Leonid Petrov.





wget 1.9 (Oct 23 2003)





wget-1.9.exe (308736 bytes):
win32 binary compiled with MS Visual C++ 6.0 and with OpenSSL 0.9.7c support.






wget 1.8.2 (Feb 25 2003)




compiled with MS Visual C++ 6.0 and linked
with OpenSSL 0.9.6c.






wget-1.8.2.exe (279552 bytes):
win32 binary with OpenSSL support and Windows-friendly filename generation.



wget-1.8.2win32-url.c-fix.zip
(21919 bytes): source changes (url.c)




One of the major problems in 1.8.2 was with the
rfc1738 reserved and
unsafe character standard, which wget tried to adhere to, not just for
decoding URLs, but also for filenames on the local filesystem. Let's just say
this didn't go over too well with Windows users. Examples were conversion of
spaces to %20, which wouldn't be too bad, except for the fact that wget
insists that % is an illegal character on Windows (which it is not), and
converted all %s to @s (basically mangling filenames beyond repair). Another
worse example was the fact that wget is unaware that '?' is an illegal
character in Windows, hence it crashed on URLs with query strings.





Usage




wget is a command line program. You start it from the command prompt, either
command.com in Windows 9x/Me or cmd.exe in Windows 2000/XP. The command prompt
can be found in the Start Menu (Accessories).




wget.exe must be placed in your path (e.g. c:\windows)




To retrieve a file: wget http://users.ugent.be/~bpuype/wget/wget.exe

Picture Preview


wget in action...




Basic options




Display all help: wget --help




Completely mirror a site: wget -mr http://...

-m: mirror

-r: recursive

Mirror without following links to other servers, parent directories:
wget -mrnp http://...

-np: no-parent




Retrieve a html file and convert relative links to absolute ones:
wget -k http://users.ugent.be/~bpuype/wget

-k: 'k'onvert links




Resume partially downloaded files (if supported by the server):
wget -c http://...

-c: continue




Read url's from a file and retrieve them:
wget -i file_with_urls.txt

-i: input-file

Ask for url's (read from stdin):
wget -i -. Enter url's on the command line, press enter after
each url, and terminate with ^Z (press CTRL-Z) on an empty line.



FTP

--glob=off

Don't treat (, *, ? etc. as globbing
characters. Use when transfering files with names that contain these
characters.




--passive-ftp

Use passive mode for data connection (try this if you're behind a firewall,
NAT box...)

Proxy

To make wget use a proxy, you must set up an environment variable before
using wget. Type this at the command prompt:




set http_proxy=http://proxy.myprovider.net:8080




...where you use the correct proxy hostname and port for your ISP or
network. You can use ftp_proxy to proxy ftp requests.





--proxy=on

--proxy=off

Turn proxy usage on/off once variable is set.





Google: 70%
visitors: 551391 (Feb 2003 - Feb 2007)

Mr Duong

Không có nhận xét nào: