diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 1999-03-06 20:27:46 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 1999-03-06 20:27:46 +0000 |
commit | 7d4955aec89412abcaf55d02c734dc4c4f7bebaa (patch) | |
tree | fc4d09823ff0bee371e60685abc32425920c01cf /usr.bin | |
parent | 4cc3b0bb60e7d05b2491df58696cad3fc6d943ec (diff) |
back out changes that should not have escaped my local tree
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/lock/Makefile | 4 | ||||
-rw-r--r-- | usr.bin/lock/lock.c | 16 | ||||
-rw-r--r-- | usr.bin/make/suff.c | 13 | ||||
-rw-r--r-- | usr.bin/skey/skey.c | 10 | ||||
-rw-r--r-- | usr.bin/top/display.c | 38 | ||||
-rw-r--r-- | usr.bin/tput/Makefile | 7 | ||||
-rw-r--r-- | usr.bin/tput/tput.1 | 39 | ||||
-rw-r--r-- | usr.bin/tput/tput.c | 100 | ||||
-rw-r--r-- | usr.bin/vi/LICENSE | 14 | ||||
-rw-r--r-- | usr.bin/vi/README | 77 | ||||
-rw-r--r-- | usr.bin/vi/build/README | 57 | ||||
-rw-r--r-- | usr.bin/vi/cl/cl_main.c | 2 | ||||
-rw-r--r-- | usr.bin/vi/cl/cl_read.c | 2 | ||||
-rw-r--r-- | usr.bin/vi/cl/cl_screen.c | 5 | ||||
-rw-r--r-- | usr.bin/vi/cl/cl_term.c | 2 | ||||
-rw-r--r-- | usr.bin/vi/common/exf.c | 2 |
16 files changed, 163 insertions, 225 deletions
diff --git a/usr.bin/lock/Makefile b/usr.bin/lock/Makefile index ee26b404699..083c0297fbe 100644 --- a/usr.bin/lock/Makefile +++ b/usr.bin/lock/Makefile @@ -1,10 +1,8 @@ -# $OpenBSD: Makefile,v 1.7 1999/03/06 20:19:19 millert Exp $ +# $OpenBSD: Makefile,v 1.8 1999/03/06 20:27:39 millert Exp $ PROG= lock BINOWN= root BINMODE=4555 -DPADD= ${LIBUTIL} -LDADD= -lutil .include <bsd.own.mk> diff --git a/usr.bin/lock/lock.c b/usr.bin/lock/lock.c index 127e16423b2..3c388f9f48b 100644 --- a/usr.bin/lock/lock.c +++ b/usr.bin/lock/lock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lock.c,v 1.11 1999/03/06 20:19:19 millert Exp $ */ +/* $OpenBSD: lock.c,v 1.12 1999/03/06 20:27:40 millert Exp $ */ /* $NetBSD: lock.c,v 1.8 1996/05/07 18:32:31 jtc Exp $ */ /* @@ -47,7 +47,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)lock.c 8.1 (Berkeley) 6/6/93"; #endif -static char rcsid[] = "$OpenBSD: lock.c,v 1.11 1999/03/06 20:19:19 millert Exp $"; +static char rcsid[] = "$OpenBSD: lock.c,v 1.12 1999/03/06 20:27:40 millert Exp $"; #endif /* not lint */ /* @@ -71,7 +71,6 @@ static char rcsid[] = "$OpenBSD: lock.c,v 1.11 1999/03/06 20:19:19 millert Exp $ #include <string.h> #include <termios.h> #include <unistd.h> -#include <login_cap.h> #ifdef SKEY #include <skey.h> @@ -104,7 +103,6 @@ main(argc, argv) int ch, sectimeout, usemine; char *ap, *mypw, *ttynam, *tzn; char hostname[MAXHOSTNAMELEN], s[BUFSIZ], s1[BUFSIZ]; - login_cap_t *lc = NULL; sectimeout = TIMEOUT; mypw = NULL; @@ -215,18 +213,8 @@ main(argc, argv) break; } #endif -#if 0 if (!strcmp(mypw, crypt(s, mypw))) break; -#else - lc = login_getpwclass(pw); - if (lc->lc_style == NULL) - lc->lc_style = login_getstyle(lc, NULL, "login"); - if ((ch = auth_response(pw->pw_name, lc->lc_class, - lc->lc_style, "response", NULL, "", s)) > 0) - break; - warnx("auth_response returned %d", ch); -#endif } else if (!strcmp(s, s1)) break; diff --git a/usr.bin/make/suff.c b/usr.bin/make/suff.c index cb2042d3516..bcf8bb7ab08 100644 --- a/usr.bin/make/suff.c +++ b/usr.bin/make/suff.c @@ -1,4 +1,4 @@ -/* $OpenBSD: suff.c,v 1.12 1999/03/06 20:19:20 millert Exp $ */ +/* $OpenBSD: suff.c,v 1.13 1999/03/06 20:27:40 millert Exp $ */ /* $NetBSD: suff.c,v 1.13 1996/11/06 17:59:25 christos Exp $ */ /* @@ -43,7 +43,7 @@ #if 0 static char sccsid[] = "@(#)suff.c 8.4 (Berkeley) 3/21/94"; #else -static char rcsid[] = "$OpenBSD: suff.c,v 1.12 1999/03/06 20:19:20 millert Exp $"; +static char rcsid[] = "$OpenBSD: suff.c,v 1.13 1999/03/06 20:27:40 millert Exp $"; #endif #endif /* not lint */ @@ -686,7 +686,6 @@ Suff_EndTransform(gnp, dummy) Lst_IsEmpty(gn->children)) { Suff *s, *t; - Lst p; (void)SuffParseTransform(gn->name, &s, &t); @@ -696,11 +695,6 @@ Suff_EndTransform(gnp, dummy) } /* - * Store s->parents because s could be deleted in SuffRemove - */ - p = s->parents; - - /* * Remove the source from the target's children list. We check for a * nil return to handle a beanhead saying something like * .c.o .c.o: @@ -713,7 +707,8 @@ Suff_EndTransform(gnp, dummy) /* * Remove the target from the source's parents list */ - SuffRemove(p, t); + if (s != NULL) + SuffRemove(s->parents, t); } else if ((gn->type & OP_TRANSFORM) && DEBUG(SUFF)) { printf("transformation %s complete\n", gn->name); } diff --git a/usr.bin/skey/skey.c b/usr.bin/skey/skey.c index 99da755e2ea..b9e5aa0eb55 100644 --- a/usr.bin/skey/skey.c +++ b/usr.bin/skey/skey.c @@ -1,4 +1,4 @@ -/* * $OpenBSD: skey.c,v 1.11 1999/03/06 20:19:20 millert Exp $*/ +/* * $OpenBSD: skey.c,v 1.12 1999/03/06 20:27:41 millert Exp $*/ /* * S/KEY v1.1b (skey.c) * @@ -37,7 +37,7 @@ main(argc, argv) { int n, i, cnt = 1, pass = 0, hexmode = 0; char passwd[SKEY_MAX_PW_LEN+1], key[SKEY_BINKEY_SIZE]; - char bufs[33], bufh[33], *seed, *slash; + char buf[33], *seed, *slash; /* If we were called as otp-METHOD, set algorithm based on that */ if ((slash = strrchr(argv[0], '/'))) @@ -129,16 +129,16 @@ main(argc, argv) if (cnt == 1) { while (n-- != 0) f(key); - (void)puts(hexmode ? put8(bufh, key) : btoe(bufs, key)); + (void)puts(hexmode ? put8(buf, key) : btoe(buf, key)); } else { for (i = 0; i <= n - cnt; i++) f(key); for (; i <= n; i++) { if (hexmode) (void)printf("%d: %-29s %s\n", i, - btoe(bufs, key), put8(bufh, key)); + btoe(buf, key), put8(buf, key)); else - (void)printf("%d: %-29s\n", i, btoe(bufs, key)); + (void)printf("%d: %-29s\n", i, btoe(buf, key)); f(key); } } diff --git a/usr.bin/top/display.c b/usr.bin/top/display.c index 5c2848252d3..93b65b07ee3 100644 --- a/usr.bin/top/display.c +++ b/usr.bin/top/display.c @@ -1,4 +1,4 @@ -/* $OpenBSD: display.c,v 1.3 1999/03/06 20:19:21 millert Exp $ */ +/* $OpenBSD: display.c,v 1.4 1999/03/06 20:27:42 millert Exp $ */ /* * Top users/processes display for Unix @@ -57,7 +57,7 @@ static int display_width = MAX_COLS; static char *cpustates_tag __P((void)); static int string_count __P((char **)); -static void summary_format __P((char *, size_t, int *, char **)); +static void summary_format __P((char *, int *, char **)); static void line_update __P((char *, char *, int, int)); #define lineindex(l) ((l)*display_width) @@ -305,8 +305,7 @@ int *brkdn; } /* format and print the process state summary */ - summary_format(procstates_buffer, sizeof(procstates_buffer), brkdn, - procstate_names); + summary_format(procstates_buffer, brkdn, procstate_names); fputs(procstates_buffer, stdout); /* save the numbers for next time */ @@ -355,7 +354,7 @@ int *brkdn; if (memcmp(lprocstates, brkdn, num_procstates * sizeof(int)) != 0) { /* format and update the line */ - summary_format(new, sizeof(new), brkdn, procstate_names); + summary_format(new, brkdn, procstate_names); line_update(procstates_buffer, new, x_brkdn, y_brkdn); memcpy(lprocstates, brkdn, num_procstates * sizeof(int)); } @@ -523,7 +522,7 @@ int *stats; lastline++; /* format and print the memory summary */ - summary_format(memory_buffer, sizeof(memory_buffer), stats, memory_names); + summary_format(memory_buffer, stats, memory_names); fputs(memory_buffer, stdout); } @@ -535,7 +534,7 @@ int *stats; static char new[MAX_COLS]; /* format the new line */ - summary_format(new, sizeof(new), stats, memory_names); + summary_format(new, stats, memory_names); line_update(memory_buffer, new, x_mem, y_mem); } @@ -936,22 +935,19 @@ register char **pp; return(cnt); } -static void summary_format(str, siz, numbers, names) +static void summary_format(str, numbers, names) char *str; -size_t siz; int *numbers; register char **names; { + register char *p; register int num; register char *thisname; - if (siz == 0) - return; - /* format each number followed by its string */ - *str = '\0'; + p = str; while ((thisname = *names++) != NULL) { /* get the number to format */ @@ -964,30 +960,30 @@ register char **names; if (thisname[0] == 'K') { /* yes: format it as a memory value */ - strlcat(str, format_k(num), siz); + p = strecpy(p, format_k(num)); /* skip over the K, since it was included by format_k */ - strlcat(str, thisname+1, siz); + p = strecpy(p, thisname+1); } else { - strlcat(str, itoa(num), siz); - strlcat(str, thisname, siz); + p = strecpy(p, itoa(num)); + p = strecpy(p, thisname); } } /* ignore negative numbers, but display corresponding string */ else if (num < 0) { - strlcat(str, thisname, siz); + p = strecpy(p, thisname); } } /* if the last two characters in the string are ", ", delete them */ - thisname = str + strlen(str) - 2; - if (thisname >= str && thisname[0] == ',' && thisname[1] == ' ') + p -= 2; + if (p >= str && p[0] == ',' && p[1] == ' ') { - *thisname = '\0'; + *p = '\0'; } } diff --git a/usr.bin/tput/Makefile b/usr.bin/tput/Makefile index 77018ee2160..836899278a7 100644 --- a/usr.bin/tput/Makefile +++ b/usr.bin/tput/Makefile @@ -1,8 +1,9 @@ -# $OpenBSD: Makefile,v 1.9 1999/03/06 20:19:21 millert Exp $ +# $OpenBSD: Makefile,v 1.10 1999/03/06 20:27:42 millert Exp $ PROG= tput -DPADD= ${LIBCURSES} -LDADD= -lcurses +CFLAGS+= -D_USE_OLD_CURSES_ +DPADD= ${LIBOLDCURSES} +LDADD= -locurses MLINKS= tput.1 clear.1 LINKS= ${BINDIR}/tput ${BINDIR}/clear diff --git a/usr.bin/tput/tput.1 b/usr.bin/tput/tput.1 index bef16e1dfd0..8a6623a5c90 100644 --- a/usr.bin/tput/tput.1 +++ b/usr.bin/tput/tput.1 @@ -1,4 +1,4 @@ -.\" $OpenBSD: tput.1,v 1.4 1999/03/06 20:19:21 millert Exp $ +.\" $OpenBSD: tput.1,v 1.5 1999/03/06 20:27:42 millert Exp $ .\" $NetBSD: tput.1,v 1.4 1994/12/07 08:49:10 jtc Exp $ .\" .\" Copyright (c) 1989, 1990, 1993 @@ -34,7 +34,7 @@ .\" .\" @(#)tput.1 8.2 (Berkeley) 3/19/94 .\" -.Dd July 25, 1998 +.Dd March 19, 1994 .Dt TPUT 1 .Os BSD 4.4 .Sh NAME @@ -46,9 +46,6 @@ .Ar attribute .Op Ar attribute-args .Ar ... -.Nm tput -.Op Fl T Ar term -.Fl S .Sh DESCRIPTION .Nm tput makes terminal-dependent information available to users or shell @@ -57,17 +54,13 @@ The options are as follows: .Bl -tag -width Ds .It Fl T The terminal name as specified in the -.Xr terminfo +.Xr termcap database, for example, ``vt100'' or ``xterm''. If not specified, .Nm tput retrieves the .Dq Ev TERM variable from the environment. -.It Fl S -The -.Ar attributes -are read from stdin instead of from the command line. .El .Pp .Nm tput @@ -82,8 +75,8 @@ without further action. If the .Ar attribute is of type string, and takes arguments (e.g. cursor movement, -the terminfo -.Dq cup +the termcap +.Dq cm sequence) the arguments are taken from the command line immediately following the attribute. .Pp @@ -91,18 +84,18 @@ The following special attributes are available: .Bl -tag -width Ar .It clear Clear the screen (the -.Xr terminfo -``clear'' sequence). +.Xr termcap +``cl'' sequence). .It init Initialize the terminal (the -.Xr terminfo -``is2'' sequence). +.Xr termcap +``is'' sequence). .It longname Print the descriptive name of the user's terminal type. .It reset Reset the terminal (the -.Xr termifo -``rs2'' sequence). +.Xr termcap +``rs'' sequence). .Sh DIAGNOSTICS The exit value of .Nm tput @@ -117,15 +110,15 @@ exits 0 if the terminal has this attribute, and 1 if it does not. .Nm tput exits 2 if any error occurred. .Sh EXAMPLES -.Bl -tag -width "tput cup 6 11 dch 6" -compact -.It Li "tput clear cup 5 10" +.Bl -tag -width "tput cm 6 11 DC 6" -compact +.It Li "tput cl cm 5 10" clear the screen and goto line 5 column 10 .Pp -.It Li "tput cup 6 11 dch 6" +.It Li "tput cm 6 11 DC 6" goto line 6 column 11 and delete 6 characters .Sh SEE ALSO -.Xr terminfo 3 , -.Xr terminfo 5 +.Xr termcap 3 , +.Xr termcap 5 .Sh BUGS .Nm tput can't really distinguish between different types of attributes. diff --git a/usr.bin/tput/tput.c b/usr.bin/tput/tput.c index e354f260882..0b961ac0001 100644 --- a/usr.bin/tput/tput.c +++ b/usr.bin/tput/tput.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tput.c,v 1.6 1999/03/06 20:19:22 millert Exp $ */ +/* $OpenBSD: tput.c,v 1.7 1999/03/06 20:27:42 millert Exp $ */ /* $NetBSD: tput.c,v 1.8 1995/08/31 22:11:37 jtc Exp $ */ /*- @@ -44,14 +44,13 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)tput.c 8.3 (Berkeley) 4/28/95"; #endif -static char rcsid[] = "$OpenBSD: tput.c,v 1.6 1999/03/06 20:19:22 millert Exp $"; +static char rcsid[] = "$OpenBSD: tput.c,v 1.7 1999/03/06 20:27:42 millert Exp $"; #endif /* not lint */ #include <termios.h> #include <err.h> #include <curses.h> -#include <term.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> @@ -59,101 +58,75 @@ static char rcsid[] = "$OpenBSD: tput.c,v 1.6 1999/03/06 20:19:22 millert Exp $" static void prlongname __P((char *)); static void setospeed __P((void)); +static void outc __P((int)); static void usage __P((void)); static char **process __P((char *, char *, char **)); -extern char *__progname; - int main(argc, argv) int argc; char **argv; { - int ch, exitval, n, Sflag = 0; - size_t len; - char *p, *term, *str; + extern char *optarg; + extern int optind; + int ch, exitval, n; + char *argv0, *cptr, *p, *term, buf[1024], tbuf[1024]; term = NULL; - while ((ch = getopt(argc, argv, "ST:")) != -1) + while ((ch = getopt(argc, argv, "T:")) != -1) switch(ch) { case 'T': term = optarg; break; - case 'S': - Sflag = 1; - break; case '?': default: usage(); } + if ((argv0 = (char *)strrchr(argv[0], '/')) != NULL) + argv0++; + else + argv0 = argv[0]; argc -= optind; argv += optind; - if (Sflag && argc > 0) - usage(); if (!term && !(term = getenv("TERM"))) errx(2, "no terminal type specified and no TERM environmental variable."); - if (setupterm(term, STDOUT_FILENO, NULL) == ERR) - err(2, "setupterm failure"); + if (tgetent(tbuf, term) != 1) + err(2, "tgetent failure"); setospeed(); - if (strcmp(__progname, "clear") == 0) { - if (Sflag) - usage(); + if (strcmp(argv0, "clear") == 0) { *argv = "clear"; *(argv+1) = NULL; } - if (Sflag) { - char **av; - - /* Build new argv based on stdin */ - argc = n = 0; - av = NULL; - while ((str = fgetln(stdin, &len)) != NULL) { - if (str[len-1] != '\n') - errx(1, "premature EOF"); - str[len-1] = '\0'; - /* grow av as needed */ - if (argc + 1 >= n) { - n += 64; - av = (char **)realloc(av, sizeof(char *) * n); - if (av == NULL) - errx(1, "out of memory"); - av = &av[argc]; - } - while ((p = strsep(&str, " \t")) != NULL) - if ((av[argc++] = strdup(p)) == NULL) - errx(1, "out of memory"); - } - if (argc > 0) { - av[argc] = NULL; - argv = av; - } - } for (exitval = 0; (p = *argv) != NULL; ++argv) { switch (*p) { + case 'c': + if (!strcmp(p, "clear")) + p = "cl"; + break; case 'i': if (!strcmp(p, "init")) - p = "is2"; /* XXX - is1 as well? */ + p = "is"; break; case 'l': if (!strcmp(p, "longname")) { - prlongname(CUR term_names); + prlongname(tbuf); continue; } break; case 'r': if (!strcmp(p, "reset")) - p = "rs2"; /* XXX - rs1 as well? */ + p = "rs"; break; } - /* XXX - check termcap names too */ - if ((str = tigetstr(p)) != NULL && str != (char *)-1) - argv = process(p, str, argv); - else if ((n = tigetnum(p)) != -1 && n != -2) + cptr = buf; + if (tgetstr(p, &cptr)) + argv = process(p, buf, argv); + else if ((n = tgetnum(p)) != -1) (void)printf("%d\n", n); else - exitval = (tigetflag(p) == -1); + exitval = !tgetflag(p); if (argv == NULL) break; @@ -211,7 +184,7 @@ process(cap, str, argv) break; default: /* - * HP-UX has lots of them, but we complain + * hpux has lot's of them, but we complain */ errx(2, erresc, *cp, cap); } @@ -219,7 +192,7 @@ process(cap, str, argv) /* And print them. */ switch (arg_need) { case 0: - (void)putp(str); + (void)tputs(str, 1, outc); break; case 1: arg_cols = 0; @@ -228,7 +201,7 @@ process(cap, str, argv) errx(2, errfew, 1, cap); arg_rows = atoi(*argv); - (void)putp(tparm(str, arg_cols, arg_rows)); + (void)tputs(tgoto(str, arg_cols, arg_rows), 1, outc); break; case 2: if (*++argv == NULL || *argv[0] == '\0') @@ -239,7 +212,7 @@ process(cap, str, argv) errx(2, errfew, 2, cap); arg_cols = atoi(*argv); - (void) tputs(tparm(str, arg_cols, arg_rows), arg_rows, putchar); + (void) tputs(tgoto(str, arg_cols, arg_rows), arg_rows, outc); break; default: @@ -262,10 +235,15 @@ setospeed() } static void +outc(c) + int c; +{ + (void)putchar(c); +} + +static void usage() { - (void)fprintf(stderr, - "usage: %s [-T term] attribute [attribute-args] ...\n" - " %s [-T term] -S\n", __progname, __progname); + (void)fprintf(stderr, "usage: tput [-T term] attribute ...\n"); exit(1); } diff --git a/usr.bin/vi/LICENSE b/usr.bin/vi/LICENSE index 5c8042e751d..78e8f4a40e1 100644 --- a/usr.bin/vi/LICENSE +++ b/usr.bin/vi/LICENSE @@ -1,12 +1,14 @@ -Copyright (c) 1996, 1997 - Sleepycat Software. All rights reserved. +The vi program is freely redistributable. You are welcome to copy, modify +and share it with others under the conditions listed in this file. If any +company (not any individual!) finds vi sufficiently useful that you would +have purchased it, or if any company wishes to redistribute it, contributions +to the authors would be appreciated. -Copyright (c) 1991, 1992, 1993, 1994, 1995, 1996 - Keith Bostic. All rights reserved. - -/* +/*- * Copyright (c) 1991, 1992, 1993, 1994 * The Regents of the University of California. All rights reserved. + * Copyright (c) 1991, 1992, 1993, 1994, 1995, 1996 + * Keith Bostic. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions diff --git a/usr.bin/vi/README b/usr.bin/vi/README index 48fddc74ccc..33db36a5c86 100644 --- a/usr.bin/vi/README +++ b/usr.bin/vi/README @@ -1,52 +1,31 @@ -# @(#)README 8.149 (Berkeley) 7/14/97 - -This is version 1.79 (7/14/97) of nex/nvi, a reimplementation of the ex/vi -text editors originally distributed as part of the Fourth Berkeley -Software Distribution (4BSD), by the University of California, Berkeley. - -The directory layout is as follows: - - FAQ ........... Frequently asked questions. - LICENSE ....... Copyright, use and redistribution information. - README ........ This file. - catalog ....... Message catalogs; see catalog/README. - changelog ..... Log of changes from version to version. - cl ............ Vi interface to the curses(3) library. - clib .......... C library replacement source code. - common ........ Code shared by ex and vi. - curses ........ A stripped-down, replacement curses(3) library. - db ............ A stripped-down, replacement db(3) library. - dist .......... Various files used to build the vi distribution. - docs .......... Ex/vi documentation, both current and historic. - docs/README ... Documentation overview. - docs/edit ..... Edit: A tutorial. - docs/exref .... Ex Reference Manual -- Version 3.7. - docs/vi.man ... UNIX manual page for nex/nvi. - docs/vi.ref ... Nex/nvi reference manual. - docs/vitut .... An Introduction to Display Editing with Vi. - ex ............ Ex source code. - include ....... Replacement include files. - ip ............ Library interface to vi: vi side. - ipc ........... Library interface to vi: application side. - motif ......... Vi motif application. - motif_l ....... Motif library interface to vi. - perl_api ...... Perl scripting language support. - perl_scripts .. Perl scripts. - regex ......... POSIX 1003.2 regular expression library. - tcl_api ....... Tcl scripting language support. - tcl_scripts ... Tcl scripts. - vi ............ Vi source code. - -Bug fixes and updated versions of this software will periodically be made -available. For more information see: - - http://www.bostic.com/vi - -To ask questions about vi, report vi problems, request notification of -future releases and/or bug fixes, or to contact the authors for any reason, -please send email to: - - bostic@bostic.com +# @(#)README 8.147 (Berkeley) 10/19/96 + +This is the README for nex/nvi, a freely redistributable implementation +of the ex/vi text editors originally distributed as part of the Fourth +Berkeley Software Distribution (4BSD), by the University of California, +Berkeley. + +The source code for nex/nvi can be retrieved by using anonymous ftp to +ftp.cs.berkeley.edu. The file ucb/4bsd/nvi.tar.gz is the gzip'd archive, +of version 1.71 of nex/nvi. This version is believed to be stable and +problem free. The file ucb/4bsd/nvi-###.ALPHA.tar.gz is a gzip'd archive +of the current alpha-test release of nex/nvi. This version reflects the +current development tree, and will be more likely to have problems. + +See the file: + build/README for information on building nvi. + LAYOUT for a description of where everything is. + LICENSE for the copyright and redistribution terms. + +If you have any questions about nex/nvi, problems with it, or concerns +about the conditions for redistribution, please contact me: + + Keith Bostic +1-508-287-4781 + 394 E. Riding Dr. bostic@bostic.com + Carlisle, MA 01741 + USA + +Keith Bostic =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= o This software is several years old and is the product of many folks' work. diff --git a/usr.bin/vi/build/README b/usr.bin/vi/build/README index efbce2b9dfb..2d0447faea2 100644 --- a/usr.bin/vi/build/README +++ b/usr.bin/vi/build/README @@ -1,4 +1,4 @@ -# @(#)README 8.26 (Berkeley) 10/19/96 +# @(#)README 8.24 (Berkeley) 6/20/96 Nvi uses the GNU autoconf program for configuration and compilation. You should enter: @@ -271,41 +271,47 @@ INSTALLING NVI Nvi installs the following files into the following locations, with the following default values: -Variables: Default value: -prefix /usr/local -exec_prefix $(prefix) -bindir $(prefix)/bin -datadir $(prefix)/share -mandir $(prefix)/man - -File(s): Default location +File(s): Location + Default Location ---------------------------------------- -vi $(bindir)/vi -vi.1 $(mandir)/man1/vi.1 -vi.0 $(mandir)/cat1/vi.0 -Perl scripts $(datadir)/vi/perl/ -Tcl scripts $(datadir)/vi/tcl/ -Message Catalogs $(datadir)/vi/catalog/ +vi $(exec_prefix)/$(bindir)/vi + /usr/local/bin/vi + +vi.0 $(prefix)/$(mandir)/cat1/vi.0 + /usr/local/man/cat1/vi.0 + +Message Catalogs $(prefix)/$(datadir)/vi/catalog/ + /usr/local/share/vi/catalog/ + +Perl5 scripts $(prefix)/$(datadir)/vi/perl/ + /usr/local/share/vi/perl/ + +Tcl scripts $(prefix)/$(datadir)/vi/tcl/ + /usr/local/share/vi/tcl/ Notes: There are two hard links to the vi program, named ex and view. - Similarly, there are two hard links to the unformatted vi manual - page, named ex.1 and view.1, and two hard links to the formatted - manual page, named ex.0 and view.0. These links are created when - the program and man pages are installed. + Similarly, there are two hard links to the vi manual page, named + ex.0 and view.0. These links are created when the program and + man pages are installed. If you want to install vi, ex, view and the man pages as nvi, nex, nview, use the configure option --program-prefix=n. Other, more complex transformations are possible -- use configure --help to see more options. + The default value for both "exec_prefix" and "prefix" is the + directory /usr/local. The default values for "bindir", "datadir" + and "mandir" are bin, share and man, respectively. + To move the entire installation tree somewhere besides /usr/local, change the value of both "exec_prefix" and "prefix". To move the - binaries to a different place, change the value of "bindir". - Similarly, to put the datafiles (the message catalogs, Perl and - Tcl scripts) or the man pages in a different place, change the - value of "datadir" or "mandir". These values can be changed as - part of configuration: + binaries to a different place in the "exec_prefix" directory tree, + change the value of "bindir". Similarly, to put the datafiles + (the message catalogs, Perl5 and Tcl scripts) or the man pages in + a different place in the "prefix" directory tree, change the value + of "datadir" or "mandir". These values can be changed as part of + configuration: configure --exec_prefix=/usr/contrib --prefix=/usr/share @@ -317,6 +323,9 @@ Notes: completely removed and then recreated as part of the installation process. + The mandir directory must have another directory named "cat1" + beneath it for the man pages to successfully install. + =-=-=-=-=-=-= NVI AND THE CURSES LIBRARY =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= diff --git a/usr.bin/vi/cl/cl_main.c b/usr.bin/vi/cl/cl_main.c index 2889f709cbb..43381d1fb7f 100644 --- a/usr.bin/vi/cl/cl_main.c +++ b/usr.bin/vi/cl/cl_main.c @@ -17,9 +17,9 @@ static const char sccsid[] = "@(#)cl_main.c 10.36 (Berkeley) 10/14/96"; #include <sys/queue.h> #include <bitstring.h> -#include <curses.h> #include <errno.h> #include <fcntl.h> +#include <curses.h> #include <signal.h> #include <stdio.h> #include <stdlib.h> diff --git a/usr.bin/vi/cl/cl_read.c b/usr.bin/vi/cl/cl_read.c index 8a95a77b243..d71e03f8c5e 100644 --- a/usr.bin/vi/cl/cl_read.c +++ b/usr.bin/vi/cl/cl_read.c @@ -21,9 +21,9 @@ static const char sccsid[] = "@(#)cl_read.c 10.15 (Berkeley) 9/24/96"; #include <sys/time.h> #include <bitstring.h> -#include <curses.h> #include <errno.h> #include <fcntl.h> +#include <curses.h> #include <signal.h> #include <stdio.h> #include <stdlib.h> diff --git a/usr.bin/vi/cl/cl_screen.c b/usr.bin/vi/cl/cl_screen.c index 2049f91c67e..23e74be812c 100644 --- a/usr.bin/vi/cl/cl_screen.c +++ b/usr.bin/vi/cl/cl_screen.c @@ -17,8 +17,8 @@ static const char sccsid[] = "@(#)cl_screen.c 10.49 (Berkeley) 9/24/96"; #include <sys/queue.h> #include <bitstring.h> -#include <curses.h> #include <errno.h> +#include <curses.h> #include <signal.h> #include <stdio.h> #include <stdlib.h> @@ -195,8 +195,7 @@ cl_vi_init(sp) /* Curses vi always reads from (and writes to) a terminal. */ if (!F_ISSET(clp, CL_STDIN_TTY) || !isatty(STDOUT_FILENO)) { msgq(sp, M_ERR, - "016|vi's standard input and output must both refer to a - terminal"); + "016|Vi's standard input and output must be a terminal"); return (1); } diff --git a/usr.bin/vi/cl/cl_term.c b/usr.bin/vi/cl/cl_term.c index 6fa2cce613e..7d7661f870f 100644 --- a/usr.bin/vi/cl/cl_term.c +++ b/usr.bin/vi/cl/cl_term.c @@ -19,9 +19,9 @@ static const char sccsid[] = "@(#)cl_term.c 10.22 (Berkeley) 9/15/96"; #include <sys/stat.h> #include <bitstring.h> -#include <curses.h> #include <errno.h> #include <limits.h> +#include <curses.h> #include <signal.h> #include <stdio.h> #include <stdlib.h> diff --git a/usr.bin/vi/common/exf.c b/usr.bin/vi/common/exf.c index 86c4c05bcd0..574a16aab3b 100644 --- a/usr.bin/vi/common/exf.c +++ b/usr.bin/vi/common/exf.c @@ -10,7 +10,7 @@ #include "config.h" #ifndef lint -static const char sccsid[] = "@(#)exf.c 10.49 (Berkeley) 10/10/96"; +static const char sccsid[] = "@(#)exf.c 10.49 (Berkeley) 10/10/96"; #endif /* not lint */ #include <sys/param.h> |