summaryrefslogtreecommitdiff
path: root/usr.bin/banner
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2017-05-27 07:55:45 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2017-05-27 07:55:45 +0000
commit01f8a255dfdcd9dbfc2b287ed13ad786a4d2d88a (patch)
treeaa995d4a76785847611422ae76cdf22d1aaa033c /usr.bin/banner
parentee9a45a4fbadf21ec88cd0e647587d0e2874c6c4 (diff)
trim some unused compile options for alternative character forms.
Diffstat (limited to 'usr.bin/banner')
-rw-r--r--usr.bin/banner/Makefile11
-rw-r--r--usr.bin/banner/banner.c7
-rw-r--r--usr.bin/banner/banner.h7
-rw-r--r--usr.bin/banner/chset.c965
4 files changed, 4 insertions, 986 deletions
diff --git a/usr.bin/banner/Makefile b/usr.bin/banner/Makefile
index c857d8ab904..f28cf2cfd7a 100644
--- a/usr.bin/banner/Makefile
+++ b/usr.bin/banner/Makefile
@@ -1,16 +1,7 @@
-# $OpenBSD: Makefile,v 1.4 2014/07/16 20:06:27 okan Exp $
+# $OpenBSD: Makefile,v 1.5 2017/05/27 07:55:44 tedu Exp $
PROG= banner
SRCS= $(PROG).c chset.c
-# if you want to make chars from the letter involved (like lpd), then
-# un-comment the following.
-#CFLAGS+= -DNOHASH_ONLY
-
-# if you want to use the same char set that lpd uses then un-comment
-# the following. Lpd uses a much nicer character set but banner
-# output will not be the same as the real thing.
-#CFLAGS+= -DLPD_CHSET
-
.include <bsd.prog.mk>
diff --git a/usr.bin/banner/banner.c b/usr.bin/banner/banner.c
index f3e1da32414..c2b4780c46a 100644
--- a/usr.bin/banner/banner.c
+++ b/usr.bin/banner/banner.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: banner.c,v 1.12 2015/11/03 04:54:07 mmcc Exp $ */
+/* $OpenBSD: banner.c,v 1.13 2017/05/27 07:55:44 tedu Exp $ */
/* $NetBSD: banner.c,v 1.2 1995/04/09 06:00:15 cgd Exp $ */
/*
@@ -71,9 +71,7 @@ scnline(int key, char *p, int c)
* the results are somewhat mixed. Sticking to '#' as
* banner(1) does is more consistent.
*/
-#ifndef NOHASH_ONLY
c = '#';
-#endif
for (scnwidth = WIDTH; --scnwidth;) {
key <<= 1;
@@ -133,9 +131,6 @@ scan_out(int scfd, char *scsp, int dlm)
if (nchrs++ >= PW/(WIDTH+1)-1)
break;
*strp++ = BACKGND;
-#ifdef LPD_CHSET /* <sjg> */
- *strp++ = BACKGND;
-#endif
}
while (*--strp == BACKGND && strp >= outbuf)
;
diff --git a/usr.bin/banner/banner.h b/usr.bin/banner/banner.h
index 71398172305..e30593e994d 100644
--- a/usr.bin/banner/banner.h
+++ b/usr.bin/banner/banner.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: banner.h,v 1.3 2003/03/13 23:11:16 tedu Exp $ */
+/* $OpenBSD: banner.h,v 1.4 2017/05/27 07:55:44 tedu Exp $ */
/* $NetBSD: banner.h,v 1.2 1995/04/09 06:00:23 cgd Exp $ */
/*
@@ -24,12 +24,7 @@
#define BACKGND ' '
#define INVALID '_'
-#ifdef LPD_CHSET
-#define HEIGHT 9 /* height of characters */
-#define DROP 3 /* offset to drop characters with descenders */
-#else
#define HEIGHT 8 /* height of characters */
#define DROP 0 /* offset to drop characters with descenders */
-#endif
#define WIDTH 8 /* width of characters */
diff --git a/usr.bin/banner/chset.c b/usr.bin/banner/chset.c
index 13881b003ce..63b4ef798c6 100644
--- a/usr.bin/banner/chset.c
+++ b/usr.bin/banner/chset.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: chset.c,v 1.5 2009/10/27 23:59:35 deraadt Exp $ */
+/* $OpenBSD: chset.c,v 1.6 2017/05/27 07:55:44 tedu Exp $ */
/* $NetBSD: chset.c,v 1.2 1995/04/09 06:00:26 cgd Exp $ */
/*
@@ -187,968 +187,6 @@
char scnkey[][HEIGHT] = /* this is relatively easy to modify */
/* just look: */
{
-#ifdef LPD_CHSET /* <sjg> */
- { c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______ }, /* */
-
- { c__11___,
- c__11___,
- c__11___,
- c__11___,
- c__11___,
- c_______,
- c_______,
- c__11___,
- c__11___ }, /* ! */
-
- { c_1__1__,
- c_1__1__,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______ }, /* " */
-
- { c_______,
- c__1_1__,
- c__1_1__,
- c1111111,
- c__1_1__,
- c1111111,
- c__1_1__,
- c__1_1__,
- c_______ }, /* # */
-
- { c___1___,
- c_11111_,
- c1__1__1,
- c1__1___,
- c_11111_,
- c___1__1,
- c1__1__1,
- c_11111_,
- c___1___ }, /* $ */
-
- { c_1_____,
- c1_1___1,
- c_1___1_,
- c____1__,
- c___1___,
- c__1____,
- c_1___1_,
- c1___1_1,
- c_____1_ }, /* % */
-
- { c_11____,
- c1__1___,
- c1___1__,
- c_1_1___,
- c__1____,
- c_1_1__1,
- c1___11_,
- c1___11_,
- c_111__1 }, /* & */
-
- { c___11__,
- c___11__,
- c___1___,
- c__1____,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______ }, /* ' */
-
- { c____1__,
- c___1___,
- c__1____,
- c__1____,
- c__1____,
- c__1____,
- c__1____,
- c___1___,
- c____1__ }, /* ( */
-
- { c__1____,
- c___1___,
- c____1__,
- c____1__,
- c____1__,
- c____1__,
- c____1__,
- c___1___,
- c__1____ }, /* ) */
-
- { c_______,
- c___1___,
- c1__1__1,
- c_1_1_1_,
- c__111__,
- c_1_1_1_,
- c1__1__1,
- c___1___,
- c_______ }, /* * */
-
- { c_______,
- c___1___,
- c___1___,
- c___1___,
- c1111111,
- c___1___,
- c___1___,
- c___1___,
- c_______ }, /* + */
-
- { c_______,
- c_______,
- c_______,
- c_______,
- c__11___,
- c__11___,
- c__1____,
- c_1_____,
- c_______ }, /* , */
-
- { c_______,
- c_______,
- c_______,
- c_______,
- c1111111,
- c_______,
- c_______,
- c_______,
- c_______ }, /* - */
-
- { c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c__11___,
- c__11___ }, /* . */
-
- { c_______,
- c______1,
- c_____1_,
- c____1__,
- c___1___,
- c__1____,
- c_1_____,
- c1______,
- c_______ }, /* / */
-
- { c_11111_,
- c1_____1,
- c1____11,
- c1___1_1,
- c1__1__1,
- c1_1___1,
- c11____1,
- c1_____1,
- c_11111_ }, /* 0 */
-
- { c___1___,
- c__11___,
- c_1_1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c_11111_ }, /* 1 */
-
- { c_11111_,
- c1_____1,
- c______1,
- c_____1_,
- c__111__,
- c_1_____,
- c1______,
- c1______,
- c1111111 }, /* 2 */
-
- { c_11111_,
- c1_____1,
- c______1,
- c______1,
- c__1111_,
- c______1,
- c______1,
- c1_____1,
- c_11111_ }, /* 3 */
-
- { c_____1_,
- c____11_,
- c___1_1_,
- c__1__1_,
- c_1___1_,
- c1____1_,
- c1111111,
- c_____1_,
- c_____1_ }, /* 4 */
-
- { c1111111,
- c1______,
- c1______,
- c11111__,
- c_____1_,
- c______1,
- c______1,
- c1____1_,
- c_1111__ }, /* 5 */
-
- { c__1111_,
- c_1_____,
- c1______,
- c1______,
- c1_1111_,
- c11____1,
- c1_____1,
- c1_____1,
- c_11111_ }, /* 6 */
-
- { c1111111,
- c1_____1,
- c_____1_,
- c____1__,
- c___1___,
- c__1____,
- c__1____,
- c__1____,
- c__1____ }, /* 7 */
-
- { c_11111_,
- c1_____1,
- c1_____1,
- c1_____1,
- c_11111_,
- c1_____1,
- c1_____1,
- c1_____1,
- c_11111_ }, /* 8 */
-
- { c_11111_,
- c1_____1,
- c1_____1,
- c1_____1,
- c_111111,
- c______1,
- c______1,
- c1_____1,
- c_1111__ }, /* 9 */
-
- { c_______,
- c_______,
- c_______,
- c__11___,
- c__11___,
- c_______,
- c_______,
- c__11___,
- c__11___ }, /* : */
-
-
- { c__11___,
- c__11___,
- c_______,
- c_______,
- c__11___,
- c__11___,
- c__1____,
- c_1_____,
- c_______ }, /* ; */
-
- { c____1__,
- c___1___,
- c__1____,
- c_1_____,
- c1______,
- c_1_____,
- c__1____,
- c___1___,
- c____1__ }, /* < */
-
- { c_______,
- c_______,
- c_______,
- c1111111,
- c_______,
- c1111111,
- c_______,
- c_______,
- c_______ }, /* = */
-
- { c__1____,
- c___1___,
- c____1__,
- c_____1_,
- c______1,
- c_____1_,
- c____1__,
- c___1___,
- c__1____ }, /* > */
-
- { c__1111_,
- c_1____1,
- c_1____1,
- c______1,
- c____11_,
- c___1___,
- c___1___,
- c_______,
- c___1___ }, /* ? */
-
- { c__1111_,
- c_1____1,
- c1__11_1,
- c1_1_1_1,
- c1_1_1_1,
- c1_1111_,
- c1______,
- c_1____1,
- c__1111_ }, /* @ */
-
- { c__111__,
- c_1___1_,
- c1_____1,
- c1_____1,
- c1111111,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1 }, /* A */
-
- { c111111_,
- c_1____1,
- c_1____1,
- c_1____1,
- c_11111_,
- c_1____1,
- c_1____1,
- c_1____1,
- c111111_ }, /* B */
-
- { c__1111_,
- c_1____1,
- c1______,
- c1______,
- c1______,
- c1______,
- c1______,
- c_1____1,
- c__1111_ }, /* C */
-
- { c11111__,
- c_1___1_,
- c_1____1,
- c_1____1,
- c_1____1,
- c_1____1,
- c_1____1,
- c_1___1_,
- c11111__ }, /* D */
-
- { c1111111,
- c1______,
- c1______,
- c1______,
- c111111_,
- c1______,
- c1______,
- c1______,
- c1111111 }, /* E */
-
- { c1111111,
- c1______,
- c1______,
- c1______,
- c111111_,
- c1______,
- c1______,
- c1______,
- c1______ }, /* F */
-
- { c__1111_,
- c_1____1,
- c1______,
- c1______,
- c1______,
- c1__1111,
- c1_____1,
- c_1____1,
- c__1111_ }, /* G */
-
- { c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1111111,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1 }, /* H */
-
- { c_11111_,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c_11111_ }, /* I */
-
- { c__11111,
- c____1__,
- c____1__,
- c____1__,
- c____1__,
- c____1__,
- c____1__,
- c1___1__,
- c_111___ }, /* J */
-
- { c1_____1,
- c1____1_,
- c1___1__,
- c1__1___,
- c1_1____,
- c11_1___,
- c1___1__,
- c1____1_,
- c1_____1 }, /* K */
-
- { c1______,
- c1______,
- c1______,
- c1______,
- c1______,
- c1______,
- c1______,
- c1______,
- c1111111 }, /* L */
-
- { c1_____1,
- c11___11,
- c1_1_1_1,
- c1__1__1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1 }, /* M */
-
- { c1_____1,
- c11____1,
- c1_1___1,
- c1__1__1,
- c1___1_1,
- c1____11,
- c1_____1,
- c1_____1,
- c1_____1 }, /* N */
-
- { c__111__,
- c_1___1_,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c_1___1_,
- c__111__ }, /* O */
-
- { c111111_,
- c1_____1,
- c1_____1,
- c1_____1,
- c111111_,
- c1______,
- c1______,
- c1______,
- c1______ }, /* P */
-
- { c__111__,
- c_1___1_,
- c1_____1,
- c1_____1,
- c1_____1,
- c1__1__1,
- c1___1_1,
- c_1___1_,
- c__111_1 }, /* Q */
-
- { c111111_,
- c1_____1,
- c1_____1,
- c1_____1,
- c111111_,
- c1__1___,
- c1___1__,
- c1____1_,
- c1_____1 }, /* R */
-
- { c_11111_,
- c1_____1,
- c1______,
- c1______,
- c_11111_,
- c______1,
- c______1,
- c1_____1,
- c_11111_ }, /* S */
-
- { c1111111,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___ }, /* T */
-
- { c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c_11111_ }, /* U */
-
- { c1_____1,
- c1_____1,
- c1_____1,
- c_1___1_,
- c_1___1_,
- c__1_1__,
- c__1_1__,
- c___1___,
- c___1___ }, /* V */
-
- { c1_____1,
- c1_____1,
- c1_____1,
- c1_____1,
- c1__1__1,
- c1__1__1,
- c1_1_1_1,
- c11___11,
- c1_____1 }, /* W */
-
- { c1_____1,
- c1_____1,
- c_1___1_,
- c__1_1__,
- c___1___,
- c__1_1__,
- c_1___1_,
- c1_____1,
- c1_____1 }, /* X */
-
- { c1_____1,
- c1_____1,
- c_1___1_,
- c__1_1__,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___ }, /* Y */
-
- { c1111111,
- c______1,
- c_____1_,
- c____1__,
- c___1___,
- c__1____,
- c_1_____,
- c1______,
- c1111111 }, /* Z */
-
- { c_1111__,
- c_1_____,
- c_1_____,
- c_1_____,
- c_1_____,
- c_1_____,
- c_1_____,
- c_1_____,
- c_1111__ }, /* [ */
-
- { c_______,
- c1______,
- c_1_____,
- c__1____,
- c___1___,
- c____1__,
- c_____1_,
- c______1,
- c_______ }, /* \ */
-
- { c__1111_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c__1111_ }, /* ] */
-
- { c___1___,
- c__1_1__,
- c_1___1_,
- c1_____1,
- c_______,
- c_______,
- c_______,
- c_______ }, /* ^ */
-
- { c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c1111111,
- c_______ }, /* _ */
-
- { c__11___,
- c__11___,
- c___1___,
- c____1__,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______ }, /* ` */
-
- { c_______,
- c_______,
- c_______,
- c_1111__,
- c_____1_,
- c_11111_,
- c1_____1,
- c1____11,
- c_1111_1 }, /* a */
-
- { c1______,
- c1______,
- c1______,
- c1_111__,
- c11___1_,
- c1_____1,
- c1_____1,
- c11___1_,
- c1_111__ }, /* b */
-
- { c_______,
- c_______,
- c_______,
- c_1111__,
- c1____1_,
- c1______,
- c1______,
- c1____1_,
- c_1111__ }, /* c */
-
- { c_____1_,
- c_____1_,
- c_____1_,
- c_111_1_,
- c1___11_,
- c1____1_,
- c1____1_,
- c1___11_,
- c_111_1_ }, /* d */
-
- { c_______,
- c_______,
- c_______,
- c_1111__,
- c1____1_,
- c111111_,
- c1______,
- c1____1_,
- c_1111__ }, /* e */
-
- { c___11__,
- c__1__1_,
- c__1____,
- c__1____,
- c11111__,
- c__1____,
- c__1____,
- c__1____,
- c__1____ }, /* f */
-
- { c_111_1_,
- c1___11_,
- c1____1_,
- c1____1_,
- c1___11_,
- c_111_1_,
- c_____1_,
- c1____1_,
- c_1111__ }, /* g */
-
- { c1______,
- c1______,
- c1______,
- c1_111__,
- c11___1_,
- c1____1_,
- c1____1_,
- c1____1_,
- c1____1_ }, /* h */
-
- { c_______,
- c___1___,
- c_______,
- c__11___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c__111__ }, /* i */
-
- { c____11_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_____1_,
- c_1___1_,
- c__111__ }, /* j */
-
- { c1______,
- c1______,
- c1______,
- c1___1__,
- c1__1___,
- c1_1____,
- c11_1___,
- c1___1__,
- c1____1_ }, /* k */
-
- { c__11___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c__111__ }, /* l */
-
- { c_______,
- c_______,
- c_______,
- c1_1_11_,
- c11_1__1,
- c1__1__1,
- c1__1__1,
- c1__1__1,
- c1__1__1 }, /* m */
-
- { c_______,
- c_______,
- c_______,
- c1_111__,
- c11___1_,
- c1____1_,
- c1____1_,
- c1____1_,
- c1____1_ }, /* n */
-
- { c_______,
- c_______,
- c_______,
- c_1111__,
- c1____1_,
- c1____1_,
- c1____1_,
- c1____1_,
- c_1111__ }, /* o */
-
- { c1_111__,
- c11___1_,
- c1____1_,
- c1____1_,
- c11___1_,
- c1_111__,
- c1______,
- c1______,
- c1______ }, /* p */
-
- { c_111_1_,
- c1___11_,
- c1____1_,
- c1____1_,
- c1___11_,
- c_111_1_,
- c_____1_,
- c_____1_,
- c_____1_ }, /* q */
-
- { c_______,
- c_______,
- c_______,
- c1_111__,
- c11___1_,
- c1______,
- c1______,
- c1______,
- c1______ }, /* r */
-
- { c_______,
- c_______,
- c_______,
- c_1111__,
- c1____1_,
- c_11____,
- c___11__,
- c1____1_,
- c_1111__ }, /* s */
-
- { c_______,
- c__1____,
- c__1____,
- c11111__,
- c__1____,
- c__1____,
- c__1____,
- c__1__1_,
- c___11__ }, /* t */
-
- { c_______,
- c_______,
- c_______,
- c1____1_,
- c1____1_,
- c1____1_,
- c1____1_,
- c1___11_,
- c_111_1_ }, /* u */
-
- { c_______,
- c_______,
- c_______,
- c1_____1,
- c1_____1,
- c1_____1,
- c_1___1_,
- c__1_1__,
- c___1___ }, /* v */
-
- { c_______,
- c_______,
- c_______,
- c1_____1,
- c1__1__1,
- c1__1__1,
- c1__1__1,
- c1__1__1,
- c_11_11_ }, /* w */
-
- { c_______,
- c_______,
- c_______,
- c1____1_,
- c_1__1__,
- c__11___,
- c__11___,
- c_1__1__,
- c1____1_ }, /* x */
-
- { c1____1_,
- c1____1_,
- c1____1_,
- c1____1_,
- c1___11_,
- c_111_1_,
- c_____1_,
- c1____1_,
- c_1111__ }, /* y */
-
- { c_______,
- c_______,
- c_______,
- c111111_,
- c____1__,
- c___1___,
- c__1____,
- c_1_____,
- c111111_ }, /* z */
-
- { c___11__,
- c__1____,
- c__1____,
- c__1____,
- c_1_____,
- c__1____,
- c__1____,
- c__1____,
- c___11__ }, /* } */
-
- { c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___,
- c___1___ }, /* | */
-
- { c__11___,
- c____1__,
- c____1__,
- c____1__,
- c_____1_,
- c____1__,
- c____1__,
- c____1__,
- c__11___ }, /* } */
-
- { c_11____,
- c1__1__1,
- c____11_,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______,
- c_______ }, /* ~ */
-
- { c_1__1__,
- c1__1__1,
- c__1__1_,
- c_1__1__,
- c1__1__1,
- c__1__1_,
- c_1__1__,
- c1__1__1,
- c__1__1_ } /* rub-out */
-
-#else /* LPD_CHSET */
/* <sjg> this is the real banner char set */
{
@@ -2113,6 +1151,5 @@ char scnkey[][HEIGHT] = /* this is relatively easy to modify */
c_1__1__,
c1__1__1
} /* rub-out */
-#endif /* LPD_CHSET */
};