1
This is wget.info, produced by makeinfo version 4.3 from ./wget.texi.
3
INFO-DIR-SECTION Network Applications
5
* Wget: (wget). The non-interactive network downloader.
8
This file documents the the GNU Wget utility for downloading network
11
Copyright (C) 1996, 1997, 1998, 2000, 2001, 2002, 2003 Free Software
14
Permission is granted to make and distribute verbatim copies of this
15
manual provided the copyright notice and this permission notice are
16
preserved on all copies.
18
Permission is granted to copy, distribute and/or modify this document
19
under the terms of the GNU Free Documentation License, Version 1.1 or
20
any later version published by the Free Software Foundation; with the
21
Invariant Sections being "GNU General Public License" and "GNU Free
22
Documentation License", with no Front-Cover Texts, and with no
23
Back-Cover Texts. A copy of the license is included in the section
24
entitled "GNU Free Documentation License".
27
File: wget.info, Node: Advanced Usage, Next: Very Advanced Usage, Prev: Simple Usage, Up: Examples
32
* You have a file that contains the URLs you want to download? Use
37
If you specify `-' as file name, the URLs will be read from
40
* Create a five levels deep mirror image of the GNU web site, with
41
the same directory structure the original has, with only one try
42
per document, saving the log of the activities to `gnulog':
44
wget -r http://www.gnu.org/ -o gnulog
46
* The same as the above, but convert the links in the HTML files to
47
point to local files, so you can view the documents off-line:
49
wget --convert-links -r http://www.gnu.org/ -o gnulog
51
* Retrieve only one HTML page, but make sure that all the elements
52
needed for the page to be displayed, such as inline images and
53
external style sheets, are also downloaded. Also make sure the
54
downloaded page references the downloaded links.
56
wget -p --convert-links http://www.server.com/dir/page.html
58
The HTML page will be saved to `www.server.com/dir/page.html', and
59
the images, stylesheets, etc., somewhere under `www.server.com/',
60
depending on where they were on the remote server.
62
* The same as the above, but without the `www.server.com/' directory.
63
In fact, I don't want to have all those random server directories
64
anyway--just save _all_ those files under a `download/'
65
subdirectory of the current directory.
67
wget -p --convert-links -nH -nd -Pdownload \
68
http://www.server.com/dir/page.html
70
* Retrieve the index.html of `www.lycos.com', showing the original
73
wget -S http://www.lycos.com/
75
* Save the server headers with the file, perhaps for post-processing.
77
wget -s http://www.lycos.com/
80
* Retrieve the first two levels of `wuarchive.wustl.edu', saving them
83
wget -r -l2 -P/tmp ftp://wuarchive.wustl.edu/
85
* You want to download all the GIFs from a directory on an HTTP
86
server. You tried `wget http://www.server.com/dir/*.gif', but that
87
didn't work because HTTP retrieval does not support globbing. In
90
wget -r -l1 --no-parent -A.gif http://www.server.com/dir/
92
More verbose, but the effect is the same. `-r -l1' means to
93
retrieve recursively (*note Recursive Retrieval::), with maximum
94
depth of 1. `--no-parent' means that references to the parent
95
directory are ignored (*note Directory-Based Limits::), and
96
`-A.gif' means to download only the GIF files. `-A "*.gif"' would
99
* Suppose you were in the middle of downloading, when Wget was
100
interrupted. Now you do not want to clobber the files already
101
present. It would be:
103
wget -nc -r http://www.gnu.org/
105
* If you want to encode your own username and password to HTTP or
106
FTP, use the appropriate URL syntax (*note URL Format::).
108
wget ftp://hniksic:mypassword@unix.server.com/.emacs
110
Note, however, that this usage is not advisable on multi-user
111
systems because it reveals your password to anyone who looks at
114
* You would like the output documents to go to standard output
117
wget -O - http://jagor.srce.hr/ http://www.srce.hr/
119
You can also combine the two options and make pipelines to
120
retrieve the documents from remote hotlists:
122
wget -O - http://cool.list.com/ | wget --force-html -i -
125
File: wget.info, Node: Very Advanced Usage, Prev: Advanced Usage, Up: Examples
130
* If you wish Wget to keep a mirror of a page (or FTP
131
subdirectories), use `--mirror' (`-m'), which is the shorthand for
132
`-r -l inf -N'. You can put Wget in the crontab file asking it to
133
recheck a site each Sunday:
136
0 0 * * 0 wget --mirror http://www.gnu.org/ -o /home/me/weeklog
138
* In addition to the above, you want the links to be converted for
139
local viewing. But, after having read this manual, you know that
140
link conversion doesn't play well with timestamping, so you also
141
want Wget to back up the original HTML files before the
142
conversion. Wget invocation would look like this:
144
wget --mirror --convert-links --backup-converted \
145
http://www.gnu.org/ -o /home/me/weeklog
147
* But you've also noticed that local viewing doesn't work all that
148
well when HTML files are saved under extensions other than `.html',
149
perhaps because they were served as `index.cgi'. So you'd like
150
Wget to rename all the files served with content-type `text/html'
151
or `application/xhtml+xml' to `NAME.html'.
153
wget --mirror --convert-links --backup-converted \
154
--html-extension -o /home/me/weeklog \
157
Or, with less typing:
159
wget -m -k -K -E http://www.gnu.org/ -o /home/me/weeklog
162
File: wget.info, Node: Various, Next: Appendices, Prev: Examples, Up: Top
167
This chapter contains all the stuff that could not fit anywhere else.
171
* Proxies:: Support for proxy servers
172
* Distribution:: Getting the latest version.
173
* Mailing List:: Wget mailing list for announcements and discussion.
174
* Reporting Bugs:: How and where to report bugs.
175
* Portability:: The systems Wget works on.
176
* Signals:: Signal-handling performed by Wget.
179
File: wget.info, Node: Proxies, Next: Distribution, Prev: Various, Up: Various
184
"Proxies" are special-purpose HTTP servers designed to transfer data
185
from remote servers to local clients. One typical use of proxies is
186
lightening network load for users behind a slow connection. This is
187
achieved by channeling all HTTP and FTP requests through the proxy
188
which caches the transferred data. When a cached resource is requested
189
again, proxy will return the data from cache. Another use for proxies
190
is for companies that separate (for security reasons) their internal
191
networks from the rest of Internet. In order to obtain information
192
from the Web, their users connect and retrieve remote data using an
195
Wget supports proxies for both HTTP and FTP retrievals. The
196
standard way to specify proxy location, which Wget recognizes, is using
197
the following environment variables:
200
This variable should contain the URL of the proxy for HTTP
204
This variable should contain the URL of the proxy for FTP
205
connections. It is quite common that HTTP_PROXY and FTP_PROXY are
209
This variable should contain a comma-separated list of domain
210
extensions proxy should _not_ be used for. For instance, if the
211
value of `no_proxy' is `.mit.edu', proxy will not be used to
212
retrieve documents from MIT.
214
In addition to the environment variables, proxy location and settings
215
may be specified from within Wget itself.
220
This option may be used to turn the proxy support on or off. Proxy
221
support is on by default, provided that the appropriate environment
227
These startup file variables allow you to override the proxy
228
settings specified by the environment.
230
Some proxy servers require authorization to enable you to use them.
231
The authorization consists of "username" and "password", which must be
232
sent by Wget. As with HTTP authorization, several authentication
233
schemes exist. For proxy authorization only the `Basic' authentication
234
scheme is currently implemented.
236
You may specify your username and password either through the proxy
237
URL or through the command-line options. Assuming that the company's
238
proxy is located at `proxy.company.com' at port 8001, a proxy URL
239
location containing authorization data might look like this:
241
http://hniksic:mypassword@proxy.company.com:8001/
243
Alternatively, you may use the `proxy-user' and `proxy-password'
244
options, and the equivalent `.wgetrc' settings `proxy_user' and
245
`proxy_passwd' to set the proxy username and password.
248
File: wget.info, Node: Distribution, Next: Mailing List, Prev: Proxies, Up: Various
253
Like all GNU utilities, the latest version of Wget can be found at
254
the master GNU archive site ftp.gnu.org, and its mirrors. For example,
255
Wget 1.9.1 can be found at
256
<ftp://ftp.gnu.org/pub/gnu/wget/wget-1.9.1.tar.gz>
259
File: wget.info, Node: Mailing List, Next: Reporting Bugs, Prev: Distribution, Up: Various
264
Wget has its own mailing list at <wget@sunsite.dk>, thanks to
265
Karsten Thygesen. The mailing list is for discussion of Wget features
266
and web, reporting Wget bugs (those that you think may be of interest
267
to the public) and mailing announcements. You are welcome to
268
subscribe. The more people on the list, the better!
270
To subscribe, simply send mail to <wget-subscribe@sunsite.dk>.
271
Unsubscribe by mailing to <wget-unsubscribe@sunsite.dk>.
273
The mailing list is archived at <http://fly.srk.fer.hr/archive/wget>.
274
Alternative archive is available at
275
<http://www.mail-archive.com/wget%40sunsite.auc.dk/>.
278
File: wget.info, Node: Reporting Bugs, Next: Portability, Prev: Mailing List, Up: Various
283
You are welcome to send bug reports about GNU Wget to
286
Before actually submitting a bug report, please try to follow a few
289
1. Please try to ascertain that the behavior you see really is a bug.
290
If Wget crashes, it's a bug. If Wget does not behave as
291
documented, it's a bug. If things work strange, but you are not
292
sure about the way they are supposed to work, it might well be a
295
2. Try to repeat the bug in as simple circumstances as possible.
296
E.g. if Wget crashes while downloading `wget -rl0 -kKE -t5 -Y0
297
http://yoyodyne.com -o /tmp/log', you should try to see if the
298
crash is repeatable, and if will occur with a simpler set of
299
options. You might even try to start the download at the page
300
where the crash occurred to see if that page somehow triggered the
303
Also, while I will probably be interested to know the contents of
304
your `.wgetrc' file, just dumping it into the debug message is
305
probably a bad idea. Instead, you should first try to see if the
306
bug repeats with `.wgetrc' moved out of the way. Only if it turns
307
out that `.wgetrc' settings affect the bug, mail me the relevant
310
3. Please start Wget with `-d' option and send the log (or the
311
relevant parts of it). If Wget was compiled without debug support,
312
recompile it. It is _much_ easier to trace bugs with debug support
315
4. If Wget has crashed, try to run it in a debugger, e.g. `gdb `which
316
wget` core' and type `where' to get the backtrace.
319
File: wget.info, Node: Portability, Next: Signals, Prev: Reporting Bugs, Up: Various
324
Since Wget uses GNU Autoconf for building and configuring, and avoids
325
using "special" ultra-mega-cool features of any particular Unix, it
326
should compile (and work) on all common Unix flavors.
328
Various Wget versions have been compiled and tested under many kinds
329
of Unix systems, including Solaris, Linux, SunOS, OSF (aka Digital
330
Unix), Ultrix, *BSD, IRIX, and others; refer to the file `MACHINES' in
331
the distribution directory for a comprehensive list. If you compile it
332
on an architecture not listed there, please let me know so I can update
335
Wget should also compile on the other Unix systems, not listed in
336
`MACHINES'. If it doesn't, please let me know.
338
Thanks to kind contributors, this version of Wget compiles and works
339
on Microsoft Windows 95 and Windows NT platforms. It has been compiled
340
successfully using MS Visual C++ 4.0, Watcom, and Borland C compilers,
341
with Winsock as networking software. Naturally, it is crippled of some
342
features available on Unix, but it should work as a substitute for
343
people stuck with Windows. Note that the Windows port is *neither
344
tested nor maintained* by me--all questions and problems should be
345
reported to Wget mailing list at <wget@sunsite.dk> where the
346
maintainers will look at them.
349
File: wget.info, Node: Signals, Prev: Portability, Up: Various
354
Since the purpose of Wget is background work, it catches the hangup
355
signal (`SIGHUP') and ignores it. If the output was on standard
356
output, it will be redirected to a file named `wget-log'. Otherwise,
357
`SIGHUP' is ignored. This is convenient when you wish to redirect the
358
output of Wget after having started it.
360
$ wget http://www.ifi.uio.no/~larsi/gnus.tar.gz &
361
$ kill -HUP %% # Redirect the output to wget-log
363
Other than that, Wget will not try to interfere with signals in any
364
way. `C-c', `kill -TERM' and `kill -KILL' should kill it alike.
367
File: wget.info, Node: Appendices, Next: Copying, Prev: Various, Up: Top
372
This chapter contains some references I consider useful.
376
* Robot Exclusion:: Wget's support for RES.
377
* Security Considerations:: Security with Wget.
378
* Contributors:: People who helped.
381
File: wget.info, Node: Robot Exclusion, Next: Security Considerations, Prev: Appendices, Up: Appendices
386
It is extremely easy to make Wget wander aimlessly around a web site,
387
sucking all the available data in progress. `wget -r SITE', and you're
388
set. Great? Not for the server admin.
390
As long as Wget is only retrieving static pages, and doing it at a
391
reasonable rate (see the `--wait' option), there's not much of a
392
problem. The trouble is that Wget can't tell the difference between the
393
smallest static page and the most demanding CGI. A site I know has a
394
section handled by a CGI Perl script that converts Info files to HTML on
395
the fly. The script is slow, but works well enough for human users
396
viewing an occasional Info file. However, when someone's recursive Wget
397
download stumbles upon the index page that links to all the Info files
398
through the script, the system is brought to its knees without providing
399
anything useful to the user (This task of converting Info files could be
400
done locally and access to Info documentation for all installed GNU
401
software on a system is available from the `info' command).
403
To avoid this kind of accident, as well as to preserve privacy for
404
documents that need to be protected from well-behaved robots, the
405
concept of "robot exclusion" was invented. The idea is that the server
406
administrators and document authors can specify which portions of the
407
site they wish to protect from robots and those they will permit access.
409
The most popular mechanism, and the de facto standard supported by
410
all the major robots, is the "Robots Exclusion Standard" (RES) written
411
by Martijn Koster et al. in 1994. It specifies the format of a text
412
file containing directives that instruct the robots which URL paths to
413
avoid. To be found by the robots, the specifications must be placed in
414
`/robots.txt' in the server root, which the robots are expected to
417
Although Wget is not a web robot in the strictest sense of the word,
418
it can downloads large parts of the site without the user's
419
intervention to download an individual page. Because of that, Wget
420
honors RES when downloading recursively. For instance, when you issue:
422
wget -r http://www.server.com/
424
First the index of `www.server.com' will be downloaded. If Wget
425
finds that it wants to download more documents from that server, it will
426
request `http://www.server.com/robots.txt' and, if found, use it for
427
further downloads. `robots.txt' is loaded only once per each server.
429
Until version 1.8, Wget supported the first version of the standard,
430
written by Martijn Koster in 1994 and available at
431
<http://www.robotstxt.org/wc/norobots.html>. As of version 1.8, Wget
432
has supported the additional directives specified in the internet draft
433
`<draft-koster-robots-00.txt>' titled "A Method for Web Robots
434
Control". The draft, which has as far as I know never made to an RFC,
435
is available at <http://www.robotstxt.org/wc/norobots-rfc.txt>.
437
This manual no longer includes the text of the Robot Exclusion
440
The second, less known mechanism, enables the author of an individual
441
document to specify whether they want the links from the file to be
442
followed by a robot. This is achieved using the `META' tag, like this:
444
<meta name="robots" content="nofollow">
446
This is explained in some detail at
447
<http://www.robotstxt.org/wc/meta-user.html>. Wget supports this
448
method of robot exclusion in addition to the usual `/robots.txt'
451
If you know what you are doing and really really wish to turn off the
452
robot exclusion, set the `robots' variable to `off' in your `.wgetrc'.
453
You can achieve the same effect from the command line using the `-e'
454
switch, e.g. `wget -e robots=off URL...'.
457
File: wget.info, Node: Security Considerations, Next: Contributors, Prev: Robot Exclusion, Up: Appendices
459
Security Considerations
460
=======================
462
When using Wget, you must be aware that it sends unencrypted
463
passwords through the network, which may present a security problem.
464
Here are the main issues, and some solutions.
466
1. The passwords on the command line are visible using `ps'. The
467
best way around it is to use `wget -i -' and feed the URLs to
468
Wget's standard input, each on a separate line, terminated by
469
`C-d'. Another workaround is to use `.netrc' to store passwords;
470
however, storing unencrypted passwords is also considered a
473
2. Using the insecure "basic" authentication scheme, unencrypted
474
passwords are transmitted through the network routers and gateways.
476
3. The FTP passwords are also in no way encrypted. There is no good
477
solution for this at the moment.
479
4. Although the "normal" output of Wget tries to hide the passwords,
480
debugging logs show them, in all forms. This problem is avoided by
481
being careful when you send debug logs (yes, even when you send
485
File: wget.info, Node: Contributors, Prev: Security Considerations, Up: Appendices
490
GNU Wget was written by Hrvoje Niksic <hniksic@xemacs.org>.
491
However, its development could never have gone as far as it has, were it
492
not for the help of many people, either with bug reports, feature
493
proposals, patches, or letters saying "Thanks!".
495
Special thanks goes to the following people (no particular order):
497
* Karsten Thygesen--donated system resources such as the mailing
498
list, web space, and FTP space, along with a lot of time to make
501
* Shawn McHorse--bug reports and patches.
503
* Kaveh R. Ghazi--on-the-fly `ansi2knr'-ization. Lots of
506
* Gordon Matzigkeit--`.netrc' support.
508
* Zlatko Calusic, Tomislav Vujec and Drazen Kacar--feature
509
suggestions and "philosophical" discussions.
511
* Darko Budor--initial port to Windows.
513
* Antonio Rosella--help and suggestions, plus the Italian
516
* Tomislav Petrovic, Mario Mikocevic--many bug reports and
519
* Francois Pinard--many thorough bug reports and discussions.
521
* Karl Eichwalder--lots of help with internationalization and other
524
* Junio Hamano--donated support for Opie and HTTP `Digest'
527
* The people who provided donations for development, including Brian
530
The following people have provided patches, bug/build reports, useful
531
suggestions, beta testing services, fan mail and all the other things
532
that make maintenance so much fun:
534
Ian Abbott Tim Adam, Adrian Aichner, Martin Baehr, Dieter Baron,
535
Roger Beeman, Dan Berger, T. Bharath, Paul Bludov, Daniel Bodea, Mark
536
Boyns, John Burden, Wanderlei Cavassin, Gilles Cedoc, Tim Charron, Noel
537
Cragg, Kristijan Conkas, John Daily, Ahmon Dancy, Andrew Davison,
538
Andrew Deryabin, Ulrich Drepper, Marc Duponcheel, Damir Dzeko, Alan
539
Eldridge, Aleksandar Erkalovic, Andy Eskilsson, Christian Fraenkel,
540
Masashi Fujita, Howard Gayle, Marcel Gerrits, Lemble Gregory, Hans
541
Grobler, Mathieu Guillaume, Dan Harkless, Aaron Hawley, Herold Heiko,
542
Jochen Hein, Karl Heuer, HIROSE Masaaki, Gregor Hoffleit, Erik Magnus
543
Hulthen, Richard Huveneers, Jonas Jensen, Simon Josefsson, Mario Juric,
544
Hack Kampbjorn, Const Kaplinsky, Goran Kezunovic, Robert Kleine, KOJIMA
545
Haime, Fila Kolodny, Alexander Kourakos, Martin Kraemer, Simos
546
KSenitellis, Hrvoje Lacko, Daniel S. Lewart, Nicolas Lichtmeier, Dave
547
Love, Alexander V. Lukyanov, Thomas Lussnig, Aurelien Marchand, Jordan
548
Mendelson, Lin Zhe Min, Tim Mooney, Simon Munton, Charlie Negyesi, R.
549
K. Owen, Andrew Pollock, Steve Pothier, Jan Prikryl, Marin Purgar,
550
Csaba Raduly, Keith Refson, Bill Richardson, Tyler Riddle, Tobias
551
Ringstrom, Juan Jose Rodrigues, Maciej W. Rozycki, Edward J. Sabol,
552
Heinz Salzmann, Robert Schmidt, Andreas Schwab, Chris Seawood, Toomas
553
Soome, Tage Stabell-Kulo, Sven Sternberger, Markus Strasser, John
554
Summerfield, Szakacsits Szabolcs, Mike Thomas, Philipp Thomas, Mauro
555
Tortonesi, Dave Turner, Gisle Vanem, Russell Vincent, Charles G Waldman,
556
Douglas E. Wegscheid, Jasmin Zainul, Bojan Zdrnja, Kristijan Zimmer.
558
Apologies to all who I accidentally left out, and many thanks to all
559
the subscribers of the Wget mailing list.
562
File: wget.info, Node: Copying, Next: Concept Index, Prev: Appendices, Up: Top
567
GNU Wget is licensed under the GNU GPL, which makes it "free
570
Please note that "free" in "free software" refers to liberty, not
571
price. As some GNU project advocates like to point out, think of "free
572
speech" rather than "free beer". The exact and legally binding
573
distribution terms are spelled out below; in short, you have the right
574
(freedom) to run and change Wget and distribute it to other people, and
575
even--if you want--charge money for doing either. The important
576
restriction is that you have to grant your recipients the same rights
577
and impose the same restrictions.
579
This method of licensing software is also known as "open source"
580
because, among other things, it makes sure that all recipients will
581
receive the source code along with the program, and be able to improve
582
it. The GNU project prefers the term "free software" for reasons
584
<http://www.gnu.org/philosophy/free-software-for-freedom.html>.
586
The exact license terms are defined by this paragraph and the GNU
587
General Public License it refers to:
589
GNU Wget is free software; you can redistribute it and/or modify it
590
under the terms of the GNU General Public License as published by
591
the Free Software Foundation; either version 2 of the License, or
592
(at your option) any later version.
594
GNU Wget is distributed in the hope that it will be useful, but
595
WITHOUT ANY WARRANTY; without even the implied warranty of
596
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
597
General Public License for more details.
599
A copy of the GNU General Public License is included as part of
600
this manual; if you did not receive it, write to the Free Software
601
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
603
In addition to this, this manual is free in the same sense:
605
Permission is granted to copy, distribute and/or modify this
606
document under the terms of the GNU Free Documentation License,
607
Version 1.1 or any later version published by the Free Software
608
Foundation; with the Invariant Sections being "GNU General Public
609
License" and "GNU Free Documentation License", with no Front-Cover
610
Texts, and with no Back-Cover Texts. A copy of the license is
611
included in the section entitled "GNU Free Documentation License".
613
The full texts of the GNU General Public License and of the GNU Free
614
Documentation License are available below.
618
* GNU General Public License::
619
* GNU Free Documentation License::
622
File: wget.info, Node: GNU General Public License, Next: GNU Free Documentation License, Prev: Copying, Up: Copying
624
GNU General Public License
625
==========================
628
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
629
675 Mass Ave, Cambridge, MA 02139, USA
631
Everyone is permitted to copy and distribute verbatim copies
632
of this license document, but changing it is not allowed.
637
The licenses for most software are designed to take away your
638
freedom to share and change it. By contrast, the GNU General Public
639
License is intended to guarantee your freedom to share and change free
640
software--to make sure the software is free for all its users. This
641
General Public License applies to most of the Free Software
642
Foundation's software and to any other program whose authors commit to
643
using it. (Some other Free Software Foundation software is covered by
644
the GNU Library General Public License instead.) You can apply it to
647
When we speak of free software, we are referring to freedom, not
648
price. Our General Public Licenses are designed to make sure that you
649
have the freedom to distribute copies of free software (and charge for
650
this service if you wish), that you receive source code or can get it
651
if you want it, that you can change the software or use pieces of it in
652
new free programs; and that you know you can do these things.
654
To protect your rights, we need to make restrictions that forbid
655
anyone to deny you these rights or to ask you to surrender the rights.
656
These restrictions translate to certain responsibilities for you if you
657
distribute copies of the software, or if you modify it.
659
For example, if you distribute copies of such a program, whether
660
gratis or for a fee, you must give the recipients all the rights that
661
you have. You must make sure that they, too, receive or can get the
662
source code. And you must show them these terms so they know their
665
We protect your rights with two steps: (1) copyright the software,
666
and (2) offer you this license which gives you legal permission to copy,
667
distribute and/or modify the software.
669
Also, for each author's protection and ours, we want to make certain
670
that everyone understands that there is no warranty for this free
671
software. If the software is modified by someone else and passed on, we
672
want its recipients to know that what they have is not the original, so
673
that any problems introduced by others will not reflect on the original
674
authors' reputations.
676
Finally, any free program is threatened constantly by software
677
patents. We wish to avoid the danger that redistributors of a free
678
program will individually obtain patent licenses, in effect making the
679
program proprietary. To prevent this, we have made it clear that any
680
patent must be licensed for everyone's free use or not licensed at all.
682
The precise terms and conditions for copying, distribution and
685
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
686
1. This License applies to any program or other work which contains a
687
notice placed by the copyright holder saying it may be distributed
688
under the terms of this General Public License. The "Program",
689
below, refers to any such program or work, and a "work based on
690
the Program" means either the Program or any derivative work under
691
copyright law: that is to say, a work containing the Program or a
692
portion of it, either verbatim or with modifications and/or
693
translated into another language. (Hereinafter, translation is
694
included without limitation in the term "modification".) Each
695
licensee is addressed as "you".
697
Activities other than copying, distribution and modification are
698
not covered by this License; they are outside its scope. The act
699
of running the Program is not restricted, and the output from the
700
Program is covered only if its contents constitute a work based on
701
the Program (independent of having been made by running the
702
Program). Whether that is true depends on what the Program does.
704
2. You may copy and distribute verbatim copies of the Program's
705
source code as you receive it, in any medium, provided that you
706
conspicuously and appropriately publish on each copy an appropriate
707
copyright notice and disclaimer of warranty; keep intact all the
708
notices that refer to this License and to the absence of any
709
warranty; and give any other recipients of the Program a copy of
710
this License along with the Program.
712
You may charge a fee for the physical act of transferring a copy,
713
and you may at your option offer warranty protection in exchange
716
3. You may modify your copy or copies of the Program or any portion
717
of it, thus forming a work based on the Program, and copy and
718
distribute such modifications or work under the terms of Section 1
719
above, provided that you also meet all of these conditions:
721
a. You must cause the modified files to carry prominent notices
722
stating that you changed the files and the date of any change.
724
b. You must cause any work that you distribute or publish, that
725
in whole or in part contains or is derived from the Program
726
or any part thereof, to be licensed as a whole at no charge
727
to all third parties under the terms of this License.
729
c. If the modified program normally reads commands interactively
730
when run, you must cause it, when started running for such
731
interactive use in the most ordinary way, to print or display
732
an announcement including an appropriate copyright notice and
733
a notice that there is no warranty (or else, saying that you
734
provide a warranty) and that users may redistribute the
735
program under these conditions, and telling the user how to
736
view a copy of this License. (Exception: if the Program
737
itself is interactive but does not normally print such an
738
announcement, your work based on the Program is not required
739
to print an announcement.)
741
These requirements apply to the modified work as a whole. If
742
identifiable sections of that work are not derived from the
743
Program, and can be reasonably considered independent and separate
744
works in themselves, then this License, and its terms, do not
745
apply to those sections when you distribute them as separate
746
works. But when you distribute the same sections as part of a
747
whole which is a work based on the Program, the distribution of
748
the whole must be on the terms of this License, whose permissions
749
for other licensees extend to the entire whole, and thus to each
750
and every part regardless of who wrote it.
752
Thus, it is not the intent of this section to claim rights or
753
contest your rights to work written entirely by you; rather, the
754
intent is to exercise the right to control the distribution of
755
derivative or collective works based on the Program.
757
In addition, mere aggregation of another work not based on the
758
Program with the Program (or with a work based on the Program) on
759
a volume of a storage or distribution medium does not bring the
760
other work under the scope of this License.
762
4. You may copy and distribute the Program (or a work based on it,
763
under Section 2) in object code or executable form under the terms
764
of Sections 1 and 2 above provided that you also do one of the
767
a. Accompany it with the complete corresponding machine-readable
768
source code, which must be distributed under the terms of
769
Sections 1 and 2 above on a medium customarily used for
770
software interchange; or,
772
b. Accompany it with a written offer, valid for at least three
773
years, to give any third party, for a charge no more than your
774
cost of physically performing source distribution, a complete
775
machine-readable copy of the corresponding source code, to be
776
distributed under the terms of Sections 1 and 2 above on a
777
medium customarily used for software interchange; or,
779
c. Accompany it with the information you received as to the offer
780
to distribute corresponding source code. (This alternative is
781
allowed only for noncommercial distribution and only if you
782
received the program in object code or executable form with
783
such an offer, in accord with Subsection b above.)
785
The source code for a work means the preferred form of the work for
786
making modifications to it. For an executable work, complete
787
source code means all the source code for all modules it contains,
788
plus any associated interface definition files, plus the scripts
789
used to control compilation and installation of the executable.
790
However, as a special exception, the source code distributed need
791
not include anything that is normally distributed (in either
792
source or binary form) with the major components (compiler,
793
kernel, and so on) of the operating system on which the executable
794
runs, unless that component itself accompanies the executable.
796
If distribution of executable or object code is made by offering
797
access to copy from a designated place, then offering equivalent
798
access to copy the source code from the same place counts as
799
distribution of the source code, even though third parties are not
800
compelled to copy the source along with the object code.
802
5. You may not copy, modify, sublicense, or distribute the Program
803
except as expressly provided under this License. Any attempt
804
otherwise to copy, modify, sublicense or distribute the Program is
805
void, and will automatically terminate your rights under this
806
License. However, parties who have received copies, or rights,
807
from you under this License will not have their licenses
808
terminated so long as such parties remain in full compliance.
810
6. You are not required to accept this License, since you have not
811
signed it. However, nothing else grants you permission to modify
812
or distribute the Program or its derivative works. These actions
813
are prohibited by law if you do not accept this License.
814
Therefore, by modifying or distributing the Program (or any work
815
based on the Program), you indicate your acceptance of this
816
License to do so, and all its terms and conditions for copying,
817
distributing or modifying the Program or works based on it.
819
7. Each time you redistribute the Program (or any work based on the
820
Program), the recipient automatically receives a license from the
821
original licensor to copy, distribute or modify the Program
822
subject to these terms and conditions. You may not impose any
823
further restrictions on the recipients' exercise of the rights
824
granted herein. You are not responsible for enforcing compliance
825
by third parties to this License.
827
8. If, as a consequence of a court judgment or allegation of patent
828
infringement or for any other reason (not limited to patent
829
issues), conditions are imposed on you (whether by court order,
830
agreement or otherwise) that contradict the conditions of this
831
License, they do not excuse you from the conditions of this
832
License. If you cannot distribute so as to satisfy simultaneously
833
your obligations under this License and any other pertinent
834
obligations, then as a consequence you may not distribute the
835
Program at all. For example, if a patent license would not permit
836
royalty-free redistribution of the Program by all those who
837
receive copies directly or indirectly through you, then the only
838
way you could satisfy both it and this License would be to refrain
839
entirely from distribution of the Program.
841
If any portion of this section is held invalid or unenforceable
842
under any particular circumstance, the balance of the section is
843
intended to apply and the section as a whole is intended to apply
844
in other circumstances.
846
It is not the purpose of this section to induce you to infringe any
847
patents or other property right claims or to contest validity of
848
any such claims; this section has the sole purpose of protecting
849
the integrity of the free software distribution system, which is
850
implemented by public license practices. Many people have made
851
generous contributions to the wide range of software distributed
852
through that system in reliance on consistent application of that
853
system; it is up to the author/donor to decide if he or she is
854
willing to distribute software through any other system and a
855
licensee cannot impose that choice.
857
This section is intended to make thoroughly clear what is believed
858
to be a consequence of the rest of this License.
860
9. If the distribution and/or use of the Program is restricted in
861
certain countries either by patents or by copyrighted interfaces,
862
the original copyright holder who places the Program under this
863
License may add an explicit geographical distribution limitation
864
excluding those countries, so that distribution is permitted only
865
in or among countries not thus excluded. In such case, this
866
License incorporates the limitation as if written in the body of
869
10. The Free Software Foundation may publish revised and/or new
870
versions of the General Public License from time to time. Such
871
new versions will be similar in spirit to the present version, but
872
may differ in detail to address new problems or concerns.
874
Each version is given a distinguishing version number. If the
875
Program specifies a version number of this License which applies
876
to it and "any later version", you have the option of following
877
the terms and conditions either of that version or of any later
878
version published by the Free Software Foundation. If the Program
879
does not specify a version number of this License, you may choose
880
any version ever published by the Free Software Foundation.
882
11. If you wish to incorporate parts of the Program into other free
883
programs whose distribution conditions are different, write to the
884
author to ask for permission. For software which is copyrighted
885
by the Free Software Foundation, write to the Free Software
886
Foundation; we sometimes make exceptions for this. Our decision
887
will be guided by the two goals of preserving the free status of
888
all derivatives of our free software and of promoting the sharing
889
and reuse of software generally.
893
12. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO
894
WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE
895
LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
896
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT
897
WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT
898
NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
899
FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE
900
QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
901
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY
902
SERVICING, REPAIR OR CORRECTION.
904
13. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
905
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY
906
MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE
907
LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL,
908
INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR
909
INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
910
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU
911
OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY
912
OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN
913
ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
915
END OF TERMS AND CONDITIONS
917
How to Apply These Terms to Your New Programs
918
=============================================
920
If you develop a new program, and you want it to be of the greatest
921
possible use to the public, the best way to achieve this is to make it
922
free software which everyone can redistribute and change under these
925
To do so, attach the following notices to the program. It is safest
926
to attach them to the start of each source file to most effectively
927
convey the exclusion of warranty; and each file should have at least
928
the "copyright" line and a pointer to where the full notice is found.
930
ONE LINE TO GIVE THE PROGRAM'S NAME AND AN IDEA OF WHAT IT DOES.
931
Copyright (C) 19YY NAME OF AUTHOR
933
This program is free software; you can redistribute it and/or
934
modify it under the terms of the GNU General Public License
935
as published by the Free Software Foundation; either version 2
936
of the License, or (at your option) any later version.
938
This program is distributed in the hope that it will be useful,
939
but WITHOUT ANY WARRANTY; without even the implied warranty of
940
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
941
GNU General Public License for more details.
943
You should have received a copy of the GNU General Public License
944
along with this program; if not, write to the Free Software
945
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
947
Also add information on how to contact you by electronic and paper
950
If the program is interactive, make it output a short notice like
951
this when it starts in an interactive mode:
953
Gnomovision version 69, Copyright (C) 19YY NAME OF AUTHOR
954
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details
955
type `show w'. This is free software, and you are welcome
956
to redistribute it under certain conditions; type `show c'
959
The hypothetical commands `show w' and `show c' should show the
960
appropriate parts of the General Public License. Of course, the
961
commands you use may be called something other than `show w' and `show
962
c'; they could even be mouse-clicks or menu items--whatever suits your
965
You should also get your employer (if you work as a programmer) or
966
your school, if any, to sign a "copyright disclaimer" for the program,
967
if necessary. Here is a sample; alter the names:
969
Yoyodyne, Inc., hereby disclaims all copyright
970
interest in the program `Gnomovision'
971
(which makes passes at compilers) written
974
SIGNATURE OF TY COON, 1 April 1989
975
Ty Coon, President of Vice
977
This General Public License does not permit incorporating your
978
program into proprietary programs. If your program is a subroutine
979
library, you may consider it more useful to permit linking proprietary
980
applications with the library. If this is what you want to do, use the
981
GNU Library General Public License instead of this License.