1 CUPS License Agreement 2 3 Copyright 2007-2016 by Apple Inc. 4 1 Infinite Loop 5 Cupertino, CA 95014 USA 6 7 WWW: http://www.cups.org/ 8 9 10 INTRODUCTION 11 12 CUPS(tm) is provided under the GNU General Public License ("GPL") 13 and GNU Library General Public License ("LGPL"), Version 2, with an 14 exception for Apple operating systems. A copy of the exception and 15 licenses follow this introduction. 16 17 The GNU LGPL applies to the CUPS and CUPS Imaging libraries 18 located in the "cups" and "filter" subdirectories of the CUPS 19 source distribution and the files in the "test" subdirectory. The 20 GNU GPL applies to the remainder of the CUPS distribution. 21 22 For those not familiar with the GNU GPL, the license basically 23 allows you to: 24 25 - Use the CUPS software at no charge. 26 - Distribute verbatim copies of the software in source or 27 binary form. 28 - Sell verbatim copies of the software for a media fee, or 29 sell support for the software. 30 31 What this license *does not* allow you to do is make changes or 32 add features to CUPS and then sell a binary distribution without 33 source code. You must provide source for any changes or additions 34 to the software, and all code must be provided under the GPL or 35 LGPL as appropriate. The only exceptions to this are the portions 36 of the CUPS software covered by the Apple operating system 37 license exceptions outlined later in this license agreement. 38 39 The GNU LGPL relaxes the "link-to" restriction, allowing you to 40 develop applications that use the CUPS and CUPS Imaging libraries 41 under other licenses and/or conditions as appropriate for your 42 application, driver, or filter. 43 44 45 LICENSE EXCEPTIONS 46 47 In addition, as the copyright holder of CUPS, Apple Inc. grants 48 the following special exception: 49 50 1. Apple Operating System Development License Exception; 51 52 a. Software that is developed by any person or entity 53 for an Apple Operating System ("Apple OS-Developed 54 Software"), including but not limited to Apple and 55 third party printer drivers, filters, and backends 56 for an Apple Operating System, that is linked to the 57 CUPS imaging library or based on any sample filters 58 or backends provided with CUPS shall not be 59 considered to be a derivative work or collective work 60 based on the CUPS program and is exempt from the 61 mandatory source code release clauses of the GNU GPL. 62 You may therefore distribute linked combinations of 63 the CUPS imaging library with Apple OS-Developed 64 Software without releasing the source code of the 65 Apple OS-Developed Software. You may also use sample 66 filters and backends provided with CUPS to develop 67 Apple OS-Developed Software without releasing the 68 source code of the Apple OS-Developed Software. 69 70 b. An Apple Operating System means any operating system 71 software developed and/or marketed by Apple Inc., 72 including but not limited to all existing releases and 73 versions of Apple's Darwin, iOS, macOS, macOS Server, and 74 tvOS products and all follow-on releases and future 75 versions thereof. 76 77 c. This exception is only available for Apple 78 OS-Developed Software and does not apply to software 79 that is distributed for use on other operating 80 systems. 81 82 d. All CUPS software that falls under this license 83 exception have the following text at the top of each 84 source file: 85 86 This file is subject to the Apple OS-Developed 87 Software exception. 88 89 No developer is required to provide this exception in a derived 90 work. 91 92 93 KERBEROS SUPPORT CODE 94 95 The Kerberos support code ("KSC") is copyright 2006 by Jelmer 96 Vernooij and is provided 'as-is', without any express or implied 97 warranty. In no event will the author or Apple Inc. be held 98 liable for any damages arising from the use of the KSC. 99 100 Sources files containing KSC have the following text at the top 101 of each source file: 102 103 This file contains Kerberos support code, copyright 2006 by 104 Jelmer Vernooij. 105 106 The KSC copyright and license apply only to Kerberos-related 107 feature code in CUPS. Such code is typically conditionally 108 compiled based on the present of the HAVE_GSSAPI preprocessor 109 definition. 110 111 Permission is granted to anyone to use the KSC for any purpose, 112 including commercial applications, and to alter it and 113 redistribute it freely, subject to the following restrictions: 114 115 1. The origin of the KSC must not be misrepresented; you 116 must not claim that you wrote the original software. If 117 you use the KSC in a product, an acknowledgment in the 118 product documentation would be appreciated but is not 119 required. 120 121 2. Altered source versions must be plainly marked as such, 122 and must not be misrepresented as being the original 123 software. 124 125 3. This notice may not be removed or altered from any source 126 distribution. 127 128 129 TRADEMARKS 130 131 CUPS and the CUPS logo (the "CUPS Marks") are trademarks of Apple 132 Inc. Apple grants you a non-exclusive and non-transferable right 133 to use the CUPS Marks in any direct port or binary distribution 134 incorporating CUPS software and in any promotional material 135 therefor. You agree that your products will meet the highest 136 levels of quality and integrity for similar goods, not be unlawful, 137 and be developed, manufactured, and distributed in compliance with 138 this license. You will not interfere with Apple's rights in the 139 CUPS Marks, and all use of the CUPS Marks shall inure to the 140 benefit of Apple. This license does not apply to use of the CUPS 141 Marks in a derivative products, which requires prior written 142 permission from Apple Inc. 143 144 GNU GENERAL PUBLIC LICENSE 145 Version 2, June 1991 146 147 Copyright (C) 1989, 1991 Free Software Foundation, Inc. 148 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 149 Everyone is permitted to copy and distribute verbatim copies 150 of this license document, but changing it is not allowed. 151 152 Preamble 153 154 The licenses for most software are designed to take away your 155 freedom to share and change it. By contrast, the GNU General Public 156 License is intended to guarantee your freedom to share and change free 157 software--to make sure the software is free for all its users. This 158 General Public License applies to most of the Free Software 159 Foundation's software and to any other program whose authors commit to 160 using it. (Some other Free Software Foundation software is covered by 161 the GNU Library General Public License instead.) You can apply it to 162 your programs, too. 163 164 When we speak of free software, we are referring to freedom, not 165 price. Our General Public Licenses are designed to make sure that you 166 have the freedom to distribute copies of free software (and charge for 167 this service if you wish), that you receive source code or can get it 168 if you want it, that you can change the software or use pieces of it 169 in new free programs; and that you know you can do these things. 170 171 To protect your rights, we need to make restrictions that forbid 172 anyone to deny you these rights or to ask you to surrender the rights. 173 These restrictions translate to certain responsibilities for you if you 174 distribute copies of the software, or if you modify it. 175 176 For example, if you distribute copies of such a program, whether 177 gratis or for a fee, you must give the recipients all the rights that 178 you have. You must make sure that they, too, receive or can get the 179 source code. And you must show them these terms so they know their 180 rights. 181 182 We protect your rights with two steps: (1) copyright the software, and 183 (2) offer you this license which gives you legal permission to copy, 184 distribute and/or modify the software. 185 186 Also, for each author's protection and ours, we want to make certain 187 that everyone understands that there is no warranty for this free 188 software. If the software is modified by someone else and passed on, we 189 want its recipients to know that what they have is not the original, so 190 that any problems introduced by others will not reflect on the original 191 authors' reputations. 192 193 Finally, any free program is threatened constantly by software 194 patents. We wish to avoid the danger that redistributors of a free 195 program will individually obtain patent licenses, in effect making the 196 program proprietary. To prevent this, we have made it clear that any 197 patent must be licensed for everyone's free use or not licensed at all. 198 199 The precise terms and conditions for copying, distribution and 200 modification follow. 201 202 GNU GENERAL PUBLIC LICENSE 203 TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 204 205 0. This License applies to any program or other work which contains 206 a notice placed by the copyright holder saying it may be distributed 207 under the terms of this General Public License. The "Program", below, 208 refers to any such program or work, and a "work based on the Program" 209 means either the Program or any derivative work under copyright law: 210 that is to say, a work containing the Program or a portion of it, 211 either verbatim or with modifications and/or translated into another 212 language. (Hereinafter, translation is included without limitation in 213 the term "modification".) Each licensee is addressed as "you". 214 215 Activities other than copying, distribution and modification are not 216 covered by this License; they are outside its scope. The act of 217 running the Program is not restricted, and the output from the Program 218 is covered only if its contents constitute a work based on the 219 Program (independent of having been made by running the Program). 220 Whether that is true depends on what the Program does. 221 222 1. You may copy and distribute verbatim copies of the Program's 223 source code as you receive it, in any medium, provided that you 224 conspicuously and appropriately publish on each copy an appropriate 225 copyright notice and disclaimer of warranty; keep intact all the 226 notices that refer to this License and to the absence of any warranty; 227 and give any other recipients of the Program a copy of this License 228 along with the Program. 229 230 You may charge a fee for the physical act of transferring a copy, and 231 you may at your option offer warranty protection in exchange for a fee. 232 233 2. You may modify your copy or copies of the Program or any portion 234 of it, thus forming a work based on the Program, and copy and 235 distribute such modifications or work under the terms of Section 1 236 above, provided that you also meet all of these conditions: 237 238 a) You must cause the modified files to carry prominent notices 239 stating that you changed the files and the date of any change. 240 241 b) You must cause any work that you distribute or publish, that in 242 whole or in part contains or is derived from the Program or any 243 part thereof, to be licensed as a whole at no charge to all third 244 parties under the terms of this License. 245 246 c) If the modified program normally reads commands interactively 247 when run, you must cause it, when started running for such 248 interactive use in the most ordinary way, to print or display an 249 announcement including an appropriate copyright notice and a 250 notice that there is no warranty (or else, saying that you provide 251 a warranty) and that users may redistribute the program under 252 these conditions, and telling the user how to view a copy of this 253 License. (Exception: if the Program itself is interactive but 254 does not normally print such an announcement, your work based on 255 the Program is not required to print an announcement.) 256 257 These requirements apply to the modified work as a whole. If 258 identifiable sections of that work are not derived from the Program, 259 and can be reasonably considered independent and separate works in 260 themselves, then this License, and its terms, do not apply to those 261 sections when you distribute them as separate works. But when you 262 distribute the same sections as part of a whole which is a work based 263 on the Program, the distribution of the whole must be on the terms of 264 this License, whose permissions for other licensees extend to the 265 entire whole, and thus to each and every part regardless of who wrote it. 266 267 Thus, it is not the intent of this section to claim rights or contest 268 your rights to work written entirely by you; rather, the intent is to 269 exercise the right to control the distribution of derivative or 270 collective works based on the Program. 271 272 In addition, mere aggregation of another work not based on the Program 273 with the Program (or with a work based on the Program) on a volume of 274 a storage or distribution medium does not bring the other work under 275 the scope of this License. 276 277 3. You may copy and distribute the Program (or a work based on it, 278 under Section 2) in object code or executable form under the terms of 279 Sections 1 and 2 above provided that you also do one of the following: 280 281 a) Accompany it with the complete corresponding machine-readable 282 source code, which must be distributed under the terms of Sections 283 1 and 2 above on a medium customarily used for software interchange; or, 284 285 b) Accompany it with a written offer, valid for at least three 286 years, to give any third party, for a charge no more than your 287 cost of physically performing source distribution, a complete 288 machine-readable copy of the corresponding source code, to be 289 distributed under the terms of Sections 1 and 2 above on a medium 290 customarily used for software interchange; or, 291 292 c) Accompany it with the information you received as to the offer 293 to distribute corresponding source code. (This alternative is 294 allowed only for noncommercial distribution and only if you 295 received the program in object code or executable form with such 296 an offer, in accord with Subsection b above.) 297 298 The source code for a work means the preferred form of the work for 299 making modifications to it. For an executable work, complete source 300 code means all the source code for all modules it contains, plus any 301 associated interface definition files, plus the scripts used to 302 control compilation and installation of the executable. However, as a 303 special exception, the source code distributed need not include 304 anything that is normally distributed (in either source or binary 305 form) with the major components (compiler, kernel, and so on) of the 306 operating system on which the executable runs, unless that component 307 itself accompanies the executable. 308 309 If distribution of executable or object code is made by offering 310 access to copy from a designated place, then offering equivalent 311 access to copy the source code from the same place counts as 312 distribution of the source code, even though third parties are not 313 compelled to copy the source along with the object code. 314 315 4. You may not copy, modify, sublicense, or distribute the Program 316 except as expressly provided under this License. Any attempt 317 otherwise to copy, modify, sublicense or distribute the Program is 318 void, and will automatically terminate your rights under this License. 319 However, parties who have received copies, or rights, from you under 320 this License will not have their licenses terminated so long as such 321 parties remain in full compliance. 322 323 5. You are not required to accept this License, since you have not 324 signed it. However, nothing else grants you permission to modify or 325 distribute the Program or its derivative works. These actions are 326 prohibited by law if you do not accept this License. Therefore, by 327 modifying or distributing the Program (or any work based on the 328 Program), you indicate your acceptance of this License to do so, and 329 all its terms and conditions for copying, distributing or modifying 330 the Program or works based on it. 331 332 6. Each time you redistribute the Program (or any work based on the 333 Program), the recipient automatically receives a license from the 334 original licensor to copy, distribute or modify the Program subject to 335 these terms and conditions. You may not impose any further 336 restrictions on the recipients' exercise of the rights granted herein. 337 You are not responsible for enforcing compliance by third parties to 338 this License. 339 340 7. If, as a consequence of a court judgment or allegation of patent 341 infringement or for any other reason (not limited to patent issues), 342 conditions are imposed on you (whether by court order, agreement or 343 otherwise) that contradict the conditions of this License, they do not 344 excuse you from the conditions of this License. If you cannot 345 distribute so as to satisfy simultaneously your obligations under this 346 License and any other pertinent obligations, then as a consequence you 347 may not distribute the Program at all. For example, if a patent 348 license would not permit royalty-free redistribution of the Program by 349 all those who receive copies directly or indirectly through you, then 350 the only way you could satisfy both it and this License would be to 351 refrain entirely from distribution of the Program. 352 353 If any portion of this section is held invalid or unenforceable under 354 any particular circumstance, the balance of the section is intended to 355 apply and the section as a whole is intended to apply in other 356 circumstances. 357 358 It is not the purpose of this section to induce you to infringe any 359 patents or other property right claims or to contest validity of any 360 such claims; this section has the sole purpose of protecting the 361 integrity of the free software distribution system, which is 362 implemented by public license practices. Many people have made 363 generous contributions to the wide range of software distributed 364 through that system in reliance on consistent application of that 365 system; it is up to the author/donor to decide if he or she is willing 366 to distribute software through any other system and a licensee cannot 367 impose that choice. 368 369 This section is intended to make thoroughly clear what is believed to 370 be a consequence of the rest of this License. 371 372 8. If the distribution and/or use of the Program is restricted in 373 certain countries either by patents or by copyrighted interfaces, the 374 original copyright holder who places the Program under this License 375 may add an explicit geographical distribution limitation excluding 376 those countries, so that distribution is permitted only in or among 377 countries not thus excluded. In such case, this License incorporates 378 the limitation as if written in the body of this License. 379 380 9. The Free Software Foundation may publish revised and/or new versions 381 of the General Public License from time to time. Such new versions will 382 be similar in spirit to the present version, but may differ in detail to 383 address new problems or concerns. 384 385 Each version is given a distinguishing version number. If the Program 386 specifies a version number of this License which applies to it and "any 387 later version", you have the option of following the terms and conditions 388 either of that version or of any later version published by the Free 389 Software Foundation. If the Program does not specify a version number of 390 this License, you may choose any version ever published by the Free Software 391 Foundation. 392 393 10. If you wish to incorporate parts of the Program into other free 394 programs whose distribution conditions are different, write to the author 395 to ask for permission. For software which is copyrighted by the Free 396 Software Foundation, write to the Free Software Foundation; we sometimes 397 make exceptions for this. Our decision will be guided by the two goals 398 of preserving the free status of all derivatives of our free software and 399 of promoting the sharing and reuse of software generally. 400 401 NO WARRANTY 402 403 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 404 FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 405 OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 406 PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 407 OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 408 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 409 TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 410 PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 411 REPAIR OR CORRECTION. 412 413 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 414 WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 415 REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 416 INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 417 OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 418 TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 419 YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 420 PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 421 POSSIBILITY OF SUCH DAMAGES. 422 423 END OF TERMS AND CONDITIONS 424 425 Appendix: How to Apply These Terms to Your New Programs 426 427 If you develop a new program, and you want it to be of the greatest 428 possible use to the public, the best way to achieve this is to make it 429 free software which everyone can redistribute and change under these terms. 430 431 To do so, attach the following notices to the program. It is safest 432 to attach them to the start of each source file to most effectively 433 convey the exclusion of warranty; and each file should have at least 434 the "copyright" line and a pointer to where the full notice is found. 435 436 <one line to give the program's name and a brief idea of what it does.> 437 Copyright (C) 19yy <name of author> 438 439 This program is free software; you can redistribute it and/or modify 440 it under the terms of the GNU General Public License as published by 441 the Free Software Foundation; either version 2 of the License, or 442 (at your option) any later version. 443 444 This program is distributed in the hope that it will be useful, 445 but WITHOUT ANY WARRANTY; without even the implied warranty of 446 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 447 GNU General Public License for more details. 448 449 You should have received a copy of the GNU General Public License 450 along with this program; if not, write to the Free Software 451 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 452 453 Also add information on how to contact you by electronic and paper mail. 454 455 If the program is interactive, make it output a short notice like this 456 when it starts in an interactive mode: 457 458 Gnomovision version 69, Copyright (C) 19yy name of author 459 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 460 This is free software, and you are welcome to redistribute it 461 under certain conditions; type `show c' for details. 462 463 The hypothetical commands `show w' and `show c' should show the appropriate 464 parts of the General Public License. Of course, the commands you use may 465 be called something other than `show w' and `show c'; they could even be 466 mouse-clicks or menu items--whatever suits your program. 467 468 You should also get your employer (if you work as a programmer) or your 469 school, if any, to sign a "copyright disclaimer" for the program, if 470 necessary. Here is a sample; alter the names: 471 472 Yoyodyne, Inc., hereby disclaims all copyright interest in the program 473 `Gnomovision' (which makes passes at compilers) written by James Hacker. 474 475 <signature of Ty Coon>, 1 April 1989 476 Ty Coon, President of Vice 477 478 This General Public License does not permit incorporating your program into 479 proprietary programs. If your program is a subroutine library, you may 480 consider it more useful to permit linking proprietary applications with the 481 library. If this is what you want to do, use the GNU Library General 482 Public License instead of this License. 483 484 GNU LIBRARY GENERAL PUBLIC LICENSE 485 Version 2, June 1991 486 487 Copyright (C) 1991 Free Software Foundation, Inc. 488 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 489 490 Everyone is permitted to copy and distribute verbatim copies 491 of this license document, but changing it is not allowed. 492 493 [This is the first released version of the library GPL. It is 494 numbered 2 because it goes with version 2 of the ordinary GPL.] 495 496 Preamble 497 498 The licenses for most software are designed to take away your 499 freedom to share and change it. By contrast, the GNU General Public 500 Licenses are intended to guarantee your freedom to share and change 501 free software--to make sure the software is free for all its users. 502 503 This license, the Library General Public License, applies to some 504 specially designated Free Software Foundation software, and to any 505 other libraries whose authors decide to use it. You can use it for 506 your libraries, too. 507 508 When we speak of free software, we are referring to freedom, not 509 price. Our General Public Licenses are designed to make sure that you 510 have the freedom to distribute copies of free software (and charge for 511 this service if you wish), that you receive source code or can get it 512 if you want it, that you can change the software or use pieces of it 513 in new free programs; and that you know you can do these things. 514 515 To protect your rights, we need to make restrictions that forbid 516 anyone to deny you these rights or to ask you to surrender the rights. 517 These restrictions translate to certain responsibilities for you if 518 you distribute copies of the library, or if you modify it. 519 520 For example, if you distribute copies of the library, whether gratis 521 or for a fee, you must give the recipients all the rights that we gave 522 you. You must make sure that they, too, receive or can get the source 523 code. If you link a program with the library, you must provide 524 complete object files to the recipients so that they can relink them 525 with the library, after making changes to the library and recompiling 526 it. And you must show them these terms so they know their rights. 527 528 Our method of protecting your rights has two steps: (1) copyright 529 the library, and (2) offer you this license which gives you legal 530 permission to copy, distribute and/or modify the library. 531 532 Also, for each distributor's protection, we want to make certain 533 that everyone understands that there is no warranty for this free 534 library. If the library is modified by someone else and passed on, we 535 want its recipients to know that what they have is not the original 536 version, so that any problems introduced by others will not reflect on 537 the original authors' reputations. 538 539 Finally, any free program is threatened constantly by software 540 patents. We wish to avoid the danger that companies distributing free 541 software will individually obtain patent licenses, thus in effect 542 transforming the program into proprietary software. To prevent this, 543 we have made it clear that any patent must be licensed for everyone's 544 free use or not licensed at all. 545 546 Most GNU software, including some libraries, is covered by the ordinary 547 GNU General Public License, which was designed for utility programs. This 548 license, the GNU Library General Public License, applies to certain 549 designated libraries. This license is quite different from the ordinary 550 one; be sure to read it in full, and don't assume that anything in it is 551 the same as in the ordinary license. 552 553 The reason we have a separate public license for some libraries is that 554 they blur the distinction we usually make between modifying or adding to a 555 program and simply using it. Linking a program with a library, without 556 changing the library, is in some sense simply using the library, and is 557 analogous to running a utility program or application program. However, in 558 a textual and legal sense, the linked executable is a combined work, a 559 derivative of the original library, and the ordinary General Public License 560 treats it as such. 561 562 Because of this blurred distinction, using the ordinary General 563 Public License for libraries did not effectively promote software 564 sharing, because most developers did not use the libraries. We 565 concluded that weaker conditions might promote sharing better. 566 567 However, unrestricted linking of non-free programs would deprive the 568 users of those programs of all benefit from the free status of the 569 libraries themselves. This Library General Public License is intended to 570 permit developers of non-free programs to use free libraries, while 571 preserving your freedom as a user of such programs to change the free 572 libraries that are incorporated in them. (We have not seen how to achieve 573 this as regards changes in header files, but we have achieved it as regards 574 changes in the actual functions of the Library.) The hope is that this 575 will lead to faster development of free libraries. 576 577 The precise terms and conditions for copying, distribution and 578 modification follow. Pay close attention to the difference between a 579 "work based on the library" and a "work that uses the library". The 580 former contains code derived from the library, while the latter only 581 works together with the library. 582 583 Note that it is possible for a library to be covered by the ordinary 584 General Public License rather than by this special one. 585 586 GNU LIBRARY GENERAL PUBLIC LICENSE 587 TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 588 589 0. This License Agreement applies to any software library which 590 contains a notice placed by the copyright holder or other authorized 591 party saying it may be distributed under the terms of this Library 592 General Public License (also called "this License"). Each licensee is 593 addressed as "you". 594 595 A "library" means a collection of software functions and/or data 596 prepared so as to be conveniently linked with application programs 597 (which use some of those functions and data) to form executables. 598 599 The "Library", below, refers to any such software library or work 600 which has been distributed under these terms. A "work based on the 601 Library" means either the Library or any derivative work under 602 copyright law: that is to say, a work containing the Library or a 603 portion of it, either verbatim or with modifications and/or translated 604 straightforwardly into another language. (Hereinafter, translation is 605 included without limitation in the term "modification".) 606 607 "Source code" for a work means the preferred form of the work for 608 making modifications to it. For a library, complete source code means 609 all the source code for all modules it contains, plus any associated 610 interface definition files, plus the scripts used to control compilation 611 and installation of the library. 612 613 Activities other than copying, distribution and modification are not 614 covered by this License; they are outside its scope. The act of 615 running a program using the Library is not restricted, and output from 616 such a program is covered only if its contents constitute a work based 617 on the Library (independent of the use of the Library in a tool for 618 writing it). Whether that is true depends on what the Library does 619 and what the program that uses the Library does. 620 621 1. You may copy and distribute verbatim copies of the Library's 622 complete source code as you receive it, in any medium, provided that 623 you conspicuously and appropriately publish on each copy an 624 appropriate copyright notice and disclaimer of warranty; keep intact 625 all the notices that refer to this License and to the absence of any 626 warranty; and distribute a copy of this License along with the 627 Library. 628 629 You may charge a fee for the physical act of transferring a copy, 630 and you may at your option offer warranty protection in exchange for a 631 fee. 632 633 2. You may modify your copy or copies of the Library or any portion 634 of it, thus forming a work based on the Library, and copy and 635 distribute such modifications or work under the terms of Section 1 636 above, provided that you also meet all of these conditions: 637 638 a) The modified work must itself be a software library. 639 640 b) You must cause the files modified to carry prominent notices 641 stating that you changed the files and the date of any change. 642 643 c) You must cause the whole of the work to be licensed at no 644 charge to all third parties under the terms of this License. 645 646 d) If a facility in the modified Library refers to a function or a 647 table of data to be supplied by an application program that uses 648 the facility, other than as an argument passed when the facility 649 is invoked, then you must make a good faith effort to ensure that, 650 in the event an application does not supply such function or 651 table, the facility still operates, and performs whatever part of 652 its purpose remains meaningful. 653 654 (For example, a function in a library to compute square roots has 655 a purpose that is entirely well-defined independent of the 656 application. Therefore, Subsection 2d requires that any 657 application-supplied function or table used by this function must 658 be optional: if the application does not supply it, the square 659 root function must still compute square roots.) 660 661 These requirements apply to the modified work as a whole. If 662 identifiable sections of that work are not derived from the Library, 663 and can be reasonably considered independent and separate works in 664 themselves, then this License, and its terms, do not apply to those 665 sections when you distribute them as separate works. But when you 666 distribute the same sections as part of a whole which is a work based 667 on the Library, the distribution of the whole must be on the terms of 668 this License, whose permissions for other licensees extend to the 669 entire whole, and thus to each and every part regardless of who wrote 670 it. 671 672 Thus, it is not the intent of this section to claim rights or contest 673 your rights to work written entirely by you; rather, the intent is to 674 exercise the right to control the distribution of derivative or 675 collective works based on the Library. 676 677 In addition, mere aggregation of another work not based on the Library 678 with the Library (or with a work based on the Library) on a volume of 679 a storage or distribution medium does not bring the other work under 680 the scope of this License. 681 682 3. You may opt to apply the terms of the ordinary GNU General Public 683 License instead of this License to a given copy of the Library. To do 684 this, you must alter all the notices that refer to this License, so 685 that they refer to the ordinary GNU General Public License, version 2, 686 instead of to this License. (If a newer version than version 2 of the 687 ordinary GNU General Public License has appeared, then you can specify 688 that version instead if you wish.) Do not make any other change in 689 these notices. 690 691 Once this change is made in a given copy, it is irreversible for 692 that copy, so the ordinary GNU General Public License applies to all 693 subsequent copies and derivative works made from that copy. 694 695 This option is useful when you wish to copy part of the code of 696 the Library into a program that is not a library. 697 698 4. You may copy and distribute the Library (or a portion or 699 derivative of it, under Section 2) in object code or executable form 700 under the terms of Sections 1 and 2 above provided that you accompany 701 it with the complete corresponding machine-readable source code, which 702 must be distributed under the terms of Sections 1 and 2 above on a 703 medium customarily used for software interchange. 704 705 If distribution of object code is made by offering access to copy 706 from a designated place, then offering equivalent access to copy the 707 source code from the same place satisfies the requirement to 708 distribute the source code, even though third parties are not 709 compelled to copy the source along with the object code. 710 711 5. A program that contains no derivative of any portion of the 712 Library, but is designed to work with the Library by being compiled or 713 linked with it, is called a "work that uses the Library". Such a 714 work, in isolation, is not a derivative work of the Library, and 715 therefore falls outside the scope of this License. 716 717 However, linking a "work that uses the Library" with the Library 718 creates an executable that is a derivative of the Library (because it 719 contains portions of the Library), rather than a "work that uses the 720 library". The executable is therefore covered by this License. 721 Section 6 states terms for distribution of such executables. 722 723 When a "work that uses the Library" uses material from a header file 724 that is part of the Library, the object code for the work may be a 725 derivative work of the Library even though the source code is not. 726 Whether this is true is especially significant if the work can be 727 linked without the Library, or if the work is itself a library. The 728 threshold for this to be true is not precisely defined by law. 729 730 If such an object file uses only numerical parameters, data 731 structure layouts and accessors, and small macros and small inline 732 functions (ten lines or less in length), then the use of the object 733 file is unrestricted, regardless of whether it is legally a derivative 734 work. (Executables containing this object code plus portions of the 735 Library will still fall under Section 6.) 736 737 Otherwise, if the work is a derivative of the Library, you may 738 distribute the object code for the work under the terms of Section 6. 739 Any executables containing that work also fall under Section 6, 740 whether or not they are linked directly with the Library itself. 741 742 6. As an exception to the Sections above, you may also compile or 743 link a "work that uses the Library" with the Library to produce a 744 work containing portions of the Library, and distribute that work 745 under terms of your choice, provided that the terms permit 746 modification of the work for the customer's own use and reverse 747 engineering for debugging such modifications. 748 749 You must give prominent notice with each copy of the work that the 750 Library is used in it and that the Library and its use are covered by 751 this License. You must supply a copy of this License. If the work 752 during execution displays copyright notices, you must include the 753 copyright notice for the Library among them, as well as a reference 754 directing the user to the copy of this License. Also, you must do one 755 of these things: 756 757 a) Accompany the work with the complete corresponding 758 machine-readable source code for the Library including whatever 759 changes were used in the work (which must be distributed under 760 Sections 1 and 2 above); and, if the work is an executable linked 761 with the Library, with the complete machine-readable "work that 762 uses the Library", as object code and/or source code, so that the 763 user can modify the Library and then relink to produce a modified 764 executable containing the modified Library. (It is understood 765 that the user who changes the contents of definitions files in the 766 Library will not necessarily be able to recompile the application 767 to use the modified definitions.) 768 769 b) Accompany the work with a written offer, valid for at 770 least three years, to give the same user the materials 771 specified in Subsection 6a, above, for a charge no more 772 than the cost of performing this distribution. 773 774 c) If distribution of the work is made by offering access to copy 775 from a designated place, offer equivalent access to copy the above 776 specified materials from the same place. 777 778 d) Verify that the user has already received a copy of these 779 materials or that you have already sent this user a copy. 780 781 For an executable, the required form of the "work that uses the 782 Library" must include any data and utility programs needed for 783 reproducing the executable from it. However, as a special exception, 784 the source code distributed need not include anything that is normally 785 distributed (in either source or binary form) with the major 786 components (compiler, kernel, and so on) of the operating system on 787 which the executable runs, unless that component itself accompanies 788 the executable. 789 790 It may happen that this requirement contradicts the license 791 restrictions of other proprietary libraries that do not normally 792 accompany the operating system. Such a contradiction means you cannot 793 use both them and the Library together in an executable that you 794 distribute. 795 796 7. You may place library facilities that are a work based on the 797 Library side-by-side in a single library together with other library 798 facilities not covered by this License, and distribute such a combined 799 library, provided that the separate distribution of the work based on 800 the Library and of the other library facilities is otherwise 801 permitted, and provided that you do these two things: 802 803 a) Accompany the combined library with a copy of the same work 804 based on the Library, uncombined with any other library 805 facilities. This must be distributed under the terms of the 806 Sections above. 807 808 b) Give prominent notice with the combined library of the fact 809 that part of it is a work based on the Library, and explaining 810 where to find the accompanying uncombined form of the same work. 811 812 8. You may not copy, modify, sublicense, link with, or distribute 813 the Library except as expressly provided under this License. Any 814 attempt otherwise to copy, modify, sublicense, link with, or 815 distribute the Library is void, and will automatically terminate your 816 rights under this License. However, parties who have received copies, 817 or rights, from you under this License will not have their licenses 818 terminated so long as such parties remain in full compliance. 819 820 9. You are not required to accept this License, since you have not 821 signed it. However, nothing else grants you permission to modify or 822 distribute the Library or its derivative works. These actions are 823 prohibited by law if you do not accept this License. Therefore, by 824 modifying or distributing the Library (or any work based on the 825 Library), you indicate your acceptance of this License to do so, and 826 all its terms and conditions for copying, distributing or modifying 827 the Library or works based on it. 828 829 10. Each time you redistribute the Library (or any work based on the 830 Library), the recipient automatically receives a license from the 831 original licensor to copy, distribute, link with or modify the Library 832 subject to these terms and conditions. You may not impose any further 833 restrictions on the recipients' exercise of the rights granted herein. 834 You are not responsible for enforcing compliance by third parties to 835 this License. 836 837 11. If, as a consequence of a court judgment or allegation of patent 838 infringement or for any other reason (not limited to patent issues), 839 conditions are imposed on you (whether by court order, agreement or 840 otherwise) that contradict the conditions of this License, they do not 841 excuse you from the conditions of this License. If you cannot 842 distribute so as to satisfy simultaneously your obligations under this 843 License and any other pertinent obligations, then as a consequence you 844 may not distribute the Library at all. For example, if a patent 845 license would not permit royalty-free redistribution of the Library by 846 all those who receive copies directly or indirectly through you, then 847 the only way you could satisfy both it and this License would be to 848 refrain entirely from distribution of the Library. 849 850 If any portion of this section is held invalid or unenforceable under any 851 particular circumstance, the balance of the section is intended to apply, 852 and the section as a whole is intended to apply in other circumstances. 853 854 It is not the purpose of this section to induce you to infringe any 855 patents or other property right claims or to contest validity of any 856 such claims; this section has the sole purpose of protecting the 857 integrity of the free software distribution system which is 858 implemented by public license practices. Many people have made 859 generous contributions to the wide range of software distributed 860 through that system in reliance on consistent application of that 861 system; it is up to the author/donor to decide if he or she is willing 862 to distribute software through any other system and a licensee cannot 863 impose that choice. 864 865 This section is intended to make thoroughly clear what is believed to 866 be a consequence of the rest of this License. 867 868 12. If the distribution and/or use of the Library is restricted in 869 certain countries either by patents or by copyrighted interfaces, the 870 original copyright holder who places the Library under this License may add 871 an explicit geographical distribution limitation excluding those countries, 872 so that distribution is permitted only in or among countries not thus 873 excluded. In such case, this License incorporates the limitation as if 874 written in the body of this License. 875 876 13. The Free Software Foundation may publish revised and/or new 877 versions of the Library General Public License from time to time. 878 Such new versions will be similar in spirit to the present version, 879 but may differ in detail to address new problems or concerns. 880 881 Each version is given a distinguishing version number. If the Library 882 specifies a version number of this License which applies to it and 883 "any later version", you have the option of following the terms and 884 conditions either of that version or of any later version published by 885 the Free Software Foundation. If the Library does not specify a 886 license version number, you may choose any version ever published by 887 the Free Software Foundation. 888 889 14. If you wish to incorporate parts of the Library into other free 890 programs whose distribution conditions are incompatible with these, 891 write to the author to ask for permission. For software which is 892 copyrighted by the Free Software Foundation, write to the Free 893 Software Foundation; we sometimes make exceptions for this. Our 894 decision will be guided by the two goals of preserving the free status 895 of all derivatives of our free software and of promoting the sharing 896 and reuse of software generally. 897 898 NO WARRANTY 899 900 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO 901 WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. 902 EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR 903 OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY 904 KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE 905 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 906 PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE 907 LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME 908 THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 909 910 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN 911 WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY 912 AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU 913 FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR 914 CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE 915 LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING 916 RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A 917 FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF 918 SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH 919 DAMAGES. 920 921 END OF TERMS AND CONDITIONS 922 923 Appendix: How to Apply These Terms to Your New Libraries 924 925 If you develop a new library, and you want it to be of the greatest 926 possible use to the public, we recommend making it free software that 927 everyone can redistribute and change. You can do so by permitting 928 redistribution under these terms (or, alternatively, under the terms of the 929 ordinary General Public License). 930 931 To apply these terms, attach the following notices to the library. It is 932 safest to attach them to the start of each source file to most effectively 933 convey the exclusion of warranty; and each file should have at least the 934 "copyright" line and a pointer to where the full notice is found. 935 936 <one line to give the library's name and a brief idea of what it does.> 937 Copyright (C) <year> <name of author> 938 939 This library is free software; you can redistribute it and/or 940 modify it under the terms of the GNU Library General Public 941 License as published by the Free Software Foundation; either 942 version 2 of the License, or (at your option) any later version. 943 944 This library is distributed in the hope that it will be useful, 945 but WITHOUT ANY WARRANTY; without even the implied warranty of 946 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 947 Library General Public License for more details. 948 949 You should have received a copy of the GNU Library General Public 950 License along with this library; if not, write to the Free 951 Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 952 953 Also add information on how to contact you by electronic and paper mail. 954 955 You should also get your employer (if you work as a programmer) or your 956 school, if any, to sign a "copyright disclaimer" for the library, if 957 necessary. Here is a sample; alter the names: 958 959 Yoyodyne, Inc., hereby disclaims all copyright interest in the 960 library `Frob' (a library for tweaking knobs) written by James Random Hacker. 961 962 <signature of Ty Coon>, 1 April 1990 963 Ty Coon, President of Vice 964 965 That's all there is to it! 966