aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan McCrohan <jmccrohan@gmail.com>2012-05-08 14:52:05 +0100
committerJonathan McCrohan <jmccrohan@gmail.com>2012-05-08 14:52:05 +0100
commit3a941f4ae2213f26118f5cfde03ca793b31ca838 (patch)
tree8ad0b9793d5ae8cf716bb288828fea12efb1d1c1
parente8ed9bd2e7597f7aefdfc7004a308f0e291c3ca7 (diff)
downloadfiglet-upstream/2.2.3.tar.gz
Imported Upstream version 2.2.3upstream/2.2.3
-rw-r--r--CHANGES36
-rw-r--r--FAQ26
-rw-r--r--LICENSE81
-rw-r--r--Makefile87
-rw-r--r--Makefile.tc42
-rw-r--r--README8
-rw-r--r--chkfont.652
-rw-r--r--chkfont.c28
-rw-r--r--crc.c45
-rw-r--r--crc.h49
-rw-r--r--figlet.653
-rw-r--r--figlet.c38
-rwxr-xr-x[-rw-r--r--]figlist0
-rw-r--r--figlist.652
-rw-r--r--figmagic6
-rw-r--r--fonts/jis0201.flc447
-rw-r--r--getopt.c104
-rw-r--r--inflate.c45
-rw-r--r--inflate.h45
-rwxr-xr-x[-rw-r--r--]showfigfonts0
-rw-r--r--showfigfonts.667
-rw-r--r--zipio.c50
-rw-r--r--zipio.h43
23 files changed, 825 insertions, 579 deletions
diff --git a/CHANGES b/CHANGES
index aead9cf..863a25a 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,39 @@
+Changes in FIGlet 2.2.3
+-----------------------
+
+FIGlet 2.2.3 is a revision of FIGlet 2.2.2 featuring minor bugfixes and
+important licensing changes in the zipio files. The full list of
+changes is:
+
+o License changed from "Academic Free License" to "New BSD License"
+ (3-clause) as agreed by FIGlet authors
+
+o New JIS X 0201 control file (Micah Cowan)
+
+o Fix behavior of JIS0201 SHIFT-OUT and SHIFT-IN that were previouly
+ inverted (Micah Cowan)
+
+o Fix memory violation when smushing at line start
+
+o Fix handling of memory allocation errors
+
+o Relicense Ed Hamrick zipio under the MIT license. This should
+ eliminate any concerns about redistribution of FIGlet as libre
+ software.
+
+o Update Makefile to meet modern standards in variable naming, using
+ BINDIR as the pathname for binary files and reservind DESTDIR
+ as the extra prefix commonly used in package building.
+
+o Add a Turbo C makefile, just because I had the compiler. (this
+ also tests portability to old compilers and foreign platforms)
+
+o Add Jonathon Abbott's man pages for figlist, showfigfonts and
+ chkfont originally contributed to the Debian Project
+
+These changes were made by Claudio Matsuoka <cmatsuoka@gmail.com>
+12 January 2011
+
Changes in FIGlet 2.2.2
-----------------------
diff --git a/FAQ b/FAQ
index 0b98eb6..63050dc 100644
--- a/FAQ
+++ b/FAQ
@@ -2,10 +2,10 @@
| __| | __| |____| |_ | __| _ | | This FIGlet FAQ is
| __|- -| | | | - _| _| | __| | | | posted once a month
|__| |_____|_____|__|____|__| |__| |__|__|__ _| on figlet@figlet.org
- info@figlet.org http://www.figlet.org/ |__| [FIGlet FAQ v0.92]
+ info@figlet.org http://www.figlet.org/ |__| [FIGlet FAQ v0.91]
===========================================================================
-The latest version of FIGlet is 2.2.2 and can be downloaded from
+The latest version of FIGlet is 2.2.3 and can be downloaded from
ftp://ftp.figlet.org/pub/figlet/program
===========================================================================
@@ -19,7 +19,6 @@ ftp://ftp.figlet.org/pub/figlet/program
===========================================================================
-
1. What is FIGlet?
FIGlet is a program for making large letters out of ordinary text
_ _ _ _ _ _
@@ -28,38 +27,37 @@ ftp://ftp.figlet.org/pub/figlet/program
| | | < __/ | |_| | | | \__ \
|_|_|_|\_\___| \__|_| |_|_|___/
-
2. Where can I get FIGlet from?
From the official FIGlet website at http://www.figlet.org/
or from the FIGlet FTP site at ftp://ftp.figlet.org/pub/figlet/
-
3. Where can I get more fonts for FIGlet?
From the FTP site at ftp://ftp.figlet.org/pub/figlet/fonts/
There are currently over 400 fonts available for download
-
-4 Where can I hear about regular FIGlet program and font updates?
- There is a mailing list available for FIGlet. To subscribe
- or unsubscribe from the FIGlet mailing list, please visit
- http://www.figlet.org/mailman/listinfo/figlet
-
+4 Where can I hear about regular FIGlet program and font updates?
+ There is a mailing list for FIGlet for general discussions about
+ FIGlet and a place where you can ask questions or share ideas
+ with other FIGlet users. It is also the place where we will publish
+ news about new fonts, new software updates etc.
+
+ To subscribe or unsubscribe from the FIGlet mailing list,
+ please send email to figlet-subscribe@figlet.org or visit the
+ following web page: http://www.figlet.org/mailman/listinfo/figlet
5. How can I contribute?
To contribute new fonts, software or information, please contact
us at info@figlet.org
-
6. Why am I getting this mail and can you make it stop?
If you received this email it is probably because you are subscribed
to the FIGlet mailing list. Please see Question 4 of this FAQ on how
to unsubscribe from the FIGlet list.
-
7. Where does the name FIGlet come from?
"Frank, Ian and Glen's letters"
= FAQ Maintainer ==========================================================
-Christiaan Keet keet@plig.net 05 July 2005
+Christiaan Keet keet@plig.net July 2005
===========================================================================
diff --git a/LICENSE b/LICENSE
index 5a1d756..a841aea 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,51 +1,30 @@
-The Academic Free License
-v. 2.1
-
-This Academic Free License (the "License") applies to any original work of authorship (the "Original Work") whose owner (the "Licensor") has placed the following notice immediately following the copyright notice for the Original Work:
-
-Licensed under the Academic Free License version 2.1
-
-1) Grant of Copyright License. Licensor hereby grants You a world-wide, royalty-free, non-exclusive, perpetual, sublicenseable license to do the following:
-
-a) to reproduce the Original Work in copies;
-
-b) to prepare derivative works ("Derivative Works") based upon the Original Work;
-
-c) to distribute copies of the Original Work and Derivative Works to the public;
-
-d) to perform the Original Work publicly; and
-
-e) to display the Original Work publicly.
-
-2) Grant of Patent License. Licensor hereby grants You a world-wide, royalty-free, non-exclusive, perpetual, sublicenseable license, under patent claims owned or controlled by the Licensor that are embodied in the Original Work as furnished by the Licensor, to make, use, sell and offer for sale the Original Work and Derivative Works.
-
-3) Grant of Source Code License. The term "Source Code" means the preferred form of the Original Work for making modifications to it and all available documentation describing how to modify the Original Work. Licensor hereby agrees to provide a machine-readable copy of the Source Code of the Original Work along with each copy of the Original Work that Licensor distributes. Licensor reserves the right to satisfy this obligation by placing a machine-readable copy of the Source Code in an information repository reasonably calculated to permit inexpensive and convenient access by You for as long as Licensor continues to distribute the Original Work, and by publishing the address of that information repository in a notice immediately following the copyright notice that applies to the Original Work.
-
-4) Exclusions From License Grant. Neither the names of Licensor, nor the names of any contributors to the Original Work, nor any of their trademarks or service marks, may be used to endorse or promote products derived from this Original Work without express prior written permission of the Licensor. Nothing in this License shall be deemed to grant any rights to trademarks, copyrights, patents, trade secrets or any other intellectual property of Licensor except as expressly stated herein. No patent license is granted to make, use, sell or offer to sell embodiments of any patent claims other than the licensed claims defined in Section 2. No right is granted to the trademarks of Licensor even if such marks are included in the Original Work. Nothing in this License shall be interpreted to prohibit Licensor from licensing under different terms from this License any Original Work that Licensor otherwise would have a right to license.
-
-5) This section intentionally omitted.
-
-6) Attribution Rights. You must retain, in the Source Code of any Derivative Works that You create, all copyright, patent or trademark notices from the Source Code of the Original Work, as well as any notices of licensing and any descriptive text identified therein as an "Attribution Notice." You must cause the Source Code for any Derivative Works that You create to carry a prominent Attribution Notice reasonably calculated to inform recipients that You have modified the Original Work.
-
-7) Warranty of Provenance and Disclaimer of Warranty. Licensor warrants that the copyright in and to the Original Work and the patent rights granted herein by Licensor are owned by the Licensor or are sublicensed to You under the terms of this License with the permission of the contributor(s) of those copyrights and patent rights. Except as expressly stated in the immediately proceeding sentence, the Original Work is provided under this License on an "AS IS" BASIS and WITHOUT WARRANTY, either express or implied, including, without limitation, the warranties of NON-INFRINGEMENT, MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY OF THE ORIGINAL WORK IS WITH YOU. This DISCLAIMER OF WARRANTY constitutes an essential part of this License. No license to Original Work is granted hereunder except under this disclaimer.
-
-8) Limitation of Liability. Under no circumstances and under no legal theory, whether in tort (including negligence), contract, or otherwise, shall the Licensor be liable to any person for any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or the use of the Original Work including, without limitation, damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses. This limitation of liability shall not apply to liability for death or personal injury resulting from Licensor's negligence to the extent applicable law prohibits such limitation. Some jurisdictions do not allow the exclusion or limitation of incidental or consequential damages, so this exclusion and limitation may not apply to You.
-
-9) Acceptance and Termination. If You distribute copies of the Original Work or a Derivative Work, You must make a reasonable effort under the circumstances to obtain the express assent of recipients to the terms of this License. Nothing else but this License (or another written agreement between Licensor and You) grants You permission to create Derivative Works based upon the Original Work or to exercise any of the rights granted in Section 1 herein, and any attempt to do so except under the terms of this License (or another written agreement between Licensor and You) is expressly prohibited by U.S. copyright law, the equivalent laws of other countries, and by international treaty. Therefore, by exercising any of the rights granted to You in Section 1 herein, You indicate Your acceptance of this License and all of its terms and conditions.
-
-10) Termination for Patent Action. This License shall terminate automatically and You may no longer exercise any of the rights granted to You by this License as of the date You commence an action, including a cross-claim or counterclaim, against Licensor or any licensee alleging that the Original Work infringes a patent. This termination provision shall not apply for an action alleging patent infringement by combinations of the Original Work with other software or hardware.
-
-11) Jurisdiction, Venue and Governing Law. Any action or suit relating to this License may be brought only in the courts of a jurisdiction wherein the Licensor resides or in which Licensor conducts its primary business, and under the laws of that jurisdiction excluding its conflict-of-law provisions. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any use of the Original Work outside the scope of this License or after its termination shall be subject to the requirements and penalties of the U.S. Copyright Act, 17 U.S.C. ยง 101 et seq., the equivalent laws of other countries, and international treaty. This section shall survive the termination of this License.
-
-12) Attorneys Fees. In any action to enforce the terms of this License or seeking damages relating thereto, the prevailing party shall be entitled to recover its costs and expenses, including, without limitation, reasonable attorneys' fees and costs incurred in connection with such action, including any appeal of such action. This section shall survive the termination of this License.
-
-13) Miscellaneous. This License represents the complete agreement concerning the subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable.
-
-14) Definition of "You" in This License. "You" throughout this License, whether in upper or lower case, means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License. For legal entities, "You" includes any entity that controls, is controlled by, or is under common control with you. For purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
-
-15) Right to Use. You may use the Original Work in all ways not otherwise restricted or conditioned by this License or by law, and Licensor promises not to interfere with or be responsible for such uses by You.
-
-This license is Copyright (C) 2003-2004 Lawrence E. Rosen. All rights reserved. Permission is hereby granted to copy and distribute this license without modification. This license may not be modified without the express written permission of its copyright owner.
-
-
-
+Copyright (C) 1991, 1993, 1994 Glenn Chappell and Ian Chai
+Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 John Cowan
+Copyright (C) 2002 Christiaan Keet
+Copyright (C) 2011 Claudio Matsuoka
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+3. Neither the name of the copyright holders nor the names of their
+ contributors may be used to endorse or promote products derived
+ from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
+TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
+USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Makefile b/Makefile
index da5107e..28dea3d 100644
--- a/Makefile
+++ b/Makefile
@@ -1,24 +1,34 @@
-# Makefile for figlet version 2.2.2 (05 July 2005)
+# Makefile for figlet version 2.2.3 (11 Jan 2011)
+# adapted from Makefile for figlet version 2.2.2 (05 July 2005)
# adapted from Makefile for figlet version 2.2 (15 Oct 1996)
# Copyright 1993, 1994,1995 Glenn Chappell and Ian Chai
# Copyright 1996, 1997, 1998, 1999, 2000, 2001 John Cowan
# Copyright 2002 Christiaan Keet
+# Copyright 2011 Claudio Matsuoka
-# Please make sure DESTDIR, MANDIR, DEFAULTFONTDIR and
+# Please notice that to follow modern standards and ease third-party
+# package creation, binaries are now installed under BINDIR, and DESTDIR
+# is reserved for the installation pathname prefix.
+#
+# Please make sure BINDIR, MANDIR, DEFAULTFONTDIR and
# DEFAULTFONTFILE are defined to reflect the situation
# on your computer. See README for details.
# Don't change this even if your shell is different. The only reason
# for changing this is if sh is not in the same place.
SHELL = /bin/sh
-CC = gcc
-CFLAGS = -g
+
+# The C compiler and linker to use
+CC = gcc
+CFLAGS = -g -O2 -Wall
+LD = gcc
+LDFLAGS =
# Where the executables should be put
-DESTDIR = /usr/local/bin
+BINDIR = /usr/local/bin
# Where the man page should be put
-MANDIR = /usr/local/man/man6
+MANDIR = /usr/local/man
# Where figlet will search first for fonts (the ".flf" files).
DEFAULTFONTDIR = /usr/local/share/figlet
@@ -35,28 +45,53 @@ DEFAULTFONTFILE = standard.flf
## END OF CONFIGURATION SECTION
##
-SOURCES = figlet.c zipio.c crc.c inflate.c
+VERSION = 2.2.3
+DIST = figlet-$(VERSION)
+OBJS = figlet.o zipio.o crc.o inflate.o
+BINS = figlet chkfont figlist showfigfonts
+MANUAL = figlet.6 chkfont.6 figlist.6 showfigfonts.6
+DFILES = Makefile Makefile.tc $(MANUAL) $(OBJS:.o=.c) chkfont.c \
+ figlist showfigfonts CHANGES FAQ README LICENSE figfont.txt \
+ crc.h inflate.h zipio.h
+
+.c.o:
+ $(CC) -c $(CFLAGS) -DDEFAULTFONTDIR=\"$(DEFAULTFONTDIR)\" \
+ -DDEFAULTFONTFILE=\"$(DEFAULTFONTFILE)\" -o $*.o $<
-all: figlet chkfont
+all: $(BINS)
-figlet: $(SOURCES)
- $(CC) $(CFLAGS) -DDEFAULTFONTDIR=\"$(DEFAULTFONTDIR)\" \
- -DDEFAULTFONTFILE=\"$(DEFAULTFONTFILE)\" \
- $(SOURCES) -o figlet
- chmod a+x figlet
+figlet: $(OBJS)
+ $(LD) $(LDFLAGS) -o $@ $(OBJS)
-chkfont: chkfont.c
- $(CC) $(CFLAGS) -o chkfont chkfont.c
+chkfont: chkfont.o
+ $(LD) $(LDFLAGS) -o $@ chkfont.o
clean:
- rm -f *.o figlet chkfont
-
-install: figlet chkfont
- mkdir -p $(DEFAULTFONTDIR)
- cp figlet $(DESTDIR)
- cp figlet.6 $(MANDIR)
- cp chkfont $(DESTDIR)
- cp figlist $(DESTDIR)
- cp showfigfonts $(DESTDIR)
- cp fonts/*.flf $(DEFAULTFONTDIR)
- cp fonts/*.flc $(DEFAULTFONTDIR)
+ rm -f *.o *~ core figlet chkfont
+
+install: all
+ mkdir -p $(DESTDIR)$(BINDIR)
+ mkdir -p $(DESTDIR)$(MANDIR)/man6
+ mkdir -p $(DESTDIR)$(DEFAULTFONTDIR)
+ cp $(BINS) $(DESTDIR)$(BINDIR)
+ cp $(MANUAL) $(DESTDIR)$(MANDIR)/man6
+ cp fonts/*.flf $(DESTDIR)$(DEFAULTFONTDIR)
+ cp fonts/*.flc $(DESTDIR)$(DEFAULTFONTDIR)
+
+dist:
+ rm -Rf $(DIST) $(DIST).tar.gz
+ mkdir $(DIST)/
+ cp $(DFILES) $(DIST)/
+ mkdir $(DIST)/fonts
+ cp fonts/*.fl[fc] $(DIST)/fonts
+ tar cvf - $(DIST) | gzip -9c > $(DIST).tar.gz
+ rm -Rf $(DIST)
+ ls -l $(DIST).tar.gz
+
+$(OBJS) chkfont.o getopt.o: Makefile
+chkfont.o: chkfont.c
+crc.o: crc.c crc.h
+figlet.o: figlet.c zipio.h
+getopt.o: getopt.c
+inflate.o: inflate.c inflate.h
+zipio.o: zipio.c zipio.h inflate.h crc.h
diff --git a/Makefile.tc b/Makefile.tc
new file mode 100644
index 0000000..435fc58
--- /dev/null
+++ b/Makefile.tc
@@ -0,0 +1,42 @@
+# Turbo C makefile for figlet
+# adapted from Makefile for figlet version 2.3.0 (11 Jan 2011)
+# adapted from Makefile for figlet version 2.2.2 (05 July 2005)
+# adapted from Makefile for figlet version 2.2 (15 Oct 1996)
+# Copyright 1993, 1994,1995 Glenn Chappell and Ian Chai
+# Copyright 1996, 1997, 1998, 1999, 2000, 2001 John Cowan
+# Copyright 2002 Christiaan Keet
+# Copyright 2011 Claudio Matsuoka
+
+# The C compiler and linker to use
+CC = tcc
+CFLAGS = -mc -I\tc\include
+LD = tcc
+LDFLAGS = -mc -L\tc\lib
+
+# Use this definition if you can't put things in /usr/local/share/figlet
+DEFAULTFONTDIR = fonts
+
+# The filename of the font to be used if no other is specified
+# (standard.flf is recommended, but any other can be used).
+# This font file should reside in the directory specified by
+# DEFAULTFONTDIR.
+DEFAULTFONTFILE = standard.flf
+
+##
+## END OF CONFIGURATION SECTION
+##
+
+OBJS = figlet.obj zipio.obj crc.obj inflate.obj getopt.obj
+BINS = figlet.exe chkfont.exe
+
+.c.obj:
+ $(CC) -c $(CFLAGS) -DDEFAULTFONTDIR="$(DEFAULTFONTDIR)" \
+ -DDEFAULTFONTFILE="$(DEFAULTFONTFILE)" -o$*.obj $<
+
+all: $(BINS)
+
+figlet.exe: $(OBJS)
+ $(LD) $(LDFLAGS) -o$@ $(OBJS)
+
+chkfont.exe: chkfont.obj
+ $(LD) $(LDFLAGS) -o$@ chkfont.obj
diff --git a/README b/README
index cbd5deb..c3b2e53 100644
--- a/README
+++ b/README
@@ -1,5 +1,5 @@
-About FIGlet (Frank, Ian & Glenn's Letters) release 2.2.2, 05 July 2005
------------------------------------------------------------------------
+About FIGlet (Frank, Ian & Glenn's Letters) release 2.2.3, 12 January 2011
+--------------------------------------------------------------------------
FIGlet is a program that creates large characters out of ordinary
screen characters
_ _ _ _ _ _
@@ -90,12 +90,12 @@ you can probably still read it using
nroff -man figlet.6 | more
(2) Do a complete installation. To do the this, set the variables
-DESTDIR and MANDIR in Makefile to the appropriate values. DESTDIR
+BINDIR and MANDIR in Makefile to the appropriate values. BINDIR
should be the full pathname of the directory in which the executable
files should be put (we recommend "/usr/games"); MANDIR should be the
full pathname of the directory in which the figlet man page should be
put, generally "/usr/man/man6". Once DEFAULTFONTDIR, DEFAULTFONTFILE,
-DESTDIR and MANDIR have been set, in the directory containing the FIGlet
+BINDIR and MANDIR have been set, in the directory containing the FIGlet
source, type "make install".
If space is a problem, the only files you absolutely must have to run
diff --git a/chkfont.6 b/chkfont.6
new file mode 100644
index 0000000..0e0b936
--- /dev/null
+++ b/chkfont.6
@@ -0,0 +1,52 @@
+.\" chkfont
+.\" By Glenn Chappell <ggc@uiuc.edu>
+.\"
+.\" This program checks figlet 2.0/2.1 font files for format errors.
+.\" It also looks for signs of common problems and gives warnings.
+.\" chkfont does not modify font files.
+.\"
+.\" Usage: chkfont fontfile ...
+.\"
+.\" Note: This is very much a spare-time project. It's probably
+.\" full o' bugs.
+.\"
+.\" Manual page by Jonathon Abbott, for the Debian Project
+.\" slightly modified by Francesco Tapparo, for the Debian Project
+.TH CHKFONT 6 "12 January 2011" "v2.2.3"
+
+.SH NAME
+chkfont \- checks figlet 2.0 and up font files for format errors
+
+.SH SYNOPSIS
+.B chkfont
+[
+.I fontfile
+]
+
+.SH DESCRIPTION
+This program checks figlet 2.0 and up font files for format errors.
+It also looks for signs of common problems and gives warnings.
+chkfont does not modify font files.
+
+.SH EXAMPLES
+To use
+.B chkfont
+on the "big" font
+.RS
+
+.B example% chkfont /usr/share/figlet/big.flf
+
+.RE
+
+.SH BUGS
+Doesn't work on compressed font files.
+
+.SH AUTHORS
+chkfont was written by Glenn Chappell <ggc@uiuc.edu>
+
+This manual page was written by Jonathon Abbott for the Debian Project.
+
+.SH "SEE ALSO"
+.BR figlet (6),
+.BR showfigfonts (6),
+.BR figlist (6)
diff --git a/chkfont.c b/chkfont.c
index 8272207..92fefad 100644
--- a/chkfont.c
+++ b/chkfont.c
@@ -1,6 +1,9 @@
#include <stdio.h>
#include <string.h>
#include <ctype.h>
+#ifdef __STDC__
+#include <stdlib.h>
+#endif
#define DATE "20 Feb 1996"
#define VERSION "2.2"
@@ -68,10 +71,9 @@ char *ptr;
ptr=(char *)malloc(size);
if (ptr==NULL) {
fprintf(stderr,"%s: Out of memory\n",myname);
+ exit(1);
}
-else {
- return(ptr);
- }
+return(ptr);
}
int badsuffix(path,suffix)
@@ -103,15 +105,22 @@ fprintf(stderr,"Usage: %s fontfile ...\n",myname);
exit(1);
}
-
void readchar()
{
int i,expected_width,k,len,newlen,diff,l;
char endmark,expected_endmark;
int leadblanks,minleadblanks,trailblanks,mintrailblanks;
+char *ret;
+expected_width = expected_endmark = 0; /* prevent compiler warning */
for (i=0;i<charheight;i++) {
- fgets(fileline,maxlen+1000,fontfile);
+ ret = fgets(fileline,maxlen+1000,fontfile);
+ if (ret == NULL) {
+ printf("%s: ERROR (fatal)- Unexpected read error after line %d.\n",
+ fontfilename,currline);
+ ec++;
+ weregone(1); if (gone) return;
+ }
if (feof(fontfile)) {
printf("%s: ERROR (fatal)- Unexpected end of file after line %d.\n",
fontfilename,currline);
@@ -235,7 +244,12 @@ if (fontfile!=stdin) {
weregone(0); if (gone) return;
}
}
-fscanf(fontfile,"%4s",magicnum);
+numsread=fscanf(fontfile,"%4s",magicnum);
+if (numsread == EOF) {
+ printf("%s: ERROR- can't read magic number.\n",fontfilename);
+ ec++;
+ weregone(0); if (gone) return;
+ }
if (strcmp(magicnum,FONTFILEMAGICNUMBER)) {
printf("%s: ERROR- Incorrect magic number.\n",fontfilename);
ec++;
@@ -457,5 +471,5 @@ for (arg=1;arg<argc;arg++) {
checkit();
if (fileline!=NULL) free(fileline);
}
-exit(0);
+return 0;
}
diff --git a/crc.c b/crc.c
index 95fbe09..b1491fc 100644
--- a/crc.c
+++ b/crc.c
@@ -1,32 +1,35 @@
/*
* crc.c - CRC calculation routine
*
- * Version 1.0
+ * Version 1.0.1
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
+ * Copyright (C) 1995, Edward B. Hamrick
*
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
*
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+/*
+ * Changes from 1.0 to 1.0.1:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Claudio Matsuoka (Jan 11 2011)
*/
#include "crc.h"
diff --git a/crc.h b/crc.h
index 1f84831..bd7c536 100644
--- a/crc.h
+++ b/crc.h
@@ -1,32 +1,35 @@
/*
* crc.h - CRC calculation routine
*
- * Version 1.0
+ * Version 1.0.1
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
- *
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
- *
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * Copyright (C) 1995, Edward B. Hamrick
+ *
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
+ *
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+/*
+ * Changes from 1.0 to 1.0.1:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Claudio Matsuoka (Jan 11 2011)
*/
/*
diff --git a/figlet.6 b/figlet.6
index fc6d8fd..c086473 100644
--- a/figlet.6
+++ b/figlet.6
@@ -3,12 +3,13 @@
.\" Internet: <info@figlet.org>
.\" Portions Copyright 1996, 1997, 1998, 1999, 2000, 2001 by John Cowan <cowan@ccil.org>
.\" Portions Copyright 2002 by Christiaan Keet
+.\" Portions Copyright 2011 by Claudio Matsuoka
.\" FIGlet, along with the various FIGlet fonts and documentation, may
.\" be freely copied and distributed.
.\" If you use FIGlet, please send an e-mail message to
.\" <info@figlet.org>
.\"
-.TH FIGLET 6 "05 July 2005" "v2.2.2"
+.TH FIGLET 6 "12 January 2011" "v2.2.3"
.SH NAME
FIGlet \- display large characters made up of ordinary screen characters
@@ -483,8 +484,8 @@ printed out. For example,
.B FIGlet
2.2 will print
.RB `` 20200 ''
-, version 2.2.2 will print
-.RB `` 20202 ''.
+, version 2.2.1 will print
+.RB `` 20201 ''.
Similarly, version 3.7.2 would print
.RB `` 30702 ''.
These numbers are guaranteed to be
@@ -1000,7 +1001,7 @@ I suppose this is to be expected.
Please report any errors you find in this man page or the program to
<info@figlet.org>
-.SH MAILING LIST
+.SH WEBSITE AND MAILING LIST
You can get many fonts which are not in the basic
.B FIGlet
package from the Web site
@@ -1009,26 +1010,29 @@ should also contain the latest version of
.B FIGlet
and other utilities related to
.BR FIGlet .
-We run 3 e-mail lists dedicated to
-.B FIGlet
-software and font announcements, as well as general discussion about
-.BR FIGlet :
- figlet@figlet.org General discussion
- figletfonts@figlet.org Font announcements
- figletsoftware@figlet.org Software announcements
- (The last two lists are moderated)
-To subscribe or unsubscribe from the FIGlet mailing lists, please visit the corresponding URL:
- http://www.figlet.org/mailman/listinfo/figlet
- http://www.figlet.org/mailman/listinfo/figletfonts
- http://www.figlet.org/mailman/listinfo/figletsoftware
+There is a mailing list for
+.B FIGlet
+for general discussions about
+.B FIGlet
+and a place where you can ask questions or share ideas
+with other
+.B FIGlet
+users. It is also the place where we will publish
+news about new fonts, new software updates etc.
+
+To subscribe or unsubscribe from the
+.B FIGlet
+mailing list,
+please send email to figlet-subscribe@figlet.org or figlet-unsubscribe@figlet.org or visit the
+following web page: http://www.figlet.org/mailman/listinfo/figlet
.SH AUTHORS
-Glenn Chappell <c486scm@semovm.semo.edu> did most of the work.
+Glenn Chappell did most of the work.
You can e-mail him but he is not an e-mail fanatic; people who e-mail
Glenn will probably get answers, but if you e-mail his best friend:
-Ian Chai <ianchai@usa.net>, who
+Ian Chai, who
.I is
an e-mail fanatic, you'll get answers, endless conversation about the
mysteries of life, invitations to join some 473 mailing lists and a
@@ -1037,13 +1041,13 @@ free toaster. (Well, ok, maybe not the free toaster.)
Frank inspired this whole project with his .sig, but don't e-mail
him; he's decidedly an un-e-mail-fanatic.
-Gilbert "The Mad Programmer" Healton <ghealton@nmia.com> added the
+Gilbert "The Mad Programmer" Healton added the
.B \-A
option for version 2.1.1. This option specified input from
the command line; it is still allowed,
but has no effect.
-John Cowan <cowan@ccil.org> added the
+John Cowan added the
.BR \-o ,
.BR \-s ,
.BR \-k ,
@@ -1057,8 +1061,13 @@ and compressed fonts
and control files.
He also revised this documentation,
with a lot of input from
-Paul Burton <solution@earthlink.net>.
+Paul Burton.
-Christiaan Keet <keet@plig.net> revised the official FIGlet documentation
+As a fan of FIGlet, Christiaan Keet revised the official FIGlet documentation
and set up the new FIGlet website at http://www.figlet.org/ (and the
corresponding ftp://ftp.figlet.org/pub/figlet/)
+
+.SH SEE ALSO
+.BR figlist (6),
+.BR chkfont (6),
+.BR showfigfonts (6)
diff --git a/figlet.c b/figlet.c
index d3bfbbb..e26d42b 100644
--- a/figlet.c
+++ b/figlet.c
@@ -3,16 +3,17 @@
FIGlet Copyright 1991, 1993, 1994 Glenn Chappell and Ian Chai
FIGlet Copyright 1996, 1997, 1998, 1999, 2000, 2001 John Cowan
FIGlet Copyright 2002 Christiaan Keet
+ FIGlet Copyright 2011 Claudio Matsuoka
Portions written by Paul Burton and Christiaan Keet
Internet: <info@figlet.org>
FIGlet, along with the various FIGlet fonts and documentation, is
- copyrighted under the provisions of the Academic Free License
+ copyrighted under the provisions of the New BSD License (3-clause)
(as listed in the file "LICENSE" which is included in this package)
****************************************************************************/
-#define DATE "05 July 2005"
-#define VERSION "2.2.2"
-#define VERSION_INT 20202
+#define DATE "12 January 2011"
+#define VERSION "2.2.3"
+#define VERSION_INT 20203
/* FIGlet (Frank, Ian & Glenn's Letters) */
/* by Glenn Chappell */
@@ -36,6 +37,7 @@
http://www.figlet.org/ */
/* Release 2.2.2 by Christiaan Keet: License changed from "Artistic License"
to "Academic Free License" as agreed by FIGlet authors. 05 July 2005 */
+/* Release 2.2.3 by Claudio Matsuoka, 12 January 2011 */
/*---------------------------------------------------------------------------
DEFAULTFONTDIR and DEFAULTFONTFILE should be defined in the Makefile.
@@ -62,6 +64,7 @@
#include <fcntl.h> /* Needed for get_columns */
#ifdef unix
+#include <unistd.h>
#include <sys/ioctl.h> /* Needed for get_columns */
#endif
@@ -655,7 +658,7 @@ char *controlname;
inchr firstch,lastch;
char dashcheck;
inchr offset;
- char *controlpath,magicnum[5];
+ char *controlpath;
int command;
ZFILE *controlfile;
int namelen;
@@ -1423,7 +1426,7 @@ int smushamt()
int addchar(c)
inchr c;
{
- int smushamount,row,k;
+ int smushamount,row,k,column,offset;
char *templine;
getletter(c);
@@ -1433,6 +1436,7 @@ inchr c;
return 0;
}
+ offset = 0;
templine = (char*)myalloc(sizeof(char)*(outlinelenlimit+1));
for (row=0;row<charheight;row++) {
if (right2left) {
@@ -1446,8 +1450,13 @@ inchr c;
}
else {
for (k=0;k<smushamount;k++) {
- outputline[row][outlinelen-smushamount+k] =
- smushem(outputline[row][outlinelen-smushamount+k],currchar[row][k]);
+ column = outlinelen-smushamount+k;
+ if (column < 0) {
+ offset = -column;
+ column = 0;
+ }
+ outputline[row][column] =
+ smushem(outputline[row][column],currchar[row][k + offset]);
}
strcat(outputline[row],currchar[row]+smushamount);
}
@@ -1532,6 +1541,7 @@ void splitline()
part1 = (inchr*)myalloc(sizeof(inchr)*(inchrlinelen+1));
part2 = (inchr*)myalloc(sizeof(inchr)*(inchrlinelen+1));
gotspace = 0;
+ lastspace = inchrlinelen-1;
for (i=inchrlinelen-1;i>=0;i--) {
if (!gotspace && inchrline[i]==' ') {
gotspace = 1;
@@ -1605,7 +1615,7 @@ inchr c;
int Agetchar()
{
extern int optind; /* current argv[] element under study */
- static AgetMode = 0; /* >= 0 for displacement into argv[n], <0 EOF */
+ static int AgetMode = 0; /* >= 0 for displacement into argv[n], <0 EOF */
char *arg; /* pointer to active character */
int c; /* current character */
@@ -1657,12 +1667,12 @@ inchr iso2022()
if (ch == 27) ch = Agetchar() + 0x100; /* ESC x */
if (ch == 0x100 + '$') ch = Agetchar() + 0x200; /* ESC $ x */
switch (ch) {
- case 14: /* invoke G0 into GL */
- gl = 0;
- return iso2022();
- case 15: /* invoke G1 into GL */
+ case 14: /* invoke G1 into GL */
gl = 1;
return iso2022();
+ case 15: /* invoke G0 into GL */
+ gl = 0;
+ return iso2022();
case 142: case 'N' + 0x100: /* invoke G2 into GL for next char */
save_gl = gl; save_gr = gr;
gl = gr = 2;
@@ -2029,5 +2039,5 @@ char *argv[];
if (outlinelen!=0) {
printline();
}
- exit(0);
+ return 0;
}
diff --git a/figlist b/figlist
index 3f629f4..3f629f4 100644..100755
--- a/figlist
+++ b/figlist
diff --git a/figlist.6 b/figlist.6
new file mode 100644
index 0000000..448f812
--- /dev/null
+++ b/figlist.6
@@ -0,0 +1,52 @@
+.\" figlist by Glenn Chappell <ggc@uiuc.edu>
+.\" figlet release 2.1.1 -- 25 Aug 1994
+.\"
+.\" Lists all fonts and control files in figlet's default font directory.
+.\" Replaces "figlet -F", which was removed from figlet version 2.1.
+.\"
+.\" Usage: figlist [ -d directory ]
+.\"
+.\" Manual page by Jonathon Abbott, for the Debian Project
+.\" slightly modified by Francesco Tapparo, for the Debian Project
+.TH FIGLIST 6 "12 January 2011" "v2.2.3"
+
+.SH NAME
+figlist \- lists figlet fonts and control files
+
+.SH SYNOPSIS
+.B figlist
+[
+.B \-d
+.I directory
+]
+
+.SH DESCRIPTION
+Lists all fonts and control files in figlet's default font directory.
+Replaces "figlet -F", which was removed from figlet version 2.1.
+
+.SH EXAMPLES
+To use
+.B figlist
+with its default settings, simply type
+.RS
+
+.B example% figlist
+
+.RE
+
+To list all the font and control files in /usr/share/fonts/figlet
+.RS
+
+.B example% figlist -d /usr/share/fonts/figlet
+
+.RE
+
+.SH AUTHORS
+figlist was written by Glenn Chappell <ggc@uiuc.edu>
+
+This manual page was written by Jonathon Abbott for the Debian Project.
+
+.SH "SEE ALSO"
+.BR figlet (6),
+.BR chkfont (6),
+.BR showfigfonts (6)
diff --git a/figmagic b/figmagic
deleted file mode 100644
index 5e9a01a..0000000
--- a/figmagic
+++ /dev/null
@@ -1,6 +0,0 @@
-# Append this file to your /etc/magic or /usr/share/misc/magic file
-# to enable the ``file'' command to report on FIGlet fonts and controlfiles.
-0 string flf FIGlet font
->3 string >2a version %-2.2s
-0 string flc FIGlet controlfile
->3 string >2a version %-2.2s
diff --git a/fonts/jis0201.flc b/fonts/jis0201.flc
index 87e9e94..6a32e62 100644
--- a/fonts/jis0201.flc
+++ b/fonts/jis0201.flc
@@ -1,202 +1,249 @@
+# JIS X 0201 (1976) mappings for ISO 2022 usage.
+
+# Invoke JIS Roman in G0/GL, and JIS Katakana ("halfwidth" katakana, but
+# we map it to fullwidth for compatibility with existing fonts) in
+# G1/GR.
#
-# Name: JIS X 0201 (1976) to Unicode 1.1 Table
-# Unicode version: 1.1
-# Table version: 0.9
-# Table format: Format A
-# Date: 8 March 1994
-# Authors: Glenn Adams <glenn@metis.com>
-# John H. Jenkins <John_Jenkins@taligent.com>
+# This means that the Katakana is available in the high bytes, or you
+# can use SHIFT OUT (0x1E) to cause the low-value bytes (in the ASCII
+# code value range) to invoke Katakana characters (using SHIFT IN (0x1F)
+# to switch back). Of course, this being ISO 2022, you can also use the
+# escape sequences ESC ( I and ESC ( J to shift it in and out.
+
+g 0 94 J
+g 1 94 I
+g L 0
+g R 1
+
+# JIS Roman: ISO 646 variant just like ASCII, but with <Yen> for
+# <backslash>, and <overline> for <tilde>.
+
+0x4A0020 0x20
+0x4A0021 0x21
+0x4A0022 0x22
+0x4A0023 0x23
+0x4A0024 0x24
+0x4A0025 0x25
+0x4A0026 0x26
+0x4A0027 0x27
+0x4A0028 0x28
+0x4A0029 0x29
+0x4A002A 0x2A
+0x4A002B 0x2B
+0x4A002C 0x2C
+0x4A002D 0x2D
+0x4A002E 0x2E
+0x4A002F 0x2F
+0x4A0030 0x30
+0x4A0031 0x31
+0x4A0032 0x32
+0x4A0033 0x33
+0x4A0034 0x34
+0x4A0035 0x35
+0x4A0036 0x36
+0x4A0037 0x37
+0x4A0038 0x38
+0x4A0039 0x39
+0x4A003A 0x3A
+0x4A003B 0x3B
+0x4A003C 0x3C
+0x4A003D 0x3D
+0x4A003E 0x3E
+0x4A003F 0x3F
+0x4A0040 0x40
+0x4A0041 0x41
+0x4A0042 0x42
+0x4A0043 0x43
+0x4A0044 0x44
+0x4A0045 0x45
+0x4A0046 0x46
+0x4A0047 0x47
+0x4A0048 0x48
+0x4A0049 0x49
+0x4A004A 0x4A
+0x4A004B 0x4B
+0x4A004C 0x4C
+0x4A004D 0x4D
+0x4A004E 0x4E
+0x4A004F 0x4F
+0x4A0050 0x50
+0x4A0051 0x51
+0x4A0052 0x52
+0x4A0053 0x53
+0x4A0054 0x54
+0x4A0055 0x55
+0x4A0056 0x56
+0x4A0057 0x57
+0x4A0058 0x58
+0x4A0059 0x59
+0x4A005A 0x5A
+0x4A005B 0x5B
+0x4A005C 0xA5 # \ -> Yen
+0x4A005D 0x5D
+0x4A005E 0x5E
+0x4A005F 0x5F
+0x4A0060 0x60
+0x4A0061 0x61
+0x4A0062 0x62
+0x4A0063 0x63
+0x4A0064 0x64
+0x4A0065 0x65
+0x4A0066 0x66
+0x4A0067 0x67
+0x4A0068 0x68
+0x4A0069 0x69
+0x4A006A 0x6A
+0x4A006B 0x6B
+0x4A006C 0x6C
+0x4A006D 0x6D
+0x4A006E 0x6E
+0x4A006F 0x6F
+0x4A0070 0x70
+0x4A0071 0x71
+0x4A0072 0x72
+0x4A0073 0x73
+0x4A0074 0x74
+0x4A0075 0x75
+0x4A0076 0x76
+0x4A0077 0x77
+0x4A0078 0x78
+0x4A0079 0x79
+0x4A007A 0x7A
+0x4A007B 0x7B
+0x4A007C 0x7C
+0x4A007D 0x7D
+0x4A007E 0x203E
+
+
+# Mappings for JIS Katakana.
+
+0x490021 0x3002
+0x490022 0x300C
+0x490023 0x300D
+0x490024 0x3001
+0x490025 0x30FB
+0x490026 0x30F2
+0x490027 0x30A1
+0x490028 0x30A3
+0x490029 0x30A5
+0x49002A 0x30A7
+0x49002B 0x30A9
+0x49002C 0x30E3
+0x49002D 0x30E5
+0x49002E 0x30E7
+0x49002F 0x30C3
+0x490030 0x30FC
+0x490031 0x30A2
+0x490032 0x30A4
+0x490033 0x30A6
+0x490034 0x30A8
+0x490035 0x30AA
+0x490036 0x30AB
+0x490037 0x30AD
+0x490038 0x30AF
+0x490039 0x30B1
+0x49003A 0x30B3
+0x49003B 0x30B5
+0x49003C 0x30B7
+0x49003D 0x30B9
+0x49003E 0x30BB
+0x49003F 0x30BD
+0x490040 0x30BF
+0x490041 0x30C1
+0x490042 0x30C4
+0x490043 0x30C6
+0x490044 0x30C8
+0x490045 0x30CA
+0x490046 0x30CB
+0x490047 0x30CC
+0x490048 0x30CD
+0x490049 0x30CE
+0x49004A 0x30CF
+0x49004B 0x30D2
+0x49004C 0x30D5
+0x49004D 0x30D8
+0x49004E 0x30DB
+0x49004F 0x30DE
+0x490050 0x30DF
+0x490051 0x30E0
+0x490052 0x30E1
+0x490053 0x30E2
+0x490054 0x30E4
+0x490055 0x30E6
+0x490056 0x30E8
+0x490057 0x30E9
+0x490058 0x30EA
+0x490059 0x30EB
+0x49005A 0x30EC
+0x49005B 0x30ED
+0x49005C 0x30EF
+0x49005D 0x30F3
+0x49005E 0x309B
+0x49005F 0x309C
+
+# For reference, here's what they'd map to if we were mapping to
+# halfwidth Katakana.
#
-# Copyright (c) 1991-1994 Unicode, Inc. All Rights reserved.
-#
-# This file is provided as-is by Unicode, Inc. (The Unicode Consortium).
-# No claims are made as to fitness for any particular purpose. No
-# warranties of any kind are expressed or implied. The recipient
-# agrees to determine applicability of information provided. If this
-# file has been provided on magnetic media by Unicode, Inc., the sole
-# remedy for any claim will be exchange of defective media within 90
-# days of receipt.
-#
-# Recipient is granted the right to make copies in any form for
-# internal distribution and to freely use the information supplied
-# in the creation of products supporting Unicode. Unicode, Inc.
-# specifically excludes the right to re-distribute this file directly
-# to third parties or other organizations whether for profit or not.
-#
-# General notes:
-#
-# This table contains the data the Unicode Consortium has on how
-# single-byte JIS X 0201 characters map into Unicode 1.1
-# (ISO/IEC 10646:1-1993 UCS-2).
-#
-# Format: Three tab-separated columns
-# Column #1 is the shift JIS code (in hex as 0xXX)
-# Column #2 is the Unicode (in hex as 0xXXXX)
-# Column #3 the Unicode (ISO 10646) name (follows a comment sign)
-#
-# The entries are in JIS order
-#
-# These mappings are provisional, pending definition of
-# official mappings by Japanese standards bodies.
-#
-# Any comments or problems, contact <John_Jenkins@taligent.com>
-#
-#
-0x20 0x0020 # SPACE
-0x21 0x0021 # EXCLAMATION MARK
-0x22 0x0022 # QUOTATION MARK
-0x23 0x0023 # NUMBER SIGN
-0x24 0x0024 # DOLLAR SIGN
-0x25 0x0025 # PERCENT SIGN
-0x26 0x0026 # AMPERSAND
-0x27 0x0027 # APOSTROPHE
-0x28 0x0028 # LEFT PARENTHESIS
-0x29 0x0029 # RIGHT PARENTHESIS
-0x2A 0x002A # ASTERISK
-0x2B 0x002B # PLUS SIGN
-0x2C 0x002C # COMMA
-0x2D 0x002D # HYPHEN-MINUS
-0x2E 0x002E # FULL STOP
-0x2F 0x002F # SOLIDUS
-0x30 0x0030 # DIGIT ZERO
-0x31 0x0031 # DIGIT ONE
-0x32 0x0032 # DIGIT TWO
-0x33 0x0033 # DIGIT THREE
-0x34 0x0034 # DIGIT FOUR
-0x35 0x0035 # DIGIT FIVE
-0x36 0x0036 # DIGIT SIX
-0x37 0x0037 # DIGIT SEVEN
-0x38 0x0038 # DIGIT EIGHT
-0x39 0x0039 # DIGIT NINE
-0x3A 0x003A # COLON
-0x3B 0x003B # SEMICOLON
-0x3C 0x003C # LESS-THAN SIGN
-0x3D 0x003D # EQUALS SIGN
-0x3E 0x003E # GREATER-THAN SIGN
-0x3F 0x003F # QUESTION MARK
-0x40 0x0040 # COMMERCIAL AT
-0x41 0x0041 # LATIN CAPITAL LETTER A
-0x42 0x0042 # LATIN CAPITAL LETTER B
-0x43 0x0043 # LATIN CAPITAL LETTER C
-0x44 0x0044 # LATIN CAPITAL LETTER D
-0x45 0x0045 # LATIN CAPITAL LETTER E
-0x46 0x0046 # LATIN CAPITAL LETTER F
-0x47 0x0047 # LATIN CAPITAL LETTER G
-0x48 0x0048 # LATIN CAPITAL LETTER H
-0x49 0x0049 # LATIN CAPITAL LETTER I
-0x4A 0x004A # LATIN CAPITAL LETTER J
-0x4B 0x004B # LATIN CAPITAL LETTER K
-0x4C 0x004C # LATIN CAPITAL LETTER L
-0x4D 0x004D # LATIN CAPITAL LETTER M
-0x4E 0x004E # LATIN CAPITAL LETTER N
-0x4F 0x004F # LATIN CAPITAL LETTER O
-0x50 0x0050 # LATIN CAPITAL LETTER P
-0x51 0x0051 # LATIN CAPITAL LETTER Q
-0x52 0x0052 # LATIN CAPITAL LETTER R
-0x53 0x0053 # LATIN CAPITAL LETTER S
-0x54 0x0054 # LATIN CAPITAL LETTER T
-0x55 0x0055 # LATIN CAPITAL LETTER U
-0x56 0x0056 # LATIN CAPITAL LETTER V
-0x57 0x0057 # LATIN CAPITAL LETTER W
-0x58 0x0058 # LATIN CAPITAL LETTER X
-0x59 0x0059 # LATIN CAPITAL LETTER Y
-0x5A 0x005A # LATIN CAPITAL LETTER Z
-0x5B 0x005B # LEFT SQUARE BRACKET
-0x5C 0x00A5 # YEN SIGN
-0x5D 0x005D # RIGHT SQUARE BRACKET
-0x5E 0x005E # CIRCUMFLEX ACCENT
-0x5F 0x005F # LOW LINE
-0x60 0x0060 # GRAVE ACCENT
-0x61 0x0061 # LATIN SMALL LETTER A
-0x62 0x0062 # LATIN SMALL LETTER B
-0x63 0x0063 # LATIN SMALL LETTER C
-0x64 0x0064 # LATIN SMALL LETTER D
-0x65 0x0065 # LATIN SMALL LETTER E
-0x66 0x0066 # LATIN SMALL LETTER F
-0x67 0x0067 # LATIN SMALL LETTER G
-0x68 0x0068 # LATIN SMALL LETTER H
-0x69 0x0069 # LATIN SMALL LETTER I
-0x6A 0x006A # LATIN SMALL LETTER J
-0x6B 0x006B # LATIN SMALL LETTER K
-0x6C 0x006C # LATIN SMALL LETTER L
-0x6D 0x006D # LATIN SMALL LETTER M
-0x6E 0x006E # LATIN SMALL LETTER N
-0x6F 0x006F # LATIN SMALL LETTER O
-0x70 0x0070 # LATIN SMALL LETTER P
-0x71 0x0071 # LATIN SMALL LETTER Q
-0x72 0x0072 # LATIN SMALL LETTER R
-0x73 0x0073 # LATIN SMALL LETTER S
-0x74 0x0074 # LATIN SMALL LETTER T
-0x75 0x0075 # LATIN SMALL LETTER U
-0x76 0x0076 # LATIN SMALL LETTER V
-0x77 0x0077 # LATIN SMALL LETTER W
-0x78 0x0078 # LATIN SMALL LETTER X
-0x79 0x0079 # LATIN SMALL LETTER Y
-0x7A 0x007A # LATIN SMALL LETTER Z
-0x7B 0x007B # LEFT CURLY BRACKET
-0x7C 0x007C # VERTICAL LINE
-0x7D 0x007D # RIGHT CURLY BRACKET
-0x7E 0x203E # OVERLINE
-0xA1 0xFF61 # HALFWIDTH IDEOGRAPHIC FULL STOP
-0xA2 0xFF62 # HALFWIDTH LEFT CORNER BRACKET
-0xA3 0xFF63 # HALFWIDTH RIGHT CORNER BRACKET
-0xA4 0xFF64 # HALFWIDTH IDEOGRAPHIC COMMA
-0xA5 0xFF65 # HALFWIDTH KATAKANA MIDDLE DOT
-0xA6 0xFF66 # HALFWIDTH KATAKANA LETTER WO
-0xA7 0xFF67 # HALFWIDTH KATAKANA LETTER SMALL A
-0xA8 0xFF68 # HALFWIDTH KATAKANA LETTER SMALL I
-0xA9 0xFF69 # HALFWIDTH KATAKANA LETTER SMALL U
-0xAA 0xFF6A # HALFWIDTH KATAKANA LETTER SMALL E
-0xAB 0xFF6B # HALFWIDTH KATAKANA LETTER SMALL O
-0xAC 0xFF6C # HALFWIDTH KATAKANA LETTER SMALL YA
-0xAD 0xFF6D # HALFWIDTH KATAKANA LETTER SMALL YU
-0xAE 0xFF6E # HALFWIDTH KATAKANA LETTER SMALL YO
-0xAF 0xFF6F # HALFWIDTH KATAKANA LETTER SMALL TU
-0xB0 0xFF70 # HALFWIDTH KATAKANA-HIRAGANA PROLONGED SOUND MARK
-0xB1 0xFF71 # HALFWIDTH KATAKANA LETTER A
-0xB2 0xFF72 # HALFWIDTH KATAKANA LETTER I
-0xB3 0xFF73 # HALFWIDTH KATAKANA LETTER U
-0xB4 0xFF74 # HALFWIDTH KATAKANA LETTER E
-0xB5 0xFF75 # HALFWIDTH KATAKANA LETTER O
-0xB6 0xFF76 # HALFWIDTH KATAKANA LETTER KA
-0xB7 0xFF77 # HALFWIDTH KATAKANA LETTER KI
-0xB8 0xFF78 # HALFWIDTH KATAKANA LETTER KU
-0xB9 0xFF79 # HALFWIDTH KATAKANA LETTER KE
-0xBA 0xFF7A # HALFWIDTH KATAKANA LETTER KO
-0xBB 0xFF7B # HALFWIDTH KATAKANA LETTER SA
-0xBC 0xFF7C # HALFWIDTH KATAKANA LETTER SI
-0xBD 0xFF7D # HALFWIDTH KATAKANA LETTER SU
-0xBE 0xFF7E # HALFWIDTH KATAKANA LETTER SE
-0xBF 0xFF7F # HALFWIDTH KATAKANA LETTER SO
-0xC0 0xFF80 # HALFWIDTH KATAKANA LETTER TA
-0xC1 0xFF81 # HALFWIDTH KATAKANA LETTER TI
-0xC2 0xFF82 # HALFWIDTH KATAKANA LETTER TU
-0xC3 0xFF83 # HALFWIDTH KATAKANA LETTER TE
-0xC4 0xFF84 # HALFWIDTH KATAKANA LETTER TO
-0xC5 0xFF85 # HALFWIDTH KATAKANA LETTER NA
-0xC6 0xFF86 # HALFWIDTH KATAKANA LETTER NI
-0xC7 0xFF87 # HALFWIDTH KATAKANA LETTER NU
-0xC8 0xFF88 # HALFWIDTH KATAKANA LETTER NE
-0xC9 0xFF89 # HALFWIDTH KATAKANA LETTER NO
-0xCA 0xFF8A # HALFWIDTH KATAKANA LETTER HA
-0xCB 0xFF8B # HALFWIDTH KATAKANA LETTER HI
-0xCC 0xFF8C # HALFWIDTH KATAKANA LETTER HU
-0xCD 0xFF8D # HALFWIDTH KATAKANA LETTER HE
-0xCE 0xFF8E # HALFWIDTH KATAKANA LETTER HO
-0xCF 0xFF8F # HALFWIDTH KATAKANA LETTER MA
-0xD0 0xFF90 # HALFWIDTH KATAKANA LETTER MI
-0xD1 0xFF91 # HALFWIDTH KATAKANA LETTER MU
-0xD2 0xFF92 # HALFWIDTH KATAKANA LETTER ME
-0xD3 0xFF93 # HALFWIDTH KATAKANA LETTER MO
-0xD4 0xFF94 # HALFWIDTH KATAKANA LETTER YA
-0xD5 0xFF95 # HALFWIDTH KATAKANA LETTER YU
-0xD6 0xFF96 # HALFWIDTH KATAKANA LETTER YO
-0xD7 0xFF97 # HALFWIDTH KATAKANA LETTER RA
-0xD8 0xFF98 # HALFWIDTH KATAKANA LETTER RI
-0xD9 0xFF99 # HALFWIDTH KATAKANA LETTER RU
-0xDA 0xFF9A # HALFWIDTH KATAKANA LETTER RE
-0xDB 0xFF9B # HALFWIDTH KATAKANA LETTER RO
-0xDC 0xFF9C # HALFWIDTH KATAKANA LETTER WA
-0xDD 0xFF9D # HALFWIDTH KATAKANA LETTER N
-0xDE 0xFF9E # HALFWIDTH KATAKANA VOICED SOUND MARK
-0xDF 0xFF9F # HALFWIDTH KATAKANA SEMI-VOICED SOUND MARK
+# 0x490021 0xFF61
+# 0x490022 0xFF62
+# 0x490023 0xFF63
+# 0x490024 0xFF64
+# 0x490025 0xFF65
+# 0x490026 0xFF66
+# 0x490027 0xFF67
+# 0x490028 0xFF68
+# 0x490029 0xFF69
+# 0x49002A 0xFF6A
+# 0x49002B 0xFF6B
+# 0x49002C 0xFF6C
+# 0x49002D 0xFF6D
+# 0x49002E 0xFF6E
+# 0x49002F 0xFF6F
+# 0x490030 0xFF70
+# 0x490031 0xFF71
+# 0x490032 0xFF72
+# 0x490033 0xFF73
+# 0x490034 0xFF74
+# 0x490035 0xFF75
+# 0x490036 0xFF76
+# 0x490037 0xFF77
+# 0x490038 0xFF78
+# 0x490039 0xFF79
+# 0x49003A 0xFF7A
+# 0x49003B 0xFF7B
+# 0x49003C 0xFF7C
+# 0x49003D 0xFF7D
+# 0x49003E 0xFF7E
+# 0x49003F 0xFF7F
+# 0x490040 0xFF80
+# 0x490041 0xFF81
+# 0x490042 0xFF82
+# 0x490043 0xFF83
+# 0x490044 0xFF84
+# 0x490045 0xFF85
+# 0x490046 0xFF86
+# 0x490047 0xFF87
+# 0x490048 0xFF88
+# 0x490049 0xFF89
+# 0x49004A 0xFF8A
+# 0x49004B 0xFF8B
+# 0x49004C 0xFF8C
+# 0x49004D 0xFF8D
+# 0x49004E 0xFF8E
+# 0x49004F 0xFF8F
+# 0x490050 0xFF90
+# 0x490051 0xFF91
+# 0x490052 0xFF92
+# 0x490053 0xFF93
+# 0x490054 0xFF94
+# 0x490055 0xFF95
+# 0x490056 0xFF96
+# 0x490057 0xFF97
+# 0x490058 0xFF98
+# 0x490059 0xFF99
+# 0x49005A 0xFF9A
+# 0x49005B 0xFF9B
+# 0x49005C 0xFF9C
+# 0x49005D 0xFF9D
+# 0x49005E 0xFF9E
+# 0x49005F 0xFF9F
diff --git a/getopt.c b/getopt.c
deleted file mode 100644
index 4218991..0000000
--- a/getopt.c
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * * @(#)getopt.c 2.3 (smail) 5/30/87
- */
-
-/*
- * Here's something you've all been waiting for: the AT&T public domain
- * source for getopt(3). It is the code which was given out at the 1985
- * UNIFORUM conference in Dallas. I obtained it by electronic mail directly
- * from AT&T. The people there assure me that it is indeed in the public
- * domain.
- *
- * There is no manual page. That is because the one they gave out at UNIFORUM
- * was slightly different from the current System V Release 2 manual page.
- * The difference apparently involved a note about the famous rules 5 and 6,
- * recommending using white space between an option and its first argument,
- * and not grouping options that have arguments. Getopt itself is currently
- * lenient about both of these things White space is allowed, but not
- * mandatory, and the last option in a group can have an argument. That
- * particular version of the man page evidently has no official existence,
- * and my source at AT&T did not send a copy. The current SVR2 man page
- * reflects the actual behavior of this getopt. However, I am not about to
- * post a copy of anything licensed by AT&T.
- */
-
-#ifdef BSD
- #include <strings.h>
-#else
- #define index strchr
- #include <string.h>
-#endif
-
-/* LINTLIBRARY */
-#ifndef NULL
-#define NULL 0
-#endif
-
-#define EOF (-1)
-#define ERR(s, c) if(opterr){\
- extern int write(int, void *, unsigned);\
- char errbuf[2];\
- errbuf[0] = (char)c; errbuf[1] = '\n';\
- (void) write(2, strlwr(argv[0]), (unsigned)strlen(argv[0]));\
- (void) write(2, s, (unsigned)strlen(s));\
- (void) write(2, errbuf, 2);}
-
-extern char *index();
-
-int opterr = 1;
-int optind = 1;
-int optopt;
-char *optarg;
-
-int getopt(int argc, char *argv[], char *opts)
-{
- static int sp = 1;
- register int c;
- register char *cp;
-
- if (sp == 1)
- {
- if (optind >= argc || argv[optind][0] != '-' ||
- argv[optind][1] == '\0')
- return (EOF);
- else if (strcmp(argv[optind], "--") == 0)
- {
- optind++;
- return (EOF);
- }
- }
- optopt = c = argv[optind][sp];
- if (c == ':' || (cp = index(opts, c)) == NULL)
- {
- ERR(": illegal option -- ", c);
- if (argv[optind][++sp] == '\0')
- {
- optind++;
- sp = 1;
- }
- return ('?');
- }
- if (*++cp == ':')
- {
- if (argv[optind][sp + 1] != '\0')
- optarg = &argv[optind++][sp + 1];
- else if (++optind >= argc)
- {
- ERR(": option requires an argument -- ", c);
- sp = 1;
- return ('?');
- }
- else optarg = argv[optind++];
- sp = 1;
- }
- else
- {
- if (argv[optind][++sp] == '\0')
- {
- sp = 1;
- optind++;
- }
- optarg = NULL;
- }
- return (c);
-}
diff --git a/inflate.c b/inflate.c
index e2c5dbe..06cef44 100644
--- a/inflate.c
+++ b/inflate.c
@@ -1,32 +1,35 @@
/*
* inflate.c - inflate decompression routine
*
- * Version 1.1
+ * Version 1.1.2
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
+ * Copyright (C) 1995, Edward B. Hamrick
*
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
*
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+/*
+ * Changes from 1.1 to 1.1.2:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Claudio Matsuoka (Jan 11 2011)
*/
/*
diff --git a/inflate.h b/inflate.h
index 93568ee..4fc7454 100644
--- a/inflate.h
+++ b/inflate.h
@@ -1,32 +1,35 @@
/*
* inflate.h - inflate decompression routine
*
- * Version 1.1
+ * Version 1.1.2
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
+ * Copyright (C) 1995, Edward B. Hamrick
*
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
*
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
+ */
+
+/*
+ * Changes from 1.1 to 1.1.2:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Claudio Matsuoka (Jan 11 2011)
*/
/*
diff --git a/showfigfonts b/showfigfonts
index 643c60b..643c60b 100644..100755
--- a/showfigfonts
+++ b/showfigfonts
diff --git a/showfigfonts.6 b/showfigfonts.6
new file mode 100644
index 0000000..6ac7cd1
--- /dev/null
+++ b/showfigfonts.6
@@ -0,0 +1,67 @@
+.\" showfigfonts by Glenn Chappell <ggc@uiuc.edu>
+.\" figlet release 2.1.1 -- 25 Aug 1994
+.\" Based on showfigfonts by Greg Galperin <grg@ai.mit.edu>, Nov 1993.
+.\"
+.\" Prints a list of available figlet fonts, along with a sample of each
+.\" font. If directory is given, lists fonts in that directory; otherwise
+.\" uses the default font directory. If word is given, prints that word
+.\" in each font; otherwise prints the font name.
+.\"
+.\" Usage: showfigfonts [ -d directory ] [ word ]
+.\"
+.\" Manual page by Jonathon Abbott, for the Debian Project
+.\" slightly modified by Francesco Tapparo, for the Debian Project
+.TH SHOWFIGFONTS 6 "12 January 2011" "v2.2.3"
+
+.SH NAME
+showfigfonts \- prints a list of available figlet fonts
+
+.SH SYNOPSIS
+.B showfigfonts
+[
+.B \-d
+.I directory
+]
+[
+.I word
+]
+
+.SH "DESCRIPTION"
+Prints a list of available figlet fonts, along with a sample of each
+font. If directory is given, lists fonts in that directory; otherwise
+uses the default font directory. If word is given, prints that word
+in each font; otherwise prints the font name.
+
+.SH EXAMPLES
+To use
+.B showfigfonts
+with its default settings, simply type
+.RS
+
+.B example% showfigfonts
+
+.RE
+
+To print all the fonts in /usr/share/fonts/figlet
+.RS
+
+.B example% showfigfonts -d /usr/share/fonts/figlet
+
+.RE
+
+To print the word foo using all available fonts
+.RS
+
+.B example% showfigfonts foo
+
+.RE
+
+.SH "AUTHORS"
+showfigfonts was written by Glenn Chappell <ggc@uiuc.edu>
+
+This manual page was written by Jonathon Abbott for the Debian Project.
+
+.SH "SEE ALSO"
+.BR figlet (6),
+.BR chkfont (6),
+.BR figlist (6)
diff --git a/zipio.c b/zipio.c
index 6ed67e0..f7406d9 100644
--- a/zipio.c
+++ b/zipio.c
@@ -1,32 +1,29 @@
/*
* zipio.c - stdio emulation library for reading zip files
*
- * Version 1.1.1
+ * Version 1.1.2
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
+ * Copyright (C) 1995, Edward B. Hamrick
*
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
*
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
*/
/*
@@ -35,6 +32,11 @@
* Added "zungetc" macro.
* Added definitions of SEEK_SET, SEEK_CUR, SEEK_END for the Posixly challenged
* John Cowan <cowan@ccil.org>
+ *
+ * Changes from 1.1.1 to 1.1.2:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Avoid usage of unitialized "length" variable in _Zgetc
+ * Claudio Matsuoka (Jan 11 2011)
*/
/*
@@ -680,11 +682,11 @@ int _Zgetc(ZFILE *stream)
/* If data isn't in current outbuf, get it */
offset = ZS->fileposition & ~((long) (OUTBUFSIZE-1));
+ length = ZS->usiz - offset;
+ if (length > OUTBUFSIZE) length = OUTBUFSIZE;
+
if (ZS->getoff != offset)
{
- length = ZS->usiz - offset;
- if (length > OUTBUFSIZE) length = OUTBUFSIZE;
-
if (BufferRead(ZS, offset, ZS->getbuf, length)) return -1;
ZS->getoff = offset;
diff --git a/zipio.h b/zipio.h
index 1b6557b..12289d6 100644
--- a/zipio.h
+++ b/zipio.h
@@ -1,32 +1,29 @@
/*
* zipio.h - stdio emulation library for reading zip files
*
- * Version 1.1.1
+ * Version 1.1.2
*/
/*
- * Copyright (c) 1995, Edward B. Hamrick
+ * Copyright (C) 1995, Edward B. Hamrick
*
- * Permission to use, copy, modify, distribute, and sell this software and
- * its documentation for any purpose is hereby granted without fee, provided
- * that
+ * Permission to use, copy, modify, and distribute this software and
+ * its documentation for any purpose and without fee is hereby granted,
+ * provided that the above copyright notice appear in all copies and
+ * that both that copyright notice and this permission notice appear in
+ * supporting documentation, and that the name of the copyright holders
+ * not be used in advertising or publicity pertaining to distribution of
+ * the software without specific, written prior permission. The copyright
+ * holders makes no representations about the suitability of this software
+ * for any purpose. It is provided "as is" without express or implied warranty.
*
- * (i) the above copyright notice and the text in this "C" comment block
- * appear in all copies of the software and related documentation, and
- *
- * (ii) any modifications to this source file must be sent, via e-mail
- * to the copyright owner (currently hamrick@primenet.com) within
- * 30 days of such modification.
- *
- * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
- * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
- *
- * IN NO EVENT SHALL EDWARD B. HAMRICK BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
- * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES WHATSOEVER
- * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR NOT ADVISED OF
- * THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF LIABILITY, ARISING OUT OF
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
+ * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS,
+ * IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT
+ * OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
+ * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+ * OF THIS SOFTWARE.
*/
/*
@@ -34,6 +31,10 @@
* Changed "z*" functions to "Z*" to avoid namespace pollution.
* Added "zungetc" macro.
* John Cowan <cowan@ccil.org>
+ *
+ * Changes from 1.1.1 to 1.1.2:
+ * Relicensed under the MIT license, with consent of the copyright holders.
+ * Claudio Matsuoka (Jan 11 2011)
*/
/*