Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

import of nvi 1.79

  • Loading branch information...
commit d7878470af879a7387e40dfa1e51675fe4260542 1 parent 1ec7d8d
aymeric authored
Showing with 7,464 additions and 3,696 deletions.
  1. +98 −9 usr.bin/vi/FAQ
  2. +3 −9 usr.bin/vi/LAYOUT
  3. +10 −7 usr.bin/vi/LICENSE
  4. +28 −25 usr.bin/vi/README
  5. +631 −40 usr.bin/vi/build/Makefile
  6. +76 −29 usr.bin/vi/build/Makefile.in
  7. +50 −52 usr.bin/vi/build/README
  8. +313 −69 usr.bin/vi/build/README.LynxOS
  9. +3 −3 usr.bin/vi/build/acconfig.h
  10. +17 −0 usr.bin/vi/build/aclocal.m4
  11. +18 −18 usr.bin/vi/build/config.guess
  12. +51 −9 usr.bin/vi/build/config.h
  13. +50 −8 usr.bin/vi/build/config.h.in
  14. +0 −3  usr.bin/vi/build/config.sub
  15. +735 −1,008 usr.bin/vi/build/configure
  16. +181 −127 usr.bin/vi/build/configure.in
  17. +29 −18 usr.bin/vi/build/distrib
  18. +1 −1  usr.bin/vi/build/pathnames.h
  19. +2 −2 usr.bin/vi/build/pathnames.h.in
  20. +6 −1 usr.bin/vi/build/port.h
  21. +6 −1 usr.bin/vi/build/port.h.in
  22. +49 −0 usr.bin/vi/build/recover
  23. +49 −0 usr.bin/vi/build/recover.in
  24. +13 −14 usr.bin/vi/catalog/Makefile
  25. +34 −20 usr.bin/vi/catalog/dutch
  26. +28 −14 usr.bin/vi/catalog/dutch.base
  27. +10 −31 usr.bin/vi/catalog/dutch.check
  28. +13 −10 usr.bin/vi/catalog/english
  29. +13 −10 usr.bin/vi/catalog/english.base
  30. +5 −2 usr.bin/vi/catalog/english.check
  31. +317 −0 usr.bin/vi/catalog/french
  32. +309 −0 usr.bin/vi/catalog/french.base
  33. +34 −0 usr.bin/vi/catalog/french.check
  34. +35 −21 usr.bin/vi/catalog/german
  35. +29 −16 usr.bin/vi/catalog/german.base
  36. +10 −31 usr.bin/vi/catalog/german.check
  37. +6 −6 usr.bin/vi/catalog/ru_SU.KOI8-R
  38. +4 −6 usr.bin/vi/catalog/ru_SU.KOI8-R.base
  39. +9 −4 usr.bin/vi/catalog/ru_SU.KOI8-R.check
  40. +317 −0 usr.bin/vi/catalog/spanish
  41. +309 −0 usr.bin/vi/catalog/spanish.base
  42. +35 −0 usr.bin/vi/catalog/spanish.check
  43. +27 −24 usr.bin/vi/catalog/swedish
  44. +26 −24 usr.bin/vi/catalog/swedish.base
  45. +4 −2 usr.bin/vi/catalog/swedish.check
  46. +13 −16 usr.bin/vi/cl/cl.h
  47. +41 −5 usr.bin/vi/cl/cl_bsd.c
  48. +118 −22 usr.bin/vi/cl/cl_funcs.c
  49. +142 −57 usr.bin/vi/cl/cl_main.c
  50. +5 −5 usr.bin/vi/cl/cl_read.c
  51. +23 −39 usr.bin/vi/cl/cl_screen.c
  52. +29 −6 usr.bin/vi/cl/cl_term.c
  53. +96 −25 usr.bin/vi/common/api.c
  54. +3 −3 usr.bin/vi/common/common.h
  55. +3 −3 usr.bin/vi/common/cut.c
  56. +9 −9 usr.bin/vi/common/delete.c
  57. +189 −47 usr.bin/vi/common/exf.c
  58. +9 −8 usr.bin/vi/common/exf.h
  59. +13 −13 usr.bin/vi/common/gs.h
  60. +5 −5 usr.bin/vi/common/key.c
  61. +4 −4 usr.bin/vi/common/key.h
  62. +2 −3 usr.bin/vi/common/line.c
  63. +48 −27 usr.bin/vi/common/main.c
  64. +2 −2 usr.bin/vi/common/mark.c
  65. +1 −1  usr.bin/vi/common/mem.h
  66. +59 −34 usr.bin/vi/common/msg.c
  67. +46 −28 usr.bin/vi/common/options.c
  68. +9 −6 usr.bin/vi/common/options.h
  69. +1 −1  usr.bin/vi/common/options_f.c
  70. +11 −9 usr.bin/vi/common/put.c
  71. +8 −5 usr.bin/vi/common/recover.c
  72. +6 −2 usr.bin/vi/common/screen.c
  73. +22 −19 usr.bin/vi/common/screen.h
  74. +35 −45 usr.bin/vi/common/search.c
  75. +2 −2 usr.bin/vi/common/util.c
  76. +0 −3  usr.bin/vi/docs/TODO
  77. +8 −15 usr.bin/vi/docs/USD.doc/edit/Makefile
  78. +13 −55 usr.bin/vi/docs/USD.doc/edit/edittut.ms
  79. +12 −9 usr.bin/vi/docs/USD.doc/exref/Makefile
  80. +7 −24 usr.bin/vi/docs/USD.doc/exref/ex.rm
  81. +13 −17 usr.bin/vi/docs/USD.doc/exref/ex.summary
  82. +9 −7 usr.bin/vi/docs/USD.doc/vi.man/Makefile
  83. +37 −42 usr.bin/vi/docs/USD.doc/vi.man/vi.1
  84. +16 −10 usr.bin/vi/docs/USD.doc/vi.ref/Makefile
  85. +28 −31 usr.bin/vi/docs/USD.doc/vi.ref/ex.cmd.roff
  86. +1 −1  usr.bin/vi/docs/USD.doc/vi.ref/merge.awk
  87. +44 −35 usr.bin/vi/docs/USD.doc/vi.ref/set.opt.roff
  88. +3 −29 usr.bin/vi/docs/USD.doc/vi.ref/vi.cmd.roff
  89. +96 −105 usr.bin/vi/docs/USD.doc/vi.ref/vi.ref
  90. +15 −10 usr.bin/vi/docs/USD.doc/vitut/Makefile
  91. +3 −1 usr.bin/vi/docs/USD.doc/vitut/vi.apwh.ms
  92. +3 −2 usr.bin/vi/docs/USD.doc/vitut/vi.chars
  93. +28 −18 usr.bin/vi/docs/USD.doc/vitut/vi.in
  94. +6 −6 usr.bin/vi/docs/USD.doc/vitut/vi.summary
  95. +168 −0 usr.bin/vi/docs/changelog
  96. +10 −15 usr.bin/vi/docs/features
  97. +229 −0 usr.bin/vi/docs/help
  98. +2 −2 usr.bin/vi/docs/interp/interp
  99. +80 −64 usr.bin/vi/ex/ex.c
  100. +4 −23 usr.bin/vi/ex/ex.h
  101. +5 −3 usr.bin/vi/ex/ex_append.c
  102. +10 −2 usr.bin/vi/ex/ex_args.c
  103. +158 −23 usr.bin/vi/ex/ex_argv.c
  104. +4 −5 usr.bin/vi/ex/ex_at.c
  105. +6 −6 usr.bin/vi/ex/ex_bang.c
  106. +25 −100 usr.bin/vi/ex/ex_cd.c
  107. +8 −8 usr.bin/vi/ex/ex_cmd.c
  108. +57 −45 usr.bin/vi/ex/ex_cscope.c
  109. +2 −2 usr.bin/vi/ex/ex_delete.c
  110. +2 −2 usr.bin/vi/ex/ex_file.c
  111. +2 −2 usr.bin/vi/ex/ex_filter.c
  112. +14 −13 usr.bin/vi/ex/ex_global.c
  113. +12 −13 usr.bin/vi/ex/ex_init.c
  114. +2 −2 usr.bin/vi/ex/ex_join.c
  115. +3 −3 usr.bin/vi/ex/ex_move.c
  116. +11 −120 usr.bin/vi/ex/ex_perl.c
  117. +31 −17 usr.bin/vi/ex/ex_read.c
  118. +14 −2 usr.bin/vi/ex/ex_screen.c
  119. +4 −4 usr.bin/vi/ex/ex_script.c
  120. +14 −4 usr.bin/vi/ex/ex_shell.c
  121. +2 −2 usr.bin/vi/ex/ex_shift.c
  122. +2 −3 usr.bin/vi/ex/ex_source.c
  123. +194 −160 usr.bin/vi/ex/ex_subst.c
  124. +22 −16 usr.bin/vi/ex/ex_tag.c
  125. +1 −2  usr.bin/vi/ex/ex_tcl.c
  126. +11 −10 usr.bin/vi/ex/ex_txt.c
  127. +13 −3 usr.bin/vi/ex/ex_util.c
  128. +2 −2 usr.bin/vi/ex/ex_version.c
  129. +2 −2 usr.bin/vi/ex/ex_visual.c
  130. +17 −10 usr.bin/vi/ex/ex_write.c
  131. +1 −1  usr.bin/vi/ex/version.h
  132. +5 −3 usr.bin/vi/include/cl_extern.h
  133. +199 −0 usr.bin/vi/include/com_extern.h
  134. +1 −4 usr.bin/vi/include/ex_extern.h
  135. +23 −0 usr.bin/vi/include/ip_extern.h
  136. +41 −39 usr.bin/vi/include/options_def.h
  137. +7 −1 usr.bin/vi/include/perl_extern.h
  138. +2 −2 usr.bin/vi/include/vi_extern.h
  139. +2 −2 usr.bin/vi/vi/getc.c
  140. +7 −5 usr.bin/vi/vi/v_delete.c
  141. +16 −6 usr.bin/vi/vi/v_ex.c
  142. +12 −12 usr.bin/vi/vi/v_itxt.c
  143. +8 −5 usr.bin/vi/vi/v_mark.c
  144. +5 −1 usr.bin/vi/vi/v_replace.c
  145. +57 −17 usr.bin/vi/vi/v_search.c
  146. +181 −99 usr.bin/vi/vi/v_txt.c
  147. +1 −1  usr.bin/vi/vi/v_ulcase.c
  148. +4 −1 usr.bin/vi/vi/v_util.c
  149. +3 −3 usr.bin/vi/vi/v_xchar.c
  150. +27 −5 usr.bin/vi/vi/v_yank.c
  151. +41 −21 usr.bin/vi/vi/vi.c
  152. +3 −3 usr.bin/vi/vi/vi.h
  153. +11 −7 usr.bin/vi/vi/vs_line.c
  154. +84 −80 usr.bin/vi/vi/vs_msg.c
  155. +132 −66 usr.bin/vi/vi/vs_refresh.c
  156. +6 −3 usr.bin/vi/vi/vs_smap.c
  157. +153 −74 usr.bin/vi/vi/vs_split.c
View
107 usr.bin/vi/FAQ
@@ -1,9 +1,9 @@
-@(#)FAQ 8.5 (Berkeley) 5/9/96
+@(#)FAQ 8.13 (Berkeley) 10/14/96
-Q: How can I get nvi to display my character set?
-A: Nvi uses the C library routine isprint(3) to determine if a character
+Q: How can I get vi to display my character set?
+A: Vi uses the C library routine isprint(3) to determine if a character
is printable, or should be displayed as an octal or hexadecimal value
- on the screen. Generally, if nvi is displaying printable characters
+ on the screen. Generally, if vi is displaying printable characters
in octal/hexadecimal forms, your environment is not configured correctly.
Try looking at the man pages that allow you to configure your locale.
For example, to configure an ISO 8859-1 locale under Solaris using csh,
@@ -21,13 +21,17 @@ A: Nvi uses the C library routine isprint(3) to determine if a character
HP-UX 10.X en_US.iso88591
SunOS 4.X iso_8859_1
SunOS 5.X iso_8859_1
+
+ If there's no other solution, you can use the print and noprint edit
+ options of vi to specify that a specific character is printable or not
+ printable.
Q: My map won't work!
A: One thing that you should immediately check if a vi map doesn't work
is if depends on the final cursor position after a P or p command.
Historic vi's were inconsistent as to the final position of the cursor,
and, to make matter worse, the final cursor position also depended on
- whether the put text came from a named or unnamed buffer! Nvi follows
+ whether the put text came from a named or unnamed buffer! Vi follows
the POSIX 1003.2 standard on this one, and makes this consistent, always
placing the cursor on the first character.
@@ -49,7 +53,7 @@ A: The difference is that the ignorecase edit option always ignores the
it will be treated case-sensitively, as if the ignorecase edit option
was not set.
-Q: When I edit binary files, nvi appends a <newline> to the last line!
+Q: When I edit binary files, vi appends a <newline> to the last line!
A: This is historic practice for vi, and further, it's required by the
POSIX 1003.2 standard. My intent is to provide a command line and/or
edit option to turn this behavior off when I switch to version 2.0 of
@@ -63,9 +67,94 @@ A: A common problem over slow links is that the set of characters sent by
vi to wait longer before deciding that the <escape> character that
starts cursor key sequences doesn't have any characters following it.
-Q: When I edit some files, nvi seems to hang forever, and I have to kill it.
-A: Nvi uses flock(2) and fcntl(2) to do file locking. When it attempts to
+Q: When I edit some files, vi seems to hang forever, and I have to kill it.
+A: Vi uses flock(2) and fcntl(2) to do file locking. When it attempts to
acquired a lock for a file on an NFS mounted filesystem, it can hang
for a very long (perhaps infinite) period of time. Turning off the
- "lock" edit option will keep nvi from attempting to acquire any locks
+ "lock" edit option will keep vi from attempting to acquire any locks
on the files you edit.
+
+Q: When I compile vi I get lots of warnings about pointer assignments
+ being incompatible!
+A: Vi is partially written to support wide characters. When this code
+ interfaces with the code that doesn't yet support wide characters,
+ the pointer types clash. This will hopefully be fixed in the near
+ future, but I've been saying that for awhile, now.
+
+Q: I get jumpy scrolling behavior in the screen!
+A: This is almost certainly a problem with the system's terminfo or
+ termcap information for your terminal. If the terminfo/termcap entry
+ doesn't have the settable scrolling region capabilities, or the more
+ powerful scrolling commands, these behaviors can result. Historic
+ implementations of vi, and some of the vi clones, don't suffer from
+ this problem because they wrote their own screen support instead of
+ using the curses library.
+
+ The solution is to find a good terminfo or termcap entry for your
+ terminal, which will fix the problem for all of the applications on
+ your system, not just vi. Eric Raymond maintains the freely
+ redistributable termcap/terminfo entries. They can be downloaded
+ from http://www.ccil.org/~esr/ncurses.html, or you can contact him
+ at esr@snark.thyrsus.com.
+
+Q: The entire screen repaints on every keystroke!
+A: Your system's curses implementation is broken. You should use the
+ curses implementation provided with vi or a curses replacement such
+ as ncurses. Eric Raymond is one of the maintainers of the freely
+ redistributable ncurses package. You can download ncurses from
+ http://www.ccil.org/~esr/ncurses.html, or you can contact him at
+ esr@snark.thyrsus.com.
+
+Q: When I use vi on a Sun console (terminal type sun-34) the screen
+ is occasionally trashed, usually when exiting vi!
+A: The Sun console can't handle the 'al' capability of the termcap
+ entry (the il1 capability of terminfo entries). If you delete that
+ entry from your terminfo/termcap information everything should work
+ correctly.
+
+Q: I don't have a version of ctags (or I have ctags, but it doesn't tag
+ nearly enough things)!
+A: There's a version of ctags available on the 4.4BSD-Lite distributions,
+ as well as the FreeBSD, NetBSD, Linux and GNU distributions. Or, you
+ might want to try Exuberant Ctags:
+
+ Title: Exuberant Ctags
+ Version: 1.3
+ Entered-date: 16JUN96
+ Description:
+ A better ctags which generates tags for all possible tag types:
+ macro definitions, enumerated values (values inside enum{...}),
+ function and method definitions, enum/struct/union tags, external
+ function prototypes (optional), typedefs, and variable
+ declarations. It is far less easily fooled by code containing #if
+ preprocessor conditional constructs, using a conditional path
+ selection algorithm to resolve complicated choices, and a
+ fall-back algorithm when this one fails. Can also be used to print
+ out a list of selected objects found in source files.
+ Keywords: ctags, tags, exuberant
+ Author: darren@sirsi.com (Darren Hiebert)
+ darren@hiwaay.net (Darren Hiebert)
+ Maintained-by: darren@sirsi.com (Darren Hiebert)
+ darren@hiwaay.net (Darren Hiebert)
+ Primary-site: sunsite.unc.edu /pub/Linux/devel/lang/c
+ 27kB ctags-1.3.tar.gz
+ Alternate-site: ftp.halcyon.com /local/gvr
+ 27kB ctags-1.3.tar.gz
+ Original-site:
+ Platforms: UNIX, MSDOS, WindowsNT, Windows95, OS/2, Amiga
+ Copying-policy: Public domain
+
+Q: When I update a file I already have open, and use :e to reread it, I
+ get nul's for the rest of the file!
+A: Your system's implementation of mmap(2) has a bug; you will have to
+ exit vi and re-execute it.
+
+Q: Where can I get cscope?
+A: Cscope is available on UNIXWare System V Release 4.0 variants such as
+ Sun Solaris 2.x (/opt/SUNWspro/bin) and UNIXWare System V Release 4.1.
+
+ You can buy version 13.3 source with an unrestricted license for $400
+ from AT&T Software Solutions by calling +1-800-462-8146. Binary
+ redistribution of cscope is an additional $1500, one-time flat fee.
+
+ For more information, see http://www.unipress.com/att/new/cscope.html.
View
12 usr.bin/vi/LAYOUT
@@ -1,4 +1,4 @@
-# @(#)LAYOUT 8.10 (Berkeley) 5/13/96
+# @(#)LAYOUT 8.12 (Berkeley) 10/10/96
LAYOUT
This file: the layout of the nvi sources.
@@ -9,9 +9,6 @@ LICENSE
README
Welcome message and basic information.
-VERSION
- The version information of nvi.
-
build/
The build/configuration directory for nvi. See build/README for
more information.
@@ -99,17 +96,14 @@ ex/
command(s) they support, but occasionally with a name that
describes their functionality.
+ version.h -- Version information.
+
include/
Replacement include files:
bitstring.h -- The 4.4BSD bitstring operations.
sys/queue.h -- The 4.4BSD queue operations.
-install/
- Things to install on the local system.
-
- recover.script -- Vi recovery script.
-
perl_api/
Source code supporting the Perl scripting language for nvi.
View
17 usr.bin/vi/LICENSE
@@ -1,12 +1,15 @@
-# @(#)LICENSE 8.7 (Berkeley) 3/4/96
-
-This work is copyrighted by The Regents of the University of California,
-and by Keith Bostic. It may be freely redistributed under the following
-conditions, until one year after the release of any subsequent version of
-this software, at which point it may no longer be redistributed without
-written permission from Keith Bostic.
+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
+ * 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
* are met:
View
53 usr.bin/vi/README
@@ -1,28 +1,29 @@
-# @(#)README 8.135 (Berkeley) 5/18/96
+# @(#)README 8.147 (Berkeley) 10/19/96
-This is the README for nex/nvi, a freely redistributable replacement for
-the ex/vi text editors originally distributed as part of the Fourth
+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 files ucb/4bsd/nvi.tar.Z and ucb/4bsd/nvi.tar.gz
-are the compressed and gzip'd archives, respectively, of version 1.34 of
-nex/nvi. This version is believed to be stable and reasonably problem
-free. The file ucb/4bsd/nvi.ALPHA.1.66.tar.gz is a gzip'd archive of the
-current alpha-test release of nex/nvi, version 1.66. This version reflects
-the current development tree, and is more likely to have unanticipated
-problems.
+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.
+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.
-See the file LAYOUT for a description of where everything is.
+If you have any questions about nex/nvi, problems with it, or concerns
+about the conditions for redistribution, please contact me:
-If you have any questions about nex/nvi, or problems making it work,
-please contact me by electronic mail at one of the following addresses:
-
- uunet!bostic
- bostic@cs.berkeley.edu
+ Keith Bostic +1-508-287-4781
+ 394 E. Riding Dr. bostic@bostic.com
+ Carlisle, MA 01741
+ USA
Keith Bostic
@@ -43,10 +44,12 @@ o This software is several years old and is the product of many folks' work.
George Neville-Neil added the Tcl interpreter, and the initial
interpreter design was his.
- Sven Verdoolaege added the Perl5 interpreter.
+ Sven Verdoolaege added the Perl interpreter.
+
+ Rob Mayoff provided the original Cscope support.
-o Many, many people provided enhancements, bug reports and testing, far too
- many to individually thank.
+o Many, many people suggested enhancements, and provided bug reports and
+ testing, far too many to individually thank.
o From the original vi acknowledgements, by William Joy and Mark Horton:
@@ -66,16 +69,16 @@ o Status:
This software is in beta test, and it's pretty stable. Almost all of the
historic functionality in ex/vi is there, the only major missing pieces
-are open mode and the lisp option. (Also, the options hardtabs, optimize,
-redraw, and slowopen are recognized, but ignored.)
+are open mode and the lisp edit option.
Nvi is largely 8-bit clean. This isn't difficult to fix, and was left in
during initial development to keep things simple. Wide character support
will be integrated at the same time that it is made fully 8-bit clean.
There aren't a lot of new features in nex/nvi, but there are a few things
-you might like. The "Additional Features" section of the reference page
-(USD.doc/vi.ref/vi.ref.txt, USD.doc/vi.ref/vi.ref.ps) has more information.
+you might like. The "Additional Features" section of the reference work
+(docs/USD.doc/vi.ref/vi.ref.txt, docs/USD.doc/vi.ref/vi.ref.ps) has more
+information.
=-=-=-=-=-=-=-=-=-=-=
o Debugging:
@@ -86,7 +89,7 @@ reproduce the bug, and I'll try to fix it locally. Stack traces of core
dumps are only rarely helpful -- an example file with a set of keystrokes
that causes the problem is almost invariably necessary. I know it's
annoying, but simply playing with the bug until you can reproduce it at
-will with minimal keystrokes is immensely helpful to me.
+will, with minimal keystrokes, is immensely helpful to me.
Please include the following in the bug report;
View
671 usr.bin/vi/build/Makefile
@@ -1,40 +1,631 @@
-# $NetBSD: Makefile,v 1.1.1.1 1996/05/20 02:06:25 mrg Exp $
-#
-# from: @(#)Makefile.in 8.56 (Berkeley) 5/18/96
-
-CFLAGS+=-I${.CURDIR} -I${.CURDIR}/../include
-
-LDADD+= -lcurses -ltermcap
-PROG= vi
-SRCS= cl_bsd.c cl_funcs.c cl_main.c cl_read.c cl_screen.c cl_term.c \
- cut.c delete.c ex.c ex_abbrev.c ex_append.c ex_args.c ex_argv.c \
- ex_at.c ex_bang.c ex_cd.c ex_cmd.c ex_cscope.c ex_delete.c \
- ex_display.c ex_edit.c ex_equal.c ex_file.c ex_filter.c \
- ex_global.c ex_init.c ex_join.c ex_map.c ex_mark.c ex_mkexrc.c \
- ex_move.c ex_open.c ex_perl.c ex_preserve.c ex_print.c ex_put.c \
- ex_quit.c ex_read.c ex_screen.c ex_script.c ex_set.c ex_shell.c \
- ex_shift.c ex_source.c ex_stop.c ex_subst.c ex_tag.c ex_tcl.c \
- ex_txt.c ex_undo.c ex_usage.c ex_util.c ex_version.c ex_visual.c \
- ex_write.c ex_yank.c ex_z.c exf.c getc.c key.c line.c log.c main.c \
- mark.c msg.c options.c options_f.c put.c recover.c screen.c \
- search.c seq.c util.c v_at.c v_ch.c v_cmd.c v_delete.c v_ex.c \
- v_increment.c v_init.c v_itxt.c v_left.c v_mark.c v_match.c \
- v_paragraph.c v_put.c v_redraw.c v_replace.c v_right.c v_screen.c \
- v_scroll.c v_search.c v_section.c v_sentence.c v_status.c v_txt.c \
- v_ulcase.c v_undo.c v_util.c v_word.c v_xchar.c v_yank.c v_z.c \
- v_zexit.c vi.c vs_line.c vs_msg.c vs_refresh.c vs_relative.c \
- vs_smap.c vs_split.c
-
-LINKS= ${BINDIR}/vi ${BINDIR}/ex ${BINDIR}/vi ${BINDIR}/view
-MLINKS= vi.1 ex.1 vi.1 view.1
-
-.PATH: ${.CURDIR}/../vi ${.CURDIR}/../svi ${.CURDIR}/../ex ${.CURDIR}/../sex ${.CURDIR}/../cl ${.CURDIR}/../common ${.CURDIR}/../docs/USD.doc/vi.man
-.include <bsd.prog.mk>
-.include "../../Makefile.inc"
-
-cat= dutch english german ru_SU.KOI8-R swedish
-datadir= /usr/share
-afterinstall:
- install -d $(datadir)/vi
- install -d $(datadir)/vi/catalog
- (cd ${.CURDIR}/../catalog && install -m $(NONBINMODE) -c $(cat) $(datadir)/vi/catalog )
+# Generated automatically from Makefile.in by configure.
+# @(#)Makefile.in 8.75 (Berkeley) 10/23/96
+
+srcdir= ./..
+CC= cc
+OPTFLAG=-O
+CFLAGS= -c $(OPTFLAG) -I. -I$(srcdir)/include -I$(srcdir)/regex -I$(srcdir)/db/include -I$(srcdir)/curses
+LDFLAGS=
+PERL= /usr/pkg/bin/perl
+PERLLIB=
+SHRPENV=
+
+# Objects
+COBJS= addbytes.o addch.o box.o clear.o clrtobot.o clrtoeol.o \
+ cr_put.o ctrace.o cur_hash.o curses.o delch.o deleteln.o delwin.o \
+ erase.o fullname.o getch.o getstr.o id_subwins.o idlok.o initscr.o \
+ insch.o insertln.o longname.o move.o mvwin.o newwin.o overlay.o \
+ overwrite.o putchar.o refresh.o scroll.o setterm.o standout.o \
+ toucholap.o touchwin.o tscroll.o tstp.o tty.o unctrl.o waddnstr.o
+CLOBJS= cl_bsd.o cl_funcs.o cl_main.o cl_read.o cl_screen.o cl_term.o
+DBOBJS= db.o mpool.o \
+ bt_close.o bt_conv.o bt_debug.o bt_delete.o bt_get.o bt_open.o \
+ bt_overflow.o bt_page.o bt_put.o bt_search.o bt_seq.o \
+ bt_split.o bt_utils.o \
+ rec_close.o rec_delete.o rec_get.o rec_open.o rec_put.o \
+ rec_search.o rec_seq.o rec_utils.o
+REOBJS= regcomp.o regerror.o regexec.o regfree.o
+TKOBJS= tk_funcs.o tk_main.o tk_read.o tk_screen.o tk_term.o tk_util.o
+VIOBJS= cut.o delete.o ex.o ex_abbrev.o ex_append.o ex_args.o ex_argv.o \
+ ex_at.o ex_bang.o ex_cd.o ex_cmd.o ex_cscope.o ex_delete.o \
+ ex_display.o ex_edit.o ex_equal.o ex_file.o ex_filter.o \
+ ex_global.o ex_init.o ex_join.o ex_map.o ex_mark.o ex_mkexrc.o \
+ ex_move.o ex_open.o ex_perl.o ex_preserve.o ex_print.o ex_put.o \
+ ex_quit.o ex_read.o ex_screen.o ex_script.o ex_set.o ex_shell.o \
+ ex_shift.o ex_source.o ex_stop.o ex_subst.o ex_tag.o ex_tcl.o \
+ ex_txt.o ex_undo.o ex_usage.o ex_util.o ex_version.o ex_visual.o \
+ ex_write.o ex_yank.o ex_z.o exf.o getc.o key.o line.o log.o main.o \
+ mark.o msg.o options.o options_f.o put.o recover.o screen.o \
+ search.o seq.o util.o v_at.o v_ch.o v_cmd.o v_delete.o v_ex.o \
+ v_increment.o v_init.o v_itxt.o v_left.o v_mark.o v_match.o \
+ v_paragraph.o v_put.o v_redraw.o v_replace.o v_right.o v_screen.o \
+ v_scroll.o v_search.o v_section.o v_sentence.o v_status.o v_txt.o \
+ v_ulcase.o v_undo.o v_util.o v_word.o v_xchar.o v_yank.o v_z.o \
+ v_zexit.o vi.o vs_line.o vs_msg.o vs_refresh.o vs_relative.o \
+ vs_smap.o vs_split.o
+
+all: nvi
+
+NVIALL= $(CLOBJS) $(VIOBJS) $(COBJS) $(REOBJS) $(DBOBJS)
+nvi nex: $(NVIALL)
+ $(SHRPENV) $(CC) $(LDFLAGS) -o $@ $(NVIALL) -ltermlib -lcrypt
+ -rm -f nex
+ ln $@ nex
+
+TKALL= $(TKOBJS) $(VIOBJS) $(REOBJS) $(DBOBJS)
+tknvi: $(TKALL)
+ $(SHRPENV) $(CC) $(LDFLAGS) -o $@ $(TKALL)
+
+chmod= /bin/chmod
+cp= /bin/cp
+ln= /bin/ln
+mkdir= /bin/mkdir
+rm= /bin/rm
+strip= /usr/bin/strip
+
+prefix= /usr/local
+bindir= ${exec_prefix}/bin
+datadir=${prefix}/share
+mandir= ${prefix}/man
+exec_prefix=${prefix}
+
+dmode= 755
+emode= 555
+fmode= 444
+
+transform=s,x,x,
+
+install: all install_common
+ @echo "Installing vi, ex, view: $(bindir) ..."
+ [ -d $(bindir) ] || \
+ ($(mkdir) $(bindir) && $(chmod) $(dmode) $(bindir))
+ cd $(bindir) && $(rm) -f `echo vi | sed '$(transform)'`
+ $(cp) nvi $(bindir)/`echo vi | sed '$(transform)'`
+ cd $(bindir) && [ -f $(strip) ] && \
+ $(strip) `echo vi | sed '$(transform)'`
+ cd $(bindir) && $(chmod) $(emode) `echo vi | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo ex | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo view | sed '$(transform)'`
+ cd $(bindir) && $(ln) \
+ `echo vi | sed '$(transform)'` `echo ex | sed '$(transform)'`
+ cd $(bindir) && $(ln) \
+ `echo vi | sed '$(transform)'` `echo view | sed '$(transform)'`
+ [ -d $(mandir) ] || \
+ ($(mkdir) $(mandir) && $(chmod) $(dmode) $(mandir))
+ [ -d $(mandir)/cat1 ] || \
+ ($(mkdir) $(mandir)/cat1 && $(chmod) $(dmode) $(mandir)/cat1)
+ @echo "Installing man pages: $(mandir) ..."
+ cd $(mandir)/cat1 && $(rm) -f `echo vi.0 | sed '$(transform)'`
+ $(cp) $(srcdir)/docs/USD.doc/vi.man/vi.0 \
+ $(mandir)/cat1/`echo vi.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(chmod) $(fmode) `echo vi.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo ex.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo view.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(ln) \
+ `echo vi.0 | sed '$(transform)'` `echo ex.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(ln) \
+ `echo vi.0 | sed '$(transform)'` `echo view.0 | sed '$(transform)'`
+ [ -d $(mandir)/man1 ] || \
+ ($(mkdir) $(mandir)/man1 && $(chmod) $(dmode) $(mandir)/man1)
+ cd $(mandir)/man1 && $(rm) -f `echo vi.1 | sed '$(transform)'`
+ $(cp) $(srcdir)/docs/USD.doc/vi.man/vi.1 \
+ $(mandir)/man1/`echo vi.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(chmod) $(fmode) `echo vi.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo ex.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo view.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(ln) \
+ `echo vi.1 | sed '$(transform)'` `echo ex.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(ln) \
+ `echo vi.1 | sed '$(transform)'` `echo view.1 | sed '$(transform)'`
+
+cat= dutch english french german ru_SU.KOI8-R spanish swedish
+install_common:
+ [ -f $(chmod) ]
+ [ -f $(cp) ]
+ [ -f $(ln) ]
+ [ -f $(mkdir) ]
+ [ -f $(rm) ]
+ [ -d $(prefix) ] || \
+ ($(mkdir) $(prefix) && $(chmod) $(dmode) $(prefix))
+ [ -d $(exec_prefix) ] || \
+ ($(mkdir) $(exec_prefix) && $(chmod) $(dmode) $(exec_prefix))
+ [ -d $(datadir) ] || \
+ ($(mkdir) $(datadir) && $(chmod) $(dmode) $(datadir))
+ $(rm) -rf $(datadir)/vi
+ $(mkdir) $(datadir)/vi && $(chmod) $(dmode) $(datadir)/vi
+ @echo "Installing message catalogs: $(datadir)/vi/catalog ..."
+ $(mkdir) $(datadir)/vi/catalog && \
+ $(chmod) $(dmode) $(datadir)/vi/catalog
+ (cd $(srcdir)/catalog && $(cp) $(cat) $(datadir)/vi/catalog && \
+ cd $(datadir)/vi/catalog && $(chmod) $(fmode) *)
+ @echo "Installing Perl scripts: $(datadir)/vi/perl ..."
+ $(mkdir) $(datadir)/vi/perl && $(chmod) $(dmode) $(datadir)/vi/perl
+ [ -f VI.pm ] && $(cp) VI.pm $(datadir)/vi/perl && \
+ cd $(datadir)/vi/perl && $(chmod) $(fmode) VI.pm)
+ (cd $(srcdir)/perl_scripts && $(cp) *.pl $(datadir)/vi/perl && \
+ cd $(datadir)/vi/perl && $(chmod) $(fmode) *.pl)
+ @echo "Installing Tcl scripts: $(datadir)/vi/tcl ..."
+ $(mkdir) $(datadir)/vi/tcl && $(chmod) $(dmode) $(datadir)/vi/tcl
+ (cd $(srcdir)/tcl_scripts && $(cp) *.tcl $(datadir)/vi/tcl && \
+ cd $(datadir)/vi/tcl && $(chmod) $(fmode) *.tcl)
+ @echo "Installing recover script: $(datadir)/vi/recover ..."
+ ($(cp) recover $(datadir)/vi/recover && \
+ $(chmod) $(emode) $(datadir)/vi/recover)
+
+uninstall:
+ $(rm) -rf $(datadir)/vi
+ cd $(bindir) && $(rm) -f `echo ex | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo vi | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo view | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo ex.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo vi.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo view.0 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo ex.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo vi.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo view.1 | sed '$(transform)'`
+
+docs:
+ cd $(srcdir)/docs/USD.doc/vi.ref && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/vi.man && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/edit && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/exref && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/vitut && $(MAKE)
+
+clean:
+ -rm -f *.core *.o memcpy.c perl.c
+ -rm -f nex nvi tknvi core
+ -rm -f $(COBJS) $(CLOBJS) $(DBOBJS) $(REOBJS)
+ -rm -f $(TKOBJS) $(VIOBJS)
+
+cleandocs:
+ cd $(srcdir)/docs/USD.doc/vi.ref && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/vi.man && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/edit && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/exref && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/vitut && $(MAKE) clean
+
+distclean maintainer-clean realclean: clean cleandocs
+ -rm -f Makefile config.cache config.h config.log config.status
+ -rm -f pathnames.h port.h
+
+# Vi curses sources.
+cl_bsd.o: $(srcdir)/cl/cl_bsd.c
+ $(CC) $(CFLAGS) $?
+cl_funcs.o: $(srcdir)/cl/cl_funcs.c
+ $(CC) $(CFLAGS) $?
+cl_main.o: $(srcdir)/cl/cl_main.c
+ $(CC) $(CFLAGS) $?
+cl_read.o: $(srcdir)/cl/cl_read.c
+ $(CC) $(CFLAGS) $?
+cl_screen.o: $(srcdir)/cl/cl_screen.c
+ $(CC) $(CFLAGS) $?
+cl_term.o: $(srcdir)/cl/cl_term.c
+ $(CC) $(CFLAGS) $?
+
+# Vi Tk sources.
+tk_funcs.o: $(srcdir)/tk/tk_funcs.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+tk_main.o: $(srcdir)/tk/tk_main.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+tk_read.o: $(srcdir)/tk/tk_read.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+tk_screen.o: $(srcdir)/tk/tk_screen.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+tk_term.o: $(srcdir)/tk/tk_term.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+tk_util.o: $(srcdir)/tk/tk_util.c
+ $(CC) $(CFLAGS) -I/usr/X11R6/include $?
+
+# Vi Tcl/Perl interpreter sources.
+api.o: $(srcdir)/common/api.c
+ $(CC) $(CFLAGS) $?
+perl.c: $(srcdir)/perl_api/perl.xs $(srcdir)/perl_api/typemap
+ echo "#define _PATH_PERLSCRIPTS \"$(datadir)/vi/perl\"" > $@
+ $(PERL) $(PERLLIB)/ExtUtils/xsubpp -typemap \
+ $(PERLLIB)/ExtUtils/typemap $(srcdir)/perl_api/perl.xs >> $@
+ ($(PERL) -ne 'print "sub $$1 {\$$curscr->$$1(\@_)}\n" \
+ if /newXS\("VI::([^":]*)"/;' $@ ; echo "1;") > VI.pm
+perl.o: perl.c
+ $(CC) $(CFLAGS) $?
+perlsfio.o: $(srcdir)/perl_api/perlsfio.c
+ $(CC) $(CFLAGS) $?
+tcl.o: $(srcdir)/tcl_api/tcl.c
+ $(CC) $(CFLAGS) $?
+
+# Vi sources.
+cut.o: $(srcdir)/common/cut.c
+ $(CC) $(CFLAGS) $?
+delete.o: $(srcdir)/common/delete.c
+ $(CC) $(CFLAGS) $?
+exf.o: $(srcdir)/common/exf.c
+ $(CC) $(CFLAGS) $?
+key.o: $(srcdir)/common/key.c
+ $(CC) $(CFLAGS) $?
+line.o: $(srcdir)/common/line.c
+ $(CC) $(CFLAGS) $?
+log.o: $(srcdir)/common/log.c
+ $(CC) $(CFLAGS) $?
+main.o: $(srcdir)/common/main.c
+ $(CC) $(CFLAGS) $?
+mark.o: $(srcdir)/common/mark.c
+ $(CC) $(CFLAGS) $?
+msg.o: $(srcdir)/common/msg.c
+ $(CC) $(CFLAGS) $?
+options.o: $(srcdir)/common/options.c
+ $(CC) $(CFLAGS) $?
+options_f.o: $(srcdir)/common/options_f.c
+ $(CC) $(CFLAGS) $?
+put.o: $(srcdir)/common/put.c
+ $(CC) $(CFLAGS) $?
+screen.o: $(srcdir)/common/screen.c
+ $(CC) $(CFLAGS) $?
+search.o: $(srcdir)/common/search.c
+ $(CC) $(CFLAGS) $?
+seq.o: $(srcdir)/common/seq.c
+ $(CC) $(CFLAGS) $?
+recover.o: $(srcdir)/common/recover.c
+ $(CC) $(CFLAGS) $?
+util.o: $(srcdir)/common/util.c
+ $(CC) $(CFLAGS) $?
+ex.o: $(srcdir)/ex/ex.c
+ $(CC) $(CFLAGS) $?
+ex_abbrev.o: $(srcdir)/ex/ex_abbrev.c
+ $(CC) $(CFLAGS) $?
+ex_append.o: $(srcdir)/ex/ex_append.c
+ $(CC) $(CFLAGS) $?
+ex_args.o: $(srcdir)/ex/ex_args.c
+ $(CC) $(CFLAGS) $?
+ex_argv.o: $(srcdir)/ex/ex_argv.c
+ $(CC) $(CFLAGS) $?
+ex_at.o: $(srcdir)/ex/ex_at.c
+ $(CC) $(CFLAGS) $?
+ex_bang.o: $(srcdir)/ex/ex_bang.c
+ $(CC) $(CFLAGS) $?
+ex_cd.o: $(srcdir)/ex/ex_cd.c
+ $(CC) $(CFLAGS) $?
+ex_cmd.o: $(srcdir)/ex/ex_cmd.c
+ $(CC) $(CFLAGS) $?
+ex_cscope.o: $(srcdir)/ex/ex_cscope.c
+ $(CC) $(CFLAGS) $?
+ex_delete.o: $(srcdir)/ex/ex_delete.c
+ $(CC) $(CFLAGS) $?
+ex_digraph.o: $(srcdir)/ex/ex_digraph.c
+ $(CC) $(CFLAGS) $?
+ex_display.o: $(srcdir)/ex/ex_display.c
+ $(CC) $(CFLAGS) $?
+ex_edit.o: $(srcdir)/ex/ex_edit.c
+ $(CC) $(CFLAGS) $?
+ex_equal.o: $(srcdir)/ex/ex_equal.c
+ $(CC) $(CFLAGS) $?
+ex_file.o: $(srcdir)/ex/ex_file.c
+ $(CC) $(CFLAGS) $?
+ex_filter.o: $(srcdir)/ex/ex_filter.c
+ $(CC) $(CFLAGS) $?
+ex_global.o: $(srcdir)/ex/ex_global.c
+ $(CC) $(CFLAGS) $?
+ex_init.o: $(srcdir)/ex/ex_init.c
+ $(CC) $(CFLAGS) $?
+ex_join.o: $(srcdir)/ex/ex_join.c
+ $(CC) $(CFLAGS) $?
+ex_map.o: $(srcdir)/ex/ex_map.c
+ $(CC) $(CFLAGS) $?
+ex_mark.o: $(srcdir)/ex/ex_mark.c
+ $(CC) $(CFLAGS) $?
+ex_mkexrc.o: $(srcdir)/ex/ex_mkexrc.c
+ $(CC) $(CFLAGS) $?
+ex_move.o: $(srcdir)/ex/ex_move.c
+ $(CC) $(CFLAGS) $?
+ex_open.o: $(srcdir)/ex/ex_open.c
+ $(CC) $(CFLAGS) $?
+ex_perl.o: $(srcdir)/ex/ex_perl.c
+ $(CC) $(CFLAGS) $?
+ex_preserve.o: $(srcdir)/ex/ex_preserve.c
+ $(CC) $(CFLAGS) $?
+ex_print.o: $(srcdir)/ex/ex_print.c
+ $(CC) $(CFLAGS) $?
+ex_put.o: $(srcdir)/ex/ex_put.c
+ $(CC) $(CFLAGS) $?
+ex_quit.o: $(srcdir)/ex/ex_quit.c
+ $(CC) $(CFLAGS) $?
+ex_read.o: $(srcdir)/ex/ex_read.c
+ $(CC) $(CFLAGS) $?
+ex_screen.o: $(srcdir)/ex/ex_screen.c
+ $(CC) $(CFLAGS) $?
+ex_script.o: $(srcdir)/ex/ex_script.c
+ $(CC) $(CFLAGS) $?
+ex_set.o: $(srcdir)/ex/ex_set.c
+ $(CC) $(CFLAGS) $?
+ex_shell.o: $(srcdir)/ex/ex_shell.c
+ $(CC) $(CFLAGS) $?
+ex_shift.o: $(srcdir)/ex/ex_shift.c
+ $(CC) $(CFLAGS) $?
+ex_source.o: $(srcdir)/ex/ex_source.c
+ $(CC) $(CFLAGS) $?
+ex_stop.o: $(srcdir)/ex/ex_stop.c
+ $(CC) $(CFLAGS) $?
+ex_subst.o: $(srcdir)/ex/ex_subst.c
+ $(CC) $(CFLAGS) $?
+ex_tag.o: $(srcdir)/ex/ex_tag.c
+ $(CC) $(CFLAGS) $?
+ex_tcl.o: $(srcdir)/ex/ex_tcl.c
+ $(CC) $(CFLAGS) $?
+ex_txt.o: $(srcdir)/ex/ex_txt.c
+ $(CC) $(CFLAGS) $?
+ex_undo.o: $(srcdir)/ex/ex_undo.c
+ $(CC) $(CFLAGS) $?
+ex_usage.o: $(srcdir)/ex/ex_usage.c
+ $(CC) $(CFLAGS) $?
+ex_util.o: $(srcdir)/ex/ex_util.c
+ $(CC) $(CFLAGS) $?
+ex_version.o: $(srcdir)/ex/ex_version.c
+ $(CC) $(CFLAGS) $?
+ex_visual.o: $(srcdir)/ex/ex_visual.c
+ $(CC) $(CFLAGS) $?
+ex_write.o: $(srcdir)/ex/ex_write.c
+ $(CC) $(CFLAGS) $?
+ex_yank.o: $(srcdir)/ex/ex_yank.c
+ $(CC) $(CFLAGS) $?
+ex_z.o: $(srcdir)/ex/ex_z.c
+ $(CC) $(CFLAGS) $?
+getc.o: $(srcdir)/vi/getc.c
+ $(CC) $(CFLAGS) $?
+v_at.o: $(srcdir)/vi/v_at.c
+ $(CC) $(CFLAGS) $?
+v_ch.o: $(srcdir)/vi/v_ch.c
+ $(CC) $(CFLAGS) $?
+v_cmd.o: $(srcdir)/vi/v_cmd.c
+ $(CC) $(CFLAGS) $?
+v_delete.o: $(srcdir)/vi/v_delete.c
+ $(CC) $(CFLAGS) $?
+v_ex.o: $(srcdir)/vi/v_ex.c
+ $(CC) $(CFLAGS) $?
+v_increment.o: $(srcdir)/vi/v_increment.c
+ $(CC) $(CFLAGS) $?
+v_init.o: $(srcdir)/vi/v_init.c
+ $(CC) $(CFLAGS) $?
+v_itxt.o: $(srcdir)/vi/v_itxt.c
+ $(CC) $(CFLAGS) $?
+v_left.o: $(srcdir)/vi/v_left.c
+ $(CC) $(CFLAGS) $?
+v_mark.o: $(srcdir)/vi/v_mark.c
+ $(CC) $(CFLAGS) $?
+v_match.o: $(srcdir)/vi/v_match.c
+ $(CC) $(CFLAGS) $?
+v_paragraph.o: $(srcdir)/vi/v_paragraph.c
+ $(CC) $(CFLAGS) $?
+v_put.o: $(srcdir)/vi/v_put.c
+ $(CC) $(CFLAGS) $?
+v_redraw.o: $(srcdir)/vi/v_redraw.c
+ $(CC) $(CFLAGS) $?
+v_replace.o: $(srcdir)/vi/v_replace.c
+ $(CC) $(CFLAGS) $?
+v_right.o: $(srcdir)/vi/v_right.c
+ $(CC) $(CFLAGS) $?
+v_screen.o: $(srcdir)/vi/v_screen.c
+ $(CC) $(CFLAGS) $?
+v_scroll.o: $(srcdir)/vi/v_scroll.c
+ $(CC) $(CFLAGS) $?
+v_search.o: $(srcdir)/vi/v_search.c
+ $(CC) $(CFLAGS) $?
+v_section.o: $(srcdir)/vi/v_section.c
+ $(CC) $(CFLAGS) $?
+v_sentence.o: $(srcdir)/vi/v_sentence.c
+ $(CC) $(CFLAGS) $?
+v_status.o: $(srcdir)/vi/v_status.c
+ $(CC) $(CFLAGS) $?
+v_txt.o: $(srcdir)/vi/v_txt.c
+ $(CC) -c -O -I. -I$(srcdir)/include -I$(srcdir)/regex -I$(srcdir)/db/include -I$(srcdir)/curses $?
+v_ulcase.o: $(srcdir)/vi/v_ulcase.c
+ $(CC) $(CFLAGS) $?
+v_undo.o: $(srcdir)/vi/v_undo.c
+ $(CC) $(CFLAGS) $?
+v_util.o: $(srcdir)/vi/v_util.c
+ $(CC) $(CFLAGS) $?
+v_word.o: $(srcdir)/vi/v_word.c
+ $(CC) $(CFLAGS) $?
+v_xchar.o: $(srcdir)/vi/v_xchar.c
+ $(CC) $(CFLAGS) $?
+v_yank.o: $(srcdir)/vi/v_yank.c
+ $(CC) $(CFLAGS) $?
+v_z.o: $(srcdir)/vi/v_z.c
+ $(CC) $(CFLAGS) $?
+v_zexit.o: $(srcdir)/vi/v_zexit.c
+ $(CC) $(CFLAGS) $?
+vi.o: $(srcdir)/vi/vi.c
+ $(CC) $(CFLAGS) $?
+vs_line.o: $(srcdir)/vi/vs_line.c
+ $(CC) $(CFLAGS) $?
+vs_msg.o: $(srcdir)/vi/vs_msg.c
+ $(CC) $(CFLAGS) $?
+vs_refresh.o: $(srcdir)/vi/vs_refresh.c
+ $(CC) $(CFLAGS) $?
+vs_relative.o: $(srcdir)/vi/vs_relative.c
+ $(CC) $(CFLAGS) $?
+vs_smap.o: $(srcdir)/vi/vs_smap.c
+ $(CC) $(CFLAGS) $?
+vs_split.o: $(srcdir)/vi/vs_split.c
+ $(CC) $(CFLAGS) $?
+
+addbytes.o: $(srcdir)/curses/addbytes.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+addch.o: $(srcdir)/curses/addch.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+box.o: $(srcdir)/curses/box.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+clear.o: $(srcdir)/curses/clear.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+clrtobot.o: $(srcdir)/curses/clrtobot.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+clrtoeol.o: $(srcdir)/curses/clrtoeol.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+cr_put.o: $(srcdir)/curses/cr_put.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+ctrace.o: $(srcdir)/curses/ctrace.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+cur_hash.o: $(srcdir)/curses/cur_hash.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+curses.o: $(srcdir)/curses/curses.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+delch.o: $(srcdir)/curses/delch.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+deleteln.o: $(srcdir)/curses/deleteln.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+delwin.o: $(srcdir)/curses/delwin.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+erase.o: $(srcdir)/curses/erase.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+fullname.o: $(srcdir)/curses/fullname.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+getch.o: $(srcdir)/curses/getch.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+getstr.o: $(srcdir)/curses/getstr.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+id_subwins.o: $(srcdir)/curses/id_subwins.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+idlok.o: $(srcdir)/curses/idlok.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+initscr.o: $(srcdir)/curses/initscr.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+insch.o: $(srcdir)/curses/insch.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+insertln.o: $(srcdir)/curses/insertln.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+longname.o: $(srcdir)/curses/longname.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+move.o: $(srcdir)/curses/move.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+mvwin.o: $(srcdir)/curses/mvwin.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+newwin.o: $(srcdir)/curses/newwin.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+overlay.o: $(srcdir)/curses/overlay.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+overwrite.o: $(srcdir)/curses/overwrite.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+putchar.o: $(srcdir)/curses/putchar.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+refresh.o: $(srcdir)/curses/refresh.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+scroll.o: $(srcdir)/curses/scroll.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+setterm.o: $(srcdir)/curses/setterm.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+standout.o: $(srcdir)/curses/standout.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+toucholap.o: $(srcdir)/curses/toucholap.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+touchwin.o: $(srcdir)/curses/touchwin.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+tscroll.o: $(srcdir)/curses/tscroll.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+tstp.o: $(srcdir)/curses/tstp.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+tty.o: $(srcdir)/curses/tty.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+unctrl.o: $(srcdir)/curses/unctrl.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+waddnstr.o: $(srcdir)/curses/waddnstr.c
+ $(CC) -D_CURSES_PRIVATE $(CFLAGS) $?
+
+# DB sources.
+db.o: $(srcdir)/db/db/db.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) $?
+mpool.o: $(srcdir)/db/mpool/mpool.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/mpool $?
+bt_close.o: $(srcdir)/db/btree/bt_close.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_conv.o: $(srcdir)/db/btree/bt_conv.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_debug.o: $(srcdir)/db/btree/bt_debug.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_delete.o: $(srcdir)/db/btree/bt_delete.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_get.o: $(srcdir)/db/btree/bt_get.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_open.o: $(srcdir)/db/btree/bt_open.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_overflow.o: $(srcdir)/db/btree/bt_overflow.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_page.o: $(srcdir)/db/btree/bt_page.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_put.o: $(srcdir)/db/btree/bt_put.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_search.o: $(srcdir)/db/btree/bt_search.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_seq.o: $(srcdir)/db/btree/bt_seq.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_split.o: $(srcdir)/db/btree/bt_split.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+bt_utils.o: $(srcdir)/db/btree/bt_utils.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/btree $?
+rec_close.o: $(srcdir)/db/recno/rec_close.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_delete.o: $(srcdir)/db/recno/rec_delete.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_get.o: $(srcdir)/db/recno/rec_get.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_open.o: $(srcdir)/db/recno/rec_open.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_put.o: $(srcdir)/db/recno/rec_put.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_search.o: $(srcdir)/db/recno/rec_search.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_seq.o: $(srcdir)/db/recno/rec_seq.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+rec_utils.o: $(srcdir)/db/recno/rec_utils.c
+ $(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
+
+# Regular Expressions sources.
+regcomp.o: $(srcdir)/regex/regcomp.c
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
+regerror.o: $(srcdir)/regex/regerror.c
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
+regexec.o: $(srcdir)/regex/regexec.c
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
+regfree.o: $(srcdir)/regex/regfree.c
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
+
+# Random replacement and workaround sources.
+addnstr.o: $(srcdir)/clib/addnstr.c
+ $(CC) $(CFLAGS) $?
+bsearch.o: $(srcdir)/clib/bsearch.c
+ $(CC) $(CFLAGS) $?
+env.o: $(srcdir)/clib/env.c
+ $(CC) $(CFLAGS) $?
+fchmod.o: $(srcdir)/clib/fchmod.c
+ $(CC) $(CFLAGS) $(INC) $?
+gethostname.o: $(srcdir)/clib/gethostname.c
+ $(CC) $(CFLAGS) $(INC) $?
+getopt.o: $(srcdir)/clib/getopt.c
+ $(CC) $(CFLAGS) $(INC) $?
+memchr.o: $(srcdir)/clib/memchr.c
+ $(CC) $(CFLAGS) $?
+memcpy.o: $(srcdir)/clib/memmove.c
+ $(cp) $? memcpy.c
+ $(CC) $(CFLAGS) -DMEMCOPY memcpy.c
+memmove.o: $(srcdir)/clib/memmove.c
+ $(CC) $(CFLAGS) -DMEMMOVE $?
+memset.o: $(srcdir)/clib/memset.c
+ $(CC) $(CFLAGS) $?
+mkstemp.o: $(srcdir)/clib/mkstemp.c
+ $(CC) $(CFLAGS) $?
+mmap.o: $(srcdir)/clib/mmap.c
+ $(CC) $(CFLAGS) $?
+realloc.o: $(srcdir)/clib/realloc.c
+ $(CC) $(CFLAGS) $?
+snprintf.o: $(srcdir)/clib/snprintf.c
+ $(CC) $(CFLAGS) $?
+strdup.o: $(srcdir)/clib/strdup.c
+ $(CC) $(CFLAGS) $?
+strerror.o: $(srcdir)/clib/strerror.c
+ $(CC) $(CFLAGS) $?
+strpbrk.o: $(srcdir)/clib/strpbrk.c
+ $(CC) $(CFLAGS) $?
+strsep.o: $(srcdir)/clib/strsep.c
+ $(CC) $(CFLAGS) $?
+strtol.o: $(srcdir)/clib/strtol.c
+ $(CC) $(CFLAGS) $?
+strtoul.o: $(srcdir)/clib/strtoul.c
+ $(CC) $(CFLAGS) $?
+vsnprintf.o: $(srcdir)/clib/vsnprintf.c
+ $(CC) $(CFLAGS) $?
View
105 usr.bin/vi/build/Makefile.in
@@ -1,10 +1,13 @@
-# @(#)Makefile.in 8.56 (Berkeley) 5/18/96
+# @(#)Makefile.in 8.75 (Berkeley) 10/23/96
srcdir= @srcdir@/..
CC= @CC@
OPTFLAG=@OPTFLAG@
CFLAGS= -c $(OPTFLAG) @CFLAGS@ -I. -I$(srcdir)/include @CPPFLAGS@
LDFLAGS=@LDFLAGS@
+PERL= @vi_cv_path_perl@
+PERLLIB=@vi_cv_perllib@
+SHRPENV=@shrpenv@
# Objects
COBJS= addbytes.o addch.o box.o clear.o clrtobot.o clrtoeol.o \
@@ -43,23 +46,14 @@ VIOBJS= cut.o delete.o ex.o ex_abbrev.o ex_append.o ex_args.o ex_argv.o \
all: nvi @tknvi@
NVIALL= $(CLOBJS) $(VIOBJS) @cobjs@ @LIBOBJS@
-nvi: $(NVIALL)
- $(CC) $(LDFLAGS) -o $@ $(NVIALL) @LIBS@
- rm -f nex
+nvi nex: $(NVIALL)
+ $(SHRPENV) $(CC) $(LDFLAGS) -o $@ $(NVIALL) @LIBS@
+ -rm -f nex
ln $@ nex
TKALL= $(TKOBJS) $(VIOBJS) @LIBOBJS@
tknvi: $(TKALL)
- $(CC) $(LDFLAGS) -o $@ $(TKALL) @TKLIBS@
-
-clean:
- -rm -f nex nvi tknvi core *.core *.o
- rm -f $(COBJS) $(CLOBJS) $(DBOBJS) $(REOBJS)
- rm -f $(TKOBJS) $(VIOBJS)
-
-distclean: clean
- rm -f Makefile pathnames.h port.h
- rm -f config.cache config.h config.log config.status
+ $(SHRPENV) $(CC) $(LDFLAGS) -o $@ $(TKALL) @TKLIBS@
chmod= @vi_cv_path_chmod@
cp= @vi_cv_path_cp@
@@ -83,7 +77,7 @@ transform=@program_transform_name@
install: all install_common
@echo "Installing vi, ex, view: $(bindir) ..."
[ -d $(bindir) ] || \
- $(mkdir) $(bindir) && $(chmod) $(dmode) $(bindir)
+ ($(mkdir) $(bindir) && $(chmod) $(dmode) $(bindir))
cd $(bindir) && $(rm) -f `echo vi | sed '$(transform)'`
$(cp) nvi $(bindir)/`echo vi | sed '$(transform)'`
cd $(bindir) && [ -f $(strip) ] && \
@@ -96,9 +90,9 @@ install: all install_common
cd $(bindir) && $(ln) \
`echo vi | sed '$(transform)'` `echo view | sed '$(transform)'`
[ -d $(mandir) ] || \
- $(mkdir) $(mandir) && $(chmod) $(dmode) $(mandir)
+ ($(mkdir) $(mandir) && $(chmod) $(dmode) $(mandir))
[ -d $(mandir)/cat1 ] || \
- $(mkdir) $(mandir)/cat1 && $(chmod) $(dmode) $(mandir)/cat1
+ ($(mkdir) $(mandir)/cat1 && $(chmod) $(dmode) $(mandir)/cat1)
@echo "Installing man pages: $(mandir) ..."
cd $(mandir)/cat1 && $(rm) -f `echo vi.0 | sed '$(transform)'`
$(cp) $(srcdir)/docs/USD.doc/vi.man/vi.0 \
@@ -111,7 +105,7 @@ install: all install_common
cd $(mandir)/cat1 && $(ln) \
`echo vi.0 | sed '$(transform)'` `echo view.0 | sed '$(transform)'`
[ -d $(mandir)/man1 ] || \
- $(mkdir) $(mandir)/man1 && $(chmod) $(dmode) $(mandir)/man1
+ ($(mkdir) $(mandir)/man1 && $(chmod) $(dmode) $(mandir)/man1)
cd $(mandir)/man1 && $(rm) -f `echo vi.1 | sed '$(transform)'`
$(cp) $(srcdir)/docs/USD.doc/vi.man/vi.1 \
$(mandir)/man1/`echo vi.1 | sed '$(transform)'`
@@ -123,7 +117,7 @@ install: all install_common
cd $(mandir)/man1 && $(ln) \
`echo vi.1 | sed '$(transform)'` `echo view.1 | sed '$(transform)'`
-cat= dutch english german ru_SU.KOI8-R swedish
+cat= dutch english french german ru_SU.KOI8-R spanish swedish
install_common:
[ -f $(chmod) ]
[ -f $(cp) ]
@@ -131,11 +125,11 @@ install_common:
[ -f $(mkdir) ]
[ -f $(rm) ]
[ -d $(prefix) ] || \
- $(mkdir) $(prefix) && $(chmod) $(dmode) $(prefix)
+ ($(mkdir) $(prefix) && $(chmod) $(dmode) $(prefix))
[ -d $(exec_prefix) ] || \
- $(mkdir) $(exec_prefix) && $(chmod) $(dmode) $(exec_prefix)
+ ($(mkdir) $(exec_prefix) && $(chmod) $(dmode) $(exec_prefix))
[ -d $(datadir) ] || \
- $(mkdir) $(datadir) && $(chmod) $(dmode) $(datadir)
+ ($(mkdir) $(datadir) && $(chmod) $(dmode) $(datadir))
$(rm) -rf $(datadir)/vi
$(mkdir) $(datadir)/vi && $(chmod) $(dmode) $(datadir)/vi
@echo "Installing message catalogs: $(datadir)/vi/catalog ..."
@@ -143,14 +137,55 @@ install_common:
$(chmod) $(dmode) $(datadir)/vi/catalog
(cd $(srcdir)/catalog && $(cp) $(cat) $(datadir)/vi/catalog && \
cd $(datadir)/vi/catalog && $(chmod) $(fmode) *)
- @echo "Installing Perl5 scripts: $(datadir)/vi/perl ..."
+ @echo "Installing Perl scripts: $(datadir)/vi/perl ..."
$(mkdir) $(datadir)/vi/perl && $(chmod) $(dmode) $(datadir)/vi/perl
+ [ -f VI.pm ] && $(cp) VI.pm $(datadir)/vi/perl && \
+ cd $(datadir)/vi/perl && $(chmod) $(fmode) VI.pm)
(cd $(srcdir)/perl_scripts && $(cp) *.pl $(datadir)/vi/perl && \
cd $(datadir)/vi/perl && $(chmod) $(fmode) *.pl)
@echo "Installing Tcl scripts: $(datadir)/vi/tcl ..."
$(mkdir) $(datadir)/vi/tcl && $(chmod) $(dmode) $(datadir)/vi/tcl
(cd $(srcdir)/tcl_scripts && $(cp) *.tcl $(datadir)/vi/tcl && \
cd $(datadir)/vi/tcl && $(chmod) $(fmode) *.tcl)
+ @echo "Installing recover script: $(datadir)/vi/recover ..."
+ ($(cp) recover $(datadir)/vi/recover && \
+ $(chmod) $(emode) $(datadir)/vi/recover)
+
+uninstall:
+ $(rm) -rf $(datadir)/vi
+ cd $(bindir) && $(rm) -f `echo ex | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo vi | sed '$(transform)'`
+ cd $(bindir) && $(rm) -f `echo view | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo ex.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo vi.0 | sed '$(transform)'`
+ cd $(mandir)/cat1 && $(rm) -f `echo view.0 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo ex.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo vi.1 | sed '$(transform)'`
+ cd $(mandir)/man1 && $(rm) -f `echo view.1 | sed '$(transform)'`
+
+docs:
+ cd $(srcdir)/docs/USD.doc/vi.ref && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/vi.man && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/edit && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/exref && $(MAKE)
+ cd $(srcdir)/docs/USD.doc/vitut && $(MAKE)
+
+clean:
+ -rm -f *.core *.o memcpy.c perl.c
+ -rm -f nex nvi tknvi core
+ -rm -f $(COBJS) $(CLOBJS) $(DBOBJS) $(REOBJS)
+ -rm -f $(TKOBJS) $(VIOBJS)
+
+cleandocs:
+ cd $(srcdir)/docs/USD.doc/vi.ref && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/vi.man && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/edit && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/exref && $(MAKE) clean
+ cd $(srcdir)/docs/USD.doc/vitut && $(MAKE) clean
+
+distclean maintainer-clean realclean: clean cleandocs
+ -rm -f Makefile config.cache config.h config.log config.status
+ -rm -f pathnames.h port.h
# Vi curses sources.
cl_bsd.o: $(srcdir)/cl/cl_bsd.c
@@ -183,7 +218,15 @@ tk_util.o: $(srcdir)/tk/tk_util.c
# Vi Tcl/Perl interpreter sources.
api.o: $(srcdir)/common/api.c
$(CC) $(CFLAGS) $?
-perl.o: $(srcdir)/perl_api/perl.c
+perl.c: $(srcdir)/perl_api/perl.xs $(srcdir)/perl_api/typemap
+ echo "#define _PATH_PERLSCRIPTS \"$(datadir)/vi/perl\"" > $@
+ $(PERL) $(PERLLIB)/ExtUtils/xsubpp -typemap \
+ $(PERLLIB)/ExtUtils/typemap $(srcdir)/perl_api/perl.xs >> $@
+ ($(PERL) -ne 'print "sub $$1 {\$$curscr->$$1(\@_)}\n" \
+ if /newXS\("VI::([^":]*)"/;' $@ ; echo "1;") > VI.pm
+perl.o: perl.c
+ $(CC) $(CFLAGS) $?
+perlsfio.o: $(srcdir)/perl_api/perlsfio.c
$(CC) $(CFLAGS) $?
tcl.o: $(srcdir)/tcl_api/tcl.c
$(CC) $(CFLAGS) $?
@@ -532,15 +575,14 @@ rec_utils.o: $(srcdir)/db/recno/rec_utils.c
$(CC) -D__DBINTERFACE_PRIVATE $(CFLAGS) -I$(srcdir)/db/recno $?
# Regular Expressions sources.
-RINC= -I$(srcdir)/regex
regcomp.o: $(srcdir)/regex/regcomp.c
- $(CC) -D__REGEX_PRIVATE $(CFLAGS) $(RINC) $?
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
regerror.o: $(srcdir)/regex/regerror.c
- $(CC) -D__REGEX_PRIVATE $(CFLAGS) $(RINC) $?
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
regexec.o: $(srcdir)/regex/regexec.c
- $(CC) -D__REGEX_PRIVATE $(CFLAGS) $(RINC) $?
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
regfree.o: $(srcdir)/regex/regfree.c
- $(CC) -D__REGEX_PRIVATE $(CFLAGS) $(RINC) $?
+ $(CC) -D__REGEX_PRIVATE $(CFLAGS) $?
# Random replacement and workaround sources.
addnstr.o: $(srcdir)/clib/addnstr.c
@@ -557,6 +599,9 @@ getopt.o: $(srcdir)/clib/getopt.c
$(CC) $(CFLAGS) $(INC) $?
memchr.o: $(srcdir)/clib/memchr.c
$(CC) $(CFLAGS) $?
+memcpy.o: $(srcdir)/clib/memmove.c
+ $(cp) $? memcpy.c
+ $(CC) $(CFLAGS) -DMEMCOPY memcpy.c
memmove.o: $(srcdir)/clib/memmove.c
$(CC) $(CFLAGS) -DMEMMOVE $?
memset.o: $(srcdir)/clib/memset.c
@@ -581,3 +626,5 @@ strtol.o: $(srcdir)/clib/strtol.c
$(CC) $(CFLAGS) $?
strtoul.o: $(srcdir)/clib/strtoul.c
$(CC) $(CFLAGS) $?
+vsnprintf.o: $(srcdir)/clib/vsnprintf.c
+ $(CC) $(CFLAGS) $?
View
102 usr.bin/vi/build/README
@@ -1,4 +1,4 @@
-# @(#)README 8.20 (Berkeley) 5/12/96
+# @(#)README 8.26 (Berkeley) 10/19/96
Nvi uses the GNU autoconf program for configuration and compilation. You
should enter:
@@ -8,25 +8,20 @@ should enter:
and nvi will configure the system and build one or two binaries: nvi and
tknvi. You can use any path to the configure script, e.g., to build for
-an x86 architecture, you might do:
+an x86 architecture, I suggest that you do:
mkdir build.x86
cd build.x86
../build/configure
make
-If you're only building nvi for a single architecture, you can just use
-the path ./configure, and build it in this directory.
-
There are options that you can specify to the configure command. See
the next section for a description of these options.
If you want to rebuild or reconfigure nvi, for example, because you change
-your mind as to the curses library that you want to use, enter:
-
- make distclean
-
-and then reconfigure using "configure" and whatever options you choose.
+your mind as to the curses library that you want to use, create a new
+directory and reconfigure it using "configure" and whatever options you
+choose, don't try to selectively edit the files.
By default, nvi is installed as "vi", with hard links to "ex" and "view".
To install them using different names, use the configure program options.
@@ -36,6 +31,10 @@ For example, to install them as "nvi", "nex" and "nview", use:
See the section below on installation for details.
+Note, if you're building nvi on a LynxOS system, you should read the
+README.LynxOS file in this directory for additional build instructions
+that are specific to that operating system.
+
If you have trouble with this procedure, send email to the addresses
listed in ../README. In that email, please provide a complete script
of the output for all of the above commands that you entered.
@@ -134,13 +133,21 @@ enable-tknvi:
see the next section of this README file for more information.
=-=-=-=-=-=-=
-ADDING OR CHANGING COMPILE OR LOAD LINE FLAGS
+ADDING OR CHANGING COMPILERS, OR COMPILE OR LOAD LINE FLAGS
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+If you want to use a specific compiler, specify the CC environment
+variable before running configure. For example:
+
+ env CC=gcc configure
+
+Using anything other than the native compiler will almost certainly
+mean that you'll want to check the compile and load line flags, too.
+
If you want to specify additional load line flags, specify the ADDLDFLAGS
environment variable before running configure. For example:
- env ADDLDFLAGS="-Q" ./configure
+ env ADDLDFLAGS="-Q" configure
would specify the -Q flag in the load line when the nvi programs are
loaded.
@@ -149,7 +156,7 @@ If you don't want configure to use the default load line flags for the
system, specify the LDFLAGS environment variable before running configure.
For example:
- env LDFLAGS="-32" ./configure
+ env LDFLAGS="-32" configure
will cause configure to set the load line flags to "-32", and not set
them based on the current system.
@@ -157,7 +164,7 @@ them based on the current system.
If you want to specify additional compile line flags, specify the
ADDCPPFLAGS environment variable before running configure. For example:
- env ADDCPPFLAGS="-I../foo" ./configure
+ env ADDCPPFLAGS="-I../foo" configure
would cause the compiler to be passed the -I../foo flag when compiling
test programs during configuration as well as when building nvi object
@@ -167,7 +174,7 @@ If you don't want configure to use the default compile line flags for the
system, specify the CPPFLAGS environment variable before running configure.
For example:
- env CPPFLAGS="-I.." ./configure
+ env CPPFLAGS="-I.." configure
will cause configure to use "-I.." as the compile line flags instead of
the default values.
@@ -183,7 +190,7 @@ they can be found.
If you want to specify additional library paths, set the ADDLIBS environment
variable before running configure. For example:
- env ADDLIBS="-L/a/b -L/e/f -ldb" ./configure
+ env ADDLIBS="-L/a/b -L/e/f -ldb" configure
would specify two additional directories to search for libraries, /a/b
and /e/f, and one additional library to load, "db".
@@ -191,7 +198,7 @@ and /e/f, and one additional library to load, "db".
If you want to specify additional include paths, specify the ADDCPPFLAGS
environment variable before running configure. For example:
- env ADDCPPFLAGS="-I/usr/local/include" LIBS="-ldb" ./configure
+ env ADDCPPFLAGS="-I/usr/local/include" LIBS="-ldb" configure
would search /usr/local/include for include files, as well as load the db
library as described above.
@@ -201,7 +208,7 @@ and you've built it in a directory named ncurses which is at the same
level in the filesystem hierarchy as nvi. You would enter something like:
env ADDCPPFLAGS="-I../../ncurses/include" \
- ADDLIBS="-L../../ncurses/libraries" ./configure
+ ADDLIBS="-L../../ncurses/libraries" configure
to cause nvi to look for the curses include files and the curses library
in the ncurses environment.
@@ -248,12 +255,12 @@ Notes:
variables in your shell before running configure. For example,
in sh or ksh, you could do:
- ADDLIBS="-L/a/b -L/e/f -ldb" ./configure
+ ADDLIBS="-L/a/b -L/e/f -ldb" configure
and in csh or tcsh, you could do:
setenv ADDLIBS "-L/a/b -L/e/f -ldb"
- ./configure
+ configure
See your shell manual page for further information.
@@ -264,47 +271,41 @@ INSTALLING NVI
Nvi installs the following files into the following locations, with
the following default values:
-File(s): Location
- Default Location
-----------------------------------------
-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/
+Variables: Default value:
+prefix /usr/local
+exec_prefix $(prefix)
+bindir $(prefix)/bin
+datadir $(prefix)/share
+mandir $(prefix)/man
-Tcl scripts $(prefix)/$(datadir)/vi/tcl/
- /usr/local/share/vi/tcl/
+File(s): 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/
Notes:
There are two hard links to the vi program, named ex and view.
- 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.
+ 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.
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 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:
+ 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:
configure --exec_prefix=/usr/contrib --prefix=/usr/share
@@ -316,9 +317,6 @@ 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
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
View
382 usr.bin/vi/build/README.LynxOS
@@ -1,76 +1,320 @@
-This file describes how to build and install NVI 1.65 (or later) for the
-LynxOS 2.4.0 operating system.
-
-Note that even though LynxOS 2.4.0 is available for a variety of different
-hardware platforms, I personally have only tried building NVI on LynxOS/x86
-(2.4.0 version), so that is the only platform that I am sure that you can
-build NVI on at the present time, however I know of no reason why these
-procedures should not work also when attempting to build NVI on other LynxOS
-hardware platforms (e.g. Sparc, PowerPC, and mc68000).
-
-Also note that these procedures may not work on versions of LynxOS prior
-to 2.4.0. (As I understand it, a good deal of work went into making the
-2.4.0 release more POSIX-compliant, and I have no idea what building glitches
-you might run into if you try to build NVI on a pre-2.4.0 version of LynxOS.)
-
-Anyway, the most important consideration when building NVI on LynxOS is
-your selection of a C compiler. DO NOT try to use either the /bin/cc or
-the /bin/gcc compiler (i.e. GCC version 1.42) to build NVI. These two
-compilers are ancient, crusty, buggy, and should probably not be used for
-any actual compiling of any actual C code. Rather than using either of
-these two C compilers, I strongly advise you to use the C compiler which
-is normally installed (on LynxOS 2.4.0) as:
-
- /cygnus/94q4-lynxos-x86/bin/gcc
-
-You can probably just setup your $PATH (*before* you do the configure step
-for NVI) so that this compiler will appear in your path before the /bin/cc
-and /bin/gcc compilers, but I personally would take no chances. What _I_
-did when _I_ built NVI was the following:
+README.LynxOS
+=============
+
+Written by Ronald F. Guilmette <rfg@monkeys.com>
+
+Last modified Wed Aug 14 23:10:07 PDT 1996
+------------------------------------------
+
+0. Introduction
+---------------
+
+This file describes how to build and install the Berkeley nvi editor for
+the LynxOS 2.4.0 operating system.
+
+LynxOS 2.4.0 is available for a variety of different hardware platforms, in
+particular, x86, m680x0, Sparc, and PowerPC. I have successfully built nvi
+on all four of these flavors of LynxOS by following the procedures given in
+this file.
+
+Note that these procedures may not work on versions of LynxOS prior to 2.4.0.
+(As I understand it, a good deal of work went into making the 2.4.0 release
+more POSIX-compliant, and I have no idea what build glitches, if any, you
+might encounter if you try to build nvi on a pre-2.4.0 version of LynxOS.)
+
+There are basically four steps to configuring, building, and installing nvi
+on LynxOS, namely:
+
+ 1. Get setup to use the proper C compiler.
+ 2. Replace your installed `tr' program.
+ 3. Fix your system include files.
+ 4. Do a normal configure, build, and install of nvi.
+
+These steps are described in separate sections below.
+
+1. Get Setup to Use the Proper C Compiler
+------------------------------------------
+
+The first step when building nvi on LynxOS is to set your $PATH environment
+variable properly so that the gcc 2.x compiler appears first on your path,
+prior to the older (and less robust) gcc 1.xx compiler (typically installed
+as /bin/gcc) and/or the old Lynx proprietary C compiler (typically installed
+as /bin/cc), both of which may also be present on your system.
+
+Note that for most operating systems, the configure script for nvi tries
+to use whatever compiler you have installed (and in your $PATH) as "cc",
+however in the special case of LynxOS, the configure script will auto-
+matically try to find a "gcc" program on your $PATH in preference to a
+compiler called "cc". If the nvi configure script only find a compiler
+called "cc", that's OK. It will still try to see if that is really just
+the GNU C compiler installed under the name "cc".
+
+Regardless of the name however (be it "gcc" or "cc") the first C compiler
+in your $PATH should be some _recent_ (i.e. 2.0 or later) version of the
+GNU C compiler... and the nvi configure script now checks that this is the
+case, and fails if it isn't.
+
+Oddly enough, LynxOS 2.4.0 (and some prior versions) shipped with as many
+as three different C compilers installed, so it is important to set your
+$PATH environment variable carfully in order to get the proper C compiler
+to appear first in your $PATH. You want to avoid having either the /bin/gcc
+compiler or the /bin/cc compiler be the first C compiler in your $PATH.
+
+To make sure that the GNU C version 2.x compiler which was shipped with your
+LynxOS system appears first on your path, you will need to either set your
+$PATH variable (for sh/bash/ksh users) or your $path variable (for csh/tcsh
+users). You can, of course, just do this at the shell command prompt, but
+it is probably better to actually edit this change into your .profile file
+(for sh/bash/ksh users) or into your .cshrc file (for csh/tcsh users).
+
+The pathname of the directory that contains the GNU C version 2.x compiler
+is (unfortunately) dependent upon the exact type of LynxOS system you have.
+
+For LynxOS 2.4.0 on x86 systems, gcc 2.x is located in:
+
+ /cygnus/94q4-lynxos-x86/bin
+
+For LynxOS 2.4.0 on m680x0 systems, gcc 2.x is located in:
+
+ /cygnus/94q4-lynxos-68k/bin
+
+For LynxOS 2.4.0 on Sparc systems, gcc 2.x is located in:
+
+ /cygnus/94q4-lynxos-usparc/bin
+
+For LynxOS 2.4.0 on PowerPC systems, gcc 2.x is located in:
+
+ /cygnus/95q2-lynxos-ppc/bin
+
+(Note also that these locations may change in LynxOS 2.5.x and beyond.)
+
+Anyway, it is imperative that you setup your $PATH environment variable
+(*before* you do the configure step for nvi) so that the GNU C version 2.x
+compiler appears in your $PATH before either the /bin/cc or /bin/gcc
+compilers (if present). If you fail to do this, the configure step for
+nvi will fail, because the compiler script actually checks (now) that the
+compiler you are using (if your are on a LynxOS system) is gcc 2.0 or
+later.
+
+To make absolutely sure that you will be configuring and building nvi with
+the proper C compiler (i.e. the GNU C version 2.x compiler on your system)
+you should add the directory name listed above for your specific system type
+to your $PATH setting in your $HOME/.profile file. (For csh/tcsh users, you
+will instead want to add the relevant directory name to the setting of your
+$path variable in your ~/.cshrc file.) Once you have added the proper direc-
+tory name (from the list given above) to your $HOME/.profile file (or to your
+~/.cshrc file, if you are using csh or tcsh) you should log out completely
+and then log back into the system just to make sure your new $PATH/$path
+setting takes effect properly.
+
+When you finish making this adjustment to your $PATH (or $path), the most
+up-to-date version of gcc on your system should be available to you as the
+first `gcc' program on your $PATH. You should verify that this is indeed the
+case simply by typing `gcc -v' and then checking the version number reported
+by the compiler. It should say either "2.6-94q4" or (on PowerPC systems) it
+should say "2.6-95q2". If you don't get these results, try again to set your
+$PATH (or $path) until you do. You won't be able to build nvi until you are
+properly setup to use gcc version 2.0 or later.
+
+Performing the steps shown above will insure that your subsequent configura-
+tion and build steps for nvi will make use of the most up-to-date version of
+gcc that was shipped with your Lynx operating system. (Note that the versions
+of gcc which are currently shipping with LynxOS 2.4.0 are also somewhat out-
+of-date themselves, but they are still quite a bit newer and more bug-free
+and ANSI conformant that those other two C compilers, /bin/cc and /bin/gcc,
+which also ship with LynxOS 2.4.0.)
+
+(Note: At present, LynxOS version 2.4.0 is the latest officially released
+version of LynxOS, and all of the above information is accurate and correct
+for LynxOS 2.4.0 as of the time of this writing. However it is rumored that
+future releases of LynxOS may provide a still newer version of gcc, and that
+it may be located in the /usr/bin directory. Thus, if you are building nvi
+for some LynxOS version later than 2.4.0, you may wish to check and see if
+your system has a program called /usr/bin/gcc, and use that version of gcc,
+if available, rather than the one suggested above.)
+
+2. Replace Your Installed `tr' Program
+---------------------------------------
+
+The `tr' program which comes bundled with LynxOS 2.4.0 (as /bin/tr) has a
+somewhat obscure bug which just happens to be tickled by almost all GNU
+`autoconf' generated `configure' scripts (including the one that nowadays
+comes bundled with nvi). Using the stock /bin/tr program on LynxOS when
+executing such `configure' scripts _will_ cause these scripts to malfunction
+in various ways. It is therefore imperative that you replace your LynxOS
+/bin/tr program with a properly working version of the `tr' command _before_
+you even try to configure nvi. (You can tell if your `tr' program has the
+bug by executng the command "echo ab- | tr ab- ABC". If this yields the
+string "Ab-" then you have the bug. If it yields "ABC" then you don't.)
+
+You can obtain sources for a working version of the `tr' command as part of
+the GNU `textutils' package (the latest version of which, at the time of this
+writing, is 1.19). The GNU textutils package is available for downloading
+from prep.ai.mit.edu in the pub/gnu directory. Look for the file named
+textutils-1.19.tar.gz, or an even more recent version of textutils, if one
+is available. Fetch it, gunzip it, untar it, and follow the directions in
+the INSTALL file included in the tar file to build and install the entire
+textutils set of utility programs (which includes a working `tr' program).
+Then just make sure that the GNU version of `tr' appears on your $PATH
+_before_ the LynxOS version of `tr' (i.e. /bin/tr). Be sure to do this
+step _before_ you start to configure nvi.
+
+When building the textutils set of programs, I suggest that you use the most
+up-to-date C compiler available on your system (as described above). Also,
+note that it will be important for you to AVOID using the -O (optimize)
+compiler option when building the GNU textutils package, even if you are
+using the most up-to-date version of gcc which shipped with your system.
+If you try to use -O when building the textutils package on an x86 with
+the Cygnus 94q4 C compiler, you will end up with a `tr' program which will
+malfunction even worse than the one you are trying to replace! If you use
+-O when building the textutils package on LynxOS on the PowerPC (using the
+Cygnus 95q2 C compiler) you will just get yourself a compiler crash. So
+just don't use -O when building textutils. You can avoid using -O by in-
+voking make in the textutils directory as follows:
+
+ make CFLAGS="-g"
+
+(Note: At present, LynxOS version 2.4.0 is the latest officially released
+version of LynxOS, and all of the above information is accurate and correct
+for LynxOS 2.4.0 as of the time of this writing. However it is rumored that
+the bug in the /bin/tr program will be fixed in future releases of LynxOS,
+so if you have a version of LynxOS later than 2.4.0, you may wish to check
+and see if your /bin/tr program even has the problematic bug before bothering
+with all of this.)
+
+
+3. Fix Your System Include Files
+---------------------------------
+
+If you are building nvi on a PowerPC system, it is also important that you
+apply the patches given at the end of this file to your /usr/include files.
+(Note that you will have to be root in order to do this.) Two of the patches
+included below fix a pair of serious bugs in the /usr/include/stdarg.h file
+on the PowerPC, and you really _do_ want to have these bugs fixed anyway,
+because without these fixes, anything that you compile which uses <stdarg.h>
+will very likely malfunction at run-time.
+
+Regardless of which LynxOS platform you are using (i.e. x86, PowerPC, Sparc,
+or m680x0) you may want to apply all of the system include files patches that
+are included below anyway. Doing so will clean up a few minor problems with
+the relevant system include files (i.e. <stdarg.h>, <ioctl.h>, and <wait.h>)
+and this step will also prevent a few warnings which you would otherwise get
+during the build of nvi.
+
+You can apply all of the patches given at the end of this file simply by
+doing the following:
su root
- cd /bin
- mv cc cc.save
- ln -s /cygnus/94q4-lynxos-x86/bin/gcc ./cc
- mv gcc gcc.save
- ln -s /cygnus/94q4-lynxos-x86/bin/gcc ./gcc
-
-This will insure that anything you compile from now on *will* be compiled
-with the Cygnus 94q4 version of GCC. (This compiler is also rather old,
-but it is still newer and more bug-free and more ANSI conformant that those
-other two C compilers which currently ship with LynxOS.)
-
-Anyway, that's the most important thing about building NVI 1.65 (or later)
-on LynxOS 2.4.0. Make sure that you use a decent C compiler. If you are
-building NVI version 1.65.alpha, then write to me at the address below and
-I will send you the patches you will need to configure & build NVI 1.65.alpha
-for LynxOS 2.4.0. If you are building some later version of NVI, you may
-not even need any patches (but that is up to Keith Bostic).
-
-A final note: You may (and probably will) get a number of warnings during
-your build of NVI which claim that the types of one or more parameters given
-in calls to the following functions are incorrect pointer types:
-
- bcopy
- wait
- waitpid
- ioctl
- db_eget
- db_get
-
-These warnings are to be expected. They are (I believe) just due to some
-small and insignificant bugs in the LynxOS 2.4.0 system include files, and
-these warnings should not concern you. Also, you will probably get two
-warnings when compiling the file vi/v_txt.c, both of which will say some-
-thing like ``comparison of distinct pointer types lacks a cast''. I haven't
-really looked into this problem yet, but they are only warnings, and I
-believe that they are probably benign.
-
-Please contact me at the address below if you find any bugs in the LynxOS
-port of NVI. Thanks.
+ cd /usr/include
+ /bin/patch < this-file
+
+Where `this-file' is the actual full pathname of the file you are now reading,
+wherever it may reside on your own system.
+
+(Note: At present, LynxOS version 2.4.0 is the latest officially released
+version of LynxOS, and all of the above information is accurate and correct
+for LynxOS 2.4.0 as of the time of this writing. However it is rumored that
+future releases of LynxOS may incorporate some or all of the important system
+include file fixes provided below. Thus, if you are building nvi for some
+LynxOS version later than 2.4.0, you should probably go ahead and try to
+apply the patches given below to your system include files, and then just
+don't worry about it if these patches seem to have already been applied.)
+
+
+4. A Brief Note about Sendmail
+-------------------------------
+
+I should mention also that LynxOS does not normally ship with the `sendmail'
+mail transfer program installed, either under /usr/lib/ or anywhere else for
+that matter. This isn't really a big problem, but nvi normally wants and
+expects to have a sendmail program available so that it can send users notifi-
+cations (by mail) whenever a partially edited file is preserved by the editor
+in response to a sudden system crash, a sudden system shutdown, or an unexpect-
+ed serial-line hangup. You can configure and build nvi without any sendmail
+program installed on your system, but you will get warnings about its absence
+when you are doing the initial configure step prior to actually building nvi.
+If you want to have a fully-functional nvi which does send out notification
+messages (by mail) whenever partially edited files are preserved during a
+serial line hangup or system crash, then you should get the BSD sendmail
+sources (via ftp from ftp.cs.berkeley.edu), build and install sendmail, and
+then reconfigure, rebuild, and reinstall nvi.
+
+Please contact me at the E-mail address below if you experience any problems in
+building or using nvi on LynxOS. I make no guarrantees, but I may be willing
+to try to help.
Ron Guilmette
Roseville, California
<rfg@monkeys.com>
-May 15, 1996
+August 14, 1996
+
+cut here for LynxOS 2.4.0 system include files patches
+-----------------------------------------------------------------------------
+*** wait.h Fri Apr 26 10:02:45 1996
+--- wait.h Sun May 19 05:36:50 1996
+***************
+*** 94,104 ****
+ /* Function prototypes */
+ #ifndef __LYNXOS
+- #ifdef _POSIX_SOURCE
+ extern pid_t wait _AP((int *));
+ extern pid_t waitpid _AP((pid_t, int *, int));
+! #else
+! extern int wait _AP((union wait *));
+! extern int waitpid _AP((int, union wait *, int));
+! extern int wait3 _AP((union wait *, int, struct rusage *));
+ #endif
+ #endif /* !__LYNXOS */
+--- 94,101 ----
+ /* Function prototypes */
+ #ifndef __LYNXOS
+ extern pid_t wait _AP((int *));
+ extern pid_t waitpid _AP((pid_t, int *, int));
+! #ifndef _POSIX_SOURCE
+! extern int wait3 _AP((int *, int, struct rusage *));
+ #endif
+ #endif /* !__LYNXOS */
+*** ioctl.h Fri Apr 26 16:50:51 1996
+--- ioctl.h Sat May 18 17:55:16 1996
+***************
+*** 572,576 ****
+
+ #ifndef __LYNXOS
+! extern int ioctl _AP((int, int, char *));
+ #endif
+
+--- 572,576 ----
+
+ #ifndef __LYNXOS
+! extern int ioctl _AP((int, int, ...));
+ #endif
+
+*** stdarg.h Fri Apr 26 16:51:02 1996
+--- stdarg.h Sat May 18 19:34:13 1996
+***************
+*** 88,92 ****
+ (((sizeof(TYPE) + sizeof(int) - 1) / sizeof(int)) * sizeof(int))
+
+! #define va_start(AP, LASTARG) (AP = ((char *) __builtin_next_arg ()))
+
+ void va_end(va_list); /* Defined in libgcc.a */
+--- 88,92 ----
+ (((sizeof(TYPE) + sizeof(int) - 1) / sizeof(int)) * sizeof(int))
+
+! #define va_start(AP, LASTARG) (AP = ((char *) __builtin_next_arg (LASTARG)))
+
+ void va_end(va_list); /* Defined in libgcc.a */
+***************
+*** 162,166 ****
+ (((sizeof(TYPE) + sizeof(int) - 1) / sizeof(int)) * sizeof(int))
+
+! #define va_start(AP, LASTARG) (AP = ((char *) __builtin_next_arg ()))
+
+ void va_end(va_list); /* Defined in libgcc.a */
+--- 162,166 ----
+ (((sizeof(TYPE) + sizeof(int) - 1) / sizeof(int)) * sizeof(int))
+
+! #define va_start(AP, LASTARG) (AP = ((char *) __builtin_next_arg (LASTARG)))
+
+ void va_end(va_list); /* Defined in libgcc.a */
View
6 usr.bin/vi/build/acconfig.h
@@ -1,4 +1,4 @@
-/* @(#)acconfig.h 8.15 (Berkeley) 4/15/96 */
+/* @(#)acconfig.h 8.18 (Berkeley) 7/2/96 */
/* Define to `int' if <sys/types.h> doesn't define. */
#undef ssize_t
@@ -57,8 +57,8 @@
/* Define if you want to compile in the Perl interpreter. */
#undef HAVE_PERL_INTERP
-/* Define if your Perl is at least 5.002_01. */
-#undef HAVE_PERL_5_002_01
+/* Define if your Perl is at least 5.003_01. */
+#undef HAVE_PERL_5_003_01
/* Define if you have the Berkeley style revoke(2) system call. */
#undef HAVE_REVOKE
View
17 usr.bin/vi/build/aclocal.m4
@@ -0,0 +1,17 @@
+AC_DEFUN(AM_SANITY_CHECK_CC,
+[dnl Derived from macros from Bruno Haible and from Cygnus.
+AC_MSG_CHECKING([whether the compiler ($CC $CFLAGS $LDFLAGS) actually works])
+AC_LANG_SAVE
+ AC_LANG_C
+ AC_TRY_RUN([main() { exit(0); }],
+ am_cv_prog_cc_works=yes, am_cv_prog_cc_works=no,
+ dnl When crosscompiling, just try linking.
+ AC_TRY_LINK([], [], am_cv_prog_cc_works=yes,
+ am_cv_prog_cc_works=no))
+AC_LANG_RESTORE
+case "$am_cv_prog_cc_works" in
+ *no) AC_MSG_ERROR([Installation or configuration problem: C compiler cannot create executables.]) ;;
+ *yes) ;;
+esac
+AC_MSG_RESULT(yes)
+])dnl
View
36 usr.bin/vi/build/config.guess
@@ -156,7 +156,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX '
- i[34]86:AIX:*:*)
+ i?86:AIX:*:*)
echo i386-ibm-aix
exit 0 ;;
*:AIX:2:3)
@@ -303,7 +303,7 @@ EOF
hp3[0-9][05]:NetBSD:*:*)
echo m68k-hp-netbsd${UNAME_RELEASE}
exit 0 ;;
- i[34]86:BSD/386:*:* | *:BSD/OS:*:*)
+ i?86:BSD/386:*:* | *:BSD/OS:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
exit 0 ;;
*:FreeBSD:*:*)
@@ -319,11 +319,11 @@ EOF
# The BFD linker knows what the default object file format is, so
# first see if it will tell us.
ld_help_string=`ld --help 2>&1`
- if echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: elf_i[345]86"; then
+ if echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: elf_i?86"; then
echo "${UNAME_MACHINE}-unknown-linux" ; exit 0
- elif echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: i[345]86linux"; then
+ elif echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: i?86linux"; then
echo "${UNAME_MACHINE}-unknown-linuxaout" ; exit 0
- elif echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: i[345]86coff"; then
+ elif echo $ld_help_string | grep >/dev/null 2>&1 "supported emulations: i?86coff"; then
echo "${UNAME_MACHINE}-unknown-linuxcoff" ; exit 0
elif test "${UNAME_MACHINE}" = "alpha" ; then
echo alpha-unknown-linux ; exit 0
@@ -351,17 +351,17 @@ EOF
fi ;;
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. earlier versions
# are messed up and put the nodename in both sysname and nodename.
- i[34]86:DYNIX/ptx:4*:*)
+ i?86:DYNIX/ptx:4*:*)
echo i386-sequent-sysv4
exit 0 ;;
- i[34]86:*:4.*:* | i[34]86:SYSTEM_V:4.*:*)
+ i?86:*:4.*:* | i?86:SYSTEM_V:4.*:*)
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
echo ${UNAME_MACHINE}-univel-sysv${UNAME_RELEASE}
else
echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}
fi
exit 0 ;;
- i[34]86:*:3.2:*)
+ i?86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
echo ${UNAME_MACHINE}-unknown-isc$UNAME_REL
@@ -390,7 +390,7 @@ EOF
# "miniframe"
echo m68010-convergent-sysv
exit 0 ;;
- M680[234]0:*:R3V[567]*:*)
+ M680?0:*:R3V[567]*:*)
test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
3[34]??:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0)
uname -p 2>/dev/null | grep 86 >/dev/null \
@@ -398,20 +398,20 @@ EOF
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
uname -p 2>/dev/null | grep 86 >/dev/null \
&& echo i486-ncr-sysv4 && exit 0 ;;
- m680[234]0:LynxOS:2.[23]*:*)
- echo m68k-lynx-lynxos${UNAME_RELEASE}
+ m68*:LynxOS:2.*:*)
+ echo m68k-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
- mc68030:UNIX_System_V:4.*:*)
+ mc68*:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
exit 0 ;;
- i[34]86:LynxOS:2.[23]*:*)
- echo i386-lynx-lynxos${UNAME_RELEASE}
+ i?86:LynxOS:2.*:*)
+ echo i386-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
- TSUNAMI:LynxOS:2.[23]*:*)
- echo sparc-lynx-lynxos${UNAME_RELEASE}
+ TSUNAMI:LynxOS:2.*:* | uSPARC2:LynxOS:2.*:*)
+ echo sparc-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
- rs6000:LynxOS:2.[23]*:*)
- echo rs6000-lynx-lynxos${UNAME_RELEASE}
+ PowerPC:LynxOS:2.*:*)
+ echo powerpc-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
RM*:SINIX-*:*:*)
echo mips-sni-sysv4
View
60 usr.bin/vi/build/config.h
@@ -4,9 +4,6 @@
/* Define to empty if the keyword does not work. */
/* #undef const */
-/* Define if you don't have vprintf but do have _doprnt. */
-/* #undef HAVE_DOPRNT */
-
/* Define if you have a working `mmap' system call. */
#define HAVE_MMAP 1
@@ -16,9 +13,6 @@
/* Define if you have <vfork.h>. */
/* #undef HAVE_VFORK_H */
-/* Define if you have the vprintf function. */
-#define HAVE_VPRINTF 1
-
/* Define to `int' if <sys/types.h> doesn't define. */
/* #undef mode_t */
@@ -42,7 +36,7 @@
/* Define if your processor stores words with the most significant
byte first (like Motorola and SPARC, unlike Intel and VAX). */
-#define WORDS_BIGENDIAN 1
+/* #undef WORDS_BIGENDIAN */
/* Define to `int' if <sys/types.h> doesn't define. */
/* #undef ssize_t */
@@ -98,8 +92,8 @@
/* Define if you want to compile in the Perl interpreter. */
/* #undef HAVE_PERL_INTERP */
-/* Define if your Perl is at least 5.002_01. */
-/* #undef HAVE_PERL_5_002_01 */
+/* Define if your Perl is at least 5.003_01. */
+/* #undef HAVE_PERL_5_003_01 */
/* Define if you have the Berkeley style revoke(2) system call. */
#define HAVE_REVOKE 1
@@ -119,20 +113,68 @@
/* Define if your sprintf returns a pointer, not a length. */
/* #undef SPRINTF_RET_CHARPNT */
+/* Define if you have the bsearch function. */
+#define HAVE_BSEARCH 1
+
+/* Define if you have the gethostname function. */
+#define HAVE_GETHOSTNAME 1
+
+/* Define if you have the getopt function. */
+#define HAVE_GETOPT 1
+
/* Define if you have the getpagesize function. */
#define HAVE_GETPAGESIZE 1
+/* Define if you have the memchr function. */
+#define HAVE_MEMCHR 1
+
+/* Define if you have the memcpy function. */
+#define HAVE_MEMCPY 1
+
+/* Define if you have the memmove function. */
+#define HAVE_MEMMOVE 1
+
+/* Define if you have the memset function. */
+#define HAVE_MEMSET 1
+
+/* Define if you have the mkstemp function. */
+#define HAVE_MKSTEMP 1
+
+/* Define if you have the mmap function. */
+#define HAVE_MMAP 1
+
/* Define if you have the select function. */
#define HAVE_SELECT 1
/* Define if you have the setenv function. */
#define HAVE_SETENV 1
+/* Define if you have the snprintf function. */
+#define HAVE_SNPRINTF 1
+
+/* Define if you have the strdup function. */
+#define HAVE_STRDUP 1
+
+/* Define if you have the strerror function. */
+#define HAVE_STRERROR 1
+
+/* Define if you have the strpbrk function. */
+#define HAVE_STRPBRK 1