home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1994 March / Source_Code_CD-ROM_Walnut_Creek_March_1994.iso / compsrcs / misc / volume33 / xvi / part18 < prev    next >
Encoding:
Text File  |  1992-11-01  |  39.4 KB  |  1,391 lines

  1. Newsgroups: comp.sources.misc
  2. From: jmd@cyclone.bt.co.uk (John Downey)
  3. Subject:  v33i027:  xvi - portable multi-window vi-like editor, Part18/18
  4. Message-ID: <1992Oct24.172557.2598@sparky.imd.sterling.com>
  5. X-Md4-Signature: 847c823c0e17dfdcf055976349680ffd
  6. Date: Sat, 24 Oct 1992 17:25:57 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: jmd@cyclone.bt.co.uk (John Downey)
  10. Posting-number: Volume 33, Issue 27
  11. Archive-name: xvi/part18
  12. Environment: Unix, MS-DOS, OS/2, QNX
  13.  
  14. #! /bin/sh
  15. # This is a shell archive.  Remove anything before this line, then feed it
  16. # into a shell via "sh file" or similar.  To overwrite existing files,
  17. # type "sh file -c".
  18. # Contents:  xvi/doc/README xvi/src/8086mm.inc xvi/src/i286.asm
  19. #   xvi/src/ibmpc.h xvi/src/makefile.bsd xvi/src/makefile.qn4
  20. #   xvi/src/makefile.qnx xvi/src/makefile.sun xvi/src/makefile.sv
  21. #   xvi/src/makefile.tos xvi/src/makefile.ult xvi/src/makefile.usg
  22. #   xvi/src/makefile.xen xvi/src/pc386.h xvi/src/ptrfunc.h
  23. #   xvi/src/version.c xvi/src/xvi.icn
  24. # Wrapped by kent@sparky on Thu Oct 22 09:03:45 1992
  25. PATH=/bin:/usr/bin:/usr/ucb:/usr/local/bin:/usr/lbin ; export PATH
  26. echo If this archive is complete, you will see the following message:
  27. echo '          "shar: End of archive 18 (of 18)."'
  28. if test -f 'xvi/doc/README' -a "${1}" != "-c" ; then 
  29.   echo shar: Will not clobber existing file \"'xvi/doc/README'\"
  30. else
  31.   echo shar: Extracting \"'xvi/doc/README'\" \(1783 characters\)
  32.   sed "s/^X//" >'xvi/doc/README' <<'END_OF_FILE'
  33. XThis is a source release of the Xvi editor (derived from "STEVIE"), a
  34. Xclone of the UNIX editor `vi'. The program was originally developed
  35. Xfor the Atari ST, but has been ported to UNIX, MS-DOS, OS/2 and QNX as
  36. Xwell.
  37. X
  38. XXvi is a portable multi-window version of `vi'. In spite of its name,
  39. Xthere is, as yet, no X-Windows-specific version of it, but work is
  40. Xstill in progress. Existing versions use text windows separated by
  41. Xhorizontal status lines on character mode displays.  The windows may
  42. Xrepresent different files being edited, or different views on to the
  43. Xsame file.
  44. X
  45. XUnix, MS-DOS and QNX versions have now been in regular use by the
  46. Xauthors, and many of our colleagues, for about three and a half years,
  47. Xand the editor's behaviour seems fairly satisfactory.
  48. X
  49. XThis source code is not in the public domain, but is provided for free,
  50. Xsubject to the license conditions set out in the COPYING file.
  51. X
  52. XThe files included in the `doc' directory are:
  53. X
  54. XREADME
  55. X    What you're reading.
  56. X
  57. XCOPYING
  58. X    The license under which xvi is provided. Please read and
  59. X    understand this license if you are going to re-distribute xvi.
  60. X
  61. Xhelp
  62. X    The help file used by xvi.
  63. X
  64. Xsource.ms
  65. Xsource.lst
  66. X    A guide to the Xvi source code, including information about
  67. X    how to port Xvi to different systems. Provided in [nt]roff -ms
  68. X    source & nroff output formats. A PostScript version may follow
  69. X    later.
  70. X
  71. Xsummary.ms
  72. Xsummary.lst
  73. X    A document describing the differences between vi and xvi.
  74. X    Same formats.
  75. X
  76. Xxvi.1
  77. Xxvi.lst
  78. X    A Unix-style manual page, in [nt]roff -man & nroff output
  79. X    formats.
  80. X
  81. XChances are, if you're on UNIX, MS-DOS or QNX, you'll be able
  82. Xto compile xvi without changing anything. Change directory
  83. Xinto `src', pick a makefile and go for it.
  84. X
  85. XIf that doesn't work, read doc/source.ms.
  86. X
  87. XChris & John Downey
  88. XOctober 1992
  89. END_OF_FILE
  90.   if test 1783 -ne `wc -c <'xvi/doc/README'`; then
  91.     echo shar: \"'xvi/doc/README'\" unpacked with wrong size!
  92.   fi
  93.   # end of 'xvi/doc/README'
  94. fi
  95. if test -f 'xvi/src/8086mm.inc' -a "${1}" != "-c" ; then 
  96.   echo shar: Will not clobber existing file \"'xvi/src/8086mm.inc'\"
  97. else
  98.   echo shar: Extracting \"'xvi/src/8086mm.inc'\" \(2248 characters\)
  99.   sed "s/^X//" >'xvi/src/8086mm.inc' <<'END_OF_FILE'
  100. X; Copyright (c) 1990,1991,1992 Chris and John Downey
  101. X;***
  102. X;
  103. X; program name:
  104. X;    xvi
  105. X; function:
  106. X;    PD version of UNIX "vi" editor, with extensions.
  107. X; module name:
  108. X;    8086mm.inc
  109. X; module function:
  110. X;    8086 assembly language macros, mainly to help make assembly
  111. X;    language modules memory model independent.
  112. X;
  113. X;    This isn't really needed for Xvi (which uses the large memory
  114. X;    model), but if we want to provide a portable terminal
  115. X;    interface library which can also be used by other
  116. X;    applications, it will almost certainly be needed.
  117. X; history:
  118. X;    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  119. X;    Originally by Tim Thompson (twitch!tjt)
  120. X;    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  121. X;    Heavily modified by Chris & John Downey
  122. X;***
  123. X
  124. X;
  125. X; Memory model definitions.
  126. X;
  127. Xs    equ    0
  128. Xm    equ    1
  129. Xc    equ    2
  130. Xl    equ    3
  131. X
  132. X;
  133. X; Define sizes of code & data pointers.
  134. X;
  135. Xif MEMMODEL eq s
  136. X    CPTRSIZE    =    2
  137. X    DPTRSIZE    =    2
  138. Xendif
  139. X
  140. Xif MEMMODEL eq m
  141. X    CPTRSIZE    =    4
  142. X    DPTRSIZE    =    2
  143. Xendif
  144. X
  145. Xif MEMMODEL eq c
  146. X    CPTRSIZE    =    2
  147. X    DPTRSIZE    =    4
  148. Xendif
  149. X
  150. Xif MEMMODEL eq l
  151. X    CPTRSIZE    =    4
  152. X    DPTRSIZE    =    4
  153. Xendif
  154. X
  155. X;
  156. X; Useful macros defined according to the memory model.
  157. X;
  158. X
  159. X;
  160. X; Declare an external function written in C.
  161. X;
  162. XC_extern    macro    funcname
  163. X    if CPTRSIZE eq 4
  164. X        extrn    funcname : far
  165. X    else
  166. X        extrn    funcname : near
  167. X    endif
  168. X        endm
  169. X
  170. X;
  171. X; Return to C caller.
  172. X;
  173. XC_ret        macro
  174. X    if CPTRSIZE eq 4
  175. X        retf
  176. X    else
  177. X        db    0c3h    ;; Near return.
  178. X    endif
  179. X        endm
  180. X
  181. X;
  182. X; Call another routine which returns with a C_ret & is in the same
  183. X; segment as the caller.
  184. X;
  185. XCn_call        macro    func
  186. X    if CPTRSIZE eq 4
  187. X        push    cs
  188. X    endif
  189. X        call    func
  190. X        endm
  191. X
  192. X;
  193. X; Assign a one-word value by dereferencing a pointer.
  194. X;
  195. X; In C, this would be:
  196. X;
  197. X;    *memptr = value;
  198. X;
  199. X; Note that:
  200. X;
  201. X;    - bx is destroyed. For compact & large memory models, ds is
  202. X;      also destroyed.
  203. X;
  204. X;    - for small & medium memory models, memptr is a near pointer,
  205. X;      which must be relative to ds.
  206. X;
  207. Xptrasg        macro    memptr, value
  208. X    if DPTRSIZE eq 4
  209. X        lds    bx, dword ptr memptr
  210. X        assume    ds: nothing
  211. X    else
  212. X        mov    bx, memptr
  213. X    endif
  214. X        mov    [bx], value
  215. X        endm
  216. X
  217. X;
  218. X; Generally useful macros, defined here for convenience.
  219. X;
  220. X
  221. X;
  222. X; Clear a register to 0.
  223. X;
  224. Xclear        macro    reg
  225. X        xor    reg, reg
  226. X        endm
  227. X
  228. X;
  229. X; Test a register for equality with 0.
  230. X;
  231. Xtst        macro    reg
  232. X        or    reg, reg
  233. X        endm
  234. END_OF_FILE
  235.   if test 2248 -ne `wc -c <'xvi/src/8086mm.inc'`; then
  236.     echo shar: \"'xvi/src/8086mm.inc'\" unpacked with wrong size!
  237.   fi
  238.   # end of 'xvi/src/8086mm.inc'
  239. fi
  240. if test -f 'xvi/src/i286.asm' -a "${1}" != "-c" ; then 
  241.   echo shar: Will not clobber existing file \"'xvi/src/i286.asm'\"
  242. else
  243.   echo shar: Extracting \"'xvi/src/i286.asm'\" \(1926 characters\)
  244.   sed "s/^X//" >'xvi/src/i286.asm' <<'END_OF_FILE'
  245. X; Copyright (c) 1990,1991,1992 Chris and John Downey
  246. X.286P
  247. X
  248. XI286_TEXT    segment word public 'CODE'
  249. X        db    "@(#)i286.asm    2.1 (Chris & John Downey) 7/29/92"
  250. X        db    0
  251. X;***
  252. X;
  253. X; program name:
  254. X;    xvi
  255. X; function:
  256. X;    PD version of UNIX "vi" editor, with extensions.
  257. X; module name:
  258. X;    i286.asm
  259. X; module function:
  260. X;    Low-level 80286-specific routines for OS/2 version.
  261. X; history:
  262. X;    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  263. X;    Originally by Tim Thompson (twitch!tjt)
  264. X;    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  265. X;    Heavily modified by Chris & John Downey
  266. X;
  267. X;***
  268. X        public    _es0
  269. X        public    _newstack
  270. X;
  271. X; void far es0(void);
  272. X;
  273. X; Set the ES register to 0. Microsoft say this should be done
  274. X; before calling the OS/2 DosCreateThread() system call but, as
  275. X; far as I can see, they don't provide any C library function or
  276. X; compiler directive or any other easy way of doing it. So, if
  277. X; you want to write multi-thread code for OS/2, you just have to
  278. X; be an assembler hacker.
  279. X;
  280. X_es0        proc    far
  281. X        xor    ax, ax
  282. X        mov    es, ax
  283. X        ret
  284. X_es0        endp
  285. X
  286. X;
  287. X; unsigned char far * far newstack (int sub);
  288. X;
  289. X; This is utterly disgusting, but unavoidable. The fault lies
  290. X; with the design of OS/2, & the lack of provision for multiple
  291. X; stacks in Microsoft's high-level language products.
  292. X;
  293. X; We need the provision for multiple stacks because we are
  294. X; running multiple threads, but some Microsoft library functions
  295. X; are evidently compiled with stack probes, which give spurious
  296. X; stack overflow errors if we use multiple stacks. So we just
  297. X; use some space at the bottom of our default (48 kb) stack. The
  298. X; return value we want here is the top of the new stack, & we
  299. X; obtain it simply by subtracting the sub parameter from the
  300. X; stack pointer.
  301. X;
  302. X_newstack    proc    far
  303. X        mov    bx, sp
  304. X        ;
  305. X        ; Return offset in AX.
  306. X        ;
  307. X        mov    ax, sp
  308. X        sub    ax, word ptr ss:[bx + 4]
  309. X        ;
  310. X        ; Return stack segment in DX.
  311. X        ;
  312. X        mov    dx, ss
  313. X        ret
  314. X_newstack    endp
  315. XI286_TEXT    ends
  316. X        end
  317. END_OF_FILE
  318.   if test 1926 -ne `wc -c <'xvi/src/i286.asm'`; then
  319.     echo shar: \"'xvi/src/i286.asm'\" unpacked with wrong size!
  320.   fi
  321.   # end of 'xvi/src/i286.asm'
  322. fi
  323. if test -f 'xvi/src/ibmpc.h' -a "${1}" != "-c" ; then 
  324.   echo shar: Will not clobber existing file \"'xvi/src/ibmpc.h'\"
  325. else
  326.   echo shar: Extracting \"'xvi/src/ibmpc.h'\" \(1958 characters\)
  327.   sed "s/^X//" >'xvi/src/ibmpc.h' <<'END_OF_FILE'
  328. X/* Copyright (c) 1990,1991,1992 Chris and John Downey */
  329. X/***
  330. X
  331. X* @(#)ibmpc.h    2.1 (Chris & John Downey) 7/29/92
  332. X
  333. X* program name:
  334. X    xvi
  335. X* function:
  336. X    PD version of UNIX "vi" editor, with extensions.
  337. X* module name:
  338. X    ibmpc.h
  339. X* module function:
  340. X    Declarations for terminal interface module for IBM PC
  341. X    compatibles running MS-DOS.
  342. X
  343. X* history:
  344. X    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  345. X    Originally by Tim Thompson (twitch!tjt)
  346. X    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  347. X    Heavily modified by Chris & John Downey
  348. X
  349. X***/
  350. X
  351. X#include <conio.h>
  352. X
  353. X#define can_ins_line    FALSE
  354. X#define can_del_line    FALSE
  355. X#define can_scroll_area TRUE
  356. X/*
  357. X * tty_linefeed() isn't needed if can_scroll_area is TRUE.
  358. X */
  359. X#define tty_linefeed()
  360. X#define can_inschar    FALSE
  361. X#define inschar(c)
  362. X#define cost_goto    0    /* cost of tty_goto() */
  363. X
  364. X#define tty_close()
  365. X#define vis_cursor()
  366. X#define invis_cursor()
  367. X#define insert_line()
  368. X#define delete_line()
  369. X
  370. X/*
  371. X * Colour handling: default screen colours for PC's.
  372. X */
  373. X#define DEF_COLOUR    7    /* white on black */
  374. X#define DEF_STCOLOUR    112    /* black on white */
  375. X#define DEF_SYSCOLOUR    7    /* white on black */
  376. X
  377. X/*
  378. X * Screen dimensions.
  379. X */
  380. Xextern unsigned int    Columns;
  381. Xextern unsigned int    Rows;
  382. X
  383. X/*
  384. X * Declarations for routines in ibmpc_a.asm & ibmpc_c.c:
  385. X */
  386. Xextern void        alert P((void));
  387. Xextern void        erase_display P((void));
  388. Xextern void        erase_line P((void));
  389. Xextern void        flush_output P((void));
  390. Xextern void        hidemouse P((void));
  391. Xextern int        inchar P((long));
  392. Xextern unsigned        mousestatus P((unsigned *, unsigned *));
  393. Xextern void        outchar P((int));
  394. Xextern void        outstr P((char *));
  395. Xextern void        scroll_down P((unsigned, unsigned, int));
  396. Xextern void        scroll_up P((unsigned, unsigned, int));
  397. Xextern void        set_colour P((int));
  398. Xextern void        showmouse P((void));
  399. Xextern void        tty_endv P((void));
  400. Xextern void        tty_goto P((int, int));
  401. Xextern void        tty_open P((unsigned *, unsigned *));
  402. Xextern void        tty_startv P((void));
  403. END_OF_FILE
  404.   if test 1958 -ne `wc -c <'xvi/src/ibmpc.h'`; then
  405.     echo shar: \"'xvi/src/ibmpc.h'\" unpacked with wrong size!
  406.   fi
  407.   # end of 'xvi/src/ibmpc.h'
  408. fi
  409. if test -f 'xvi/src/makefile.bsd' -a "${1}" != "-c" ; then 
  410.   echo shar: Will not clobber existing file \"'xvi/src/makefile.bsd'\"
  411. else
  412.   echo shar: Extracting \"'xvi/src/makefile.bsd'\" \(1890 characters\)
  413.   sed "s/^X//" >'xvi/src/makefile.bsd' <<'END_OF_FILE'
  414. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  415. X#***
  416. X#
  417. X# @(#)makefile.bsd    2.3 (Chris & John Downey) 9/3/92
  418. X#
  419. X# program name:
  420. X#    xvi
  421. X# function:
  422. X#    PD version of UNIX "vi" editor, with extensions.
  423. X# module name:
  424. X#    makefile.bsd
  425. X# module function:
  426. X#    Makefile for Berkeley UNIX.
  427. X# history:
  428. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  429. X#    Originally by Tim Thompson (twitch!tjt)
  430. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  431. X#    Heavily modified by Chris & John Downey
  432. X#***
  433. X
  434. XSYSDEFS=    -DUNIX -DBSD
  435. XINCDIRS=
  436. X
  437. XLIBS=        -ltermcap
  438. XLDFLAGS=
  439. X
  440. XCFLAGS=     $(SYSDEFS) $(INCDIRS) -O
  441. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  442. X
  443. XMACHSRC=    unix.c termcap.c defscr.c
  444. XMACHOBJ=    unix.o termcap.o defscr.o
  445. XMACHINC=    unix.h termcap.h
  446. X
  447. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  448. X
  449. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  450. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  451. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  452. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  453. X        regexp.c screen.c search.c signal.c startup.c status.c \
  454. X        tags.c undo.c version.c windows.c yankput.c
  455. X
  456. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  457. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  458. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  459. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  460. X        regexp.o screen.o search.o signal.o startup.o status.o \
  461. X        tags.o undo.o version.o windows.o yankput.o
  462. X
  463. Xall:        xvi
  464. X
  465. Xxvi:        $(GENOBJ) $(MACHOBJ)
  466. X        $(CC) $(CFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  467. X
  468. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  469. X        $(CC) $(CFLAGS) -c $<
  470. X
  471. Xlint:
  472. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  473. X
  474. Xlistsrc:
  475. X        @echo $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  476. X
  477. Xlistobj:
  478. X        @echo $(GENOBJ) $(MACHOBJ)
  479. X
  480. X
  481. Xtags:        $(GENSRC) $(MACHSRC)
  482. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  483. X
  484. Xclean:
  485. X        rm $(GENOBJ) $(MACHOBJ) xvi
  486. X
  487. X$(GENOBJ):     $(GENINC) $(MACHINC)
  488. END_OF_FILE
  489.   if test 1890 -ne `wc -c <'xvi/src/makefile.bsd'`; then
  490.     echo shar: \"'xvi/src/makefile.bsd'\" unpacked with wrong size!
  491.   fi
  492.   # end of 'xvi/src/makefile.bsd'
  493. fi
  494. if test -f 'xvi/src/makefile.qn4' -a "${1}" != "-c" ; then 
  495.   echo shar: Will not clobber existing file \"'xvi/src/makefile.qn4'\"
  496. else
  497.   echo shar: Extracting \"'xvi/src/makefile.qn4'\" \(1957 characters\)
  498.   sed "s/^X//" >'xvi/src/makefile.qn4' <<'END_OF_FILE'
  499. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  500. X#***
  501. X#
  502. X# @(#)makefile.qn4    2.2 (Chris & John Downey) 7/31/92
  503. X#
  504. X# program name:
  505. X#    xvi
  506. X# function:
  507. X#    PD version of UNIX "vi" editor, with extensions.
  508. X# module name:
  509. X#    makefile.qn4
  510. X# module function:
  511. X#    Makefile for QNX V4.1 (POSIX-conformant) using Watcom C Compiler.
  512. X# history:
  513. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  514. X#    Originally by Tim Thompson (twitch!tjt)
  515. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  516. X#    Heavily modified by Chris & John Downey
  517. X#***
  518. X
  519. XSYSDEFS=    -DUNIX -DTERMIOS -DPOSIX -DHELPFILE=\"/usr/local/lib/xvi.help\"
  520. XINCDIRS=    -I/usr/include
  521. X
  522. XLIBS=        -ltermcap
  523. XLD=        cc
  524. XLDFLAGS=    -Cd -Q -ml -2 -w2 -N32768
  525. X
  526. XCC=        cc
  527. XCFLAGS=        $(SYSDEFS) $(INCDIRS) -Cd -Q -Oil -ml -2 -w2
  528. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  529. X
  530. XMACHSRC=    unix.c termcap.c defscr.c
  531. XMACHOBJ=    unix.o termcap.o defscr.o
  532. XMACHINC=    unix.h termcap.h
  533. X
  534. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  535. X
  536. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  537. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  538. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  539. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  540. X        regexp.c screen.c search.c signal.c startup.c status.c \
  541. X        tags.c undo.c version.c windows.c yankput.c
  542. X
  543. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  544. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  545. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  546. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  547. X        regexp.o screen.o search.o signal.o startup.o status.o \
  548. X        tags.o undo.o version.o windows.o yankput.o
  549. X
  550. Xall:        xvi
  551. X
  552. Xxvi:        $(GENOBJ) $(MACHOBJ)
  553. X        $(LD) $(LDFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  554. X
  555. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  556. X        $(CC) $(CFLAGS) -c $<
  557. X
  558. Xlint:
  559. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  560. X
  561. Xtags:        $(GENSRC) $(MACHSRC)
  562. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  563. X
  564. Xclean:
  565. X        rm $(GENOBJ) $(MACHOBJ) xvi
  566. X
  567. X$(GENOBJ):    $(GENINC) $(MACHINC)
  568. END_OF_FILE
  569.   if test 1957 -ne `wc -c <'xvi/src/makefile.qn4'`; then
  570.     echo shar: \"'xvi/src/makefile.qn4'\" unpacked with wrong size!
  571.   fi
  572.   # end of 'xvi/src/makefile.qn4'
  573. fi
  574. if test -f 'xvi/src/makefile.qnx' -a "${1}" != "-c" ; then 
  575.   echo shar: Will not clobber existing file \"'xvi/src/makefile.qnx'\"
  576. else
  577.   echo shar: Extracting \"'xvi/src/makefile.qnx'\" \(1640 characters\)
  578.   sed "s/^X//" >'xvi/src/makefile.qnx' <<'END_OF_FILE'
  579. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  580. X#***
  581. X#
  582. X# @(#)makefile.qnx    2.2 (Chris & John Downey) 7/31/92
  583. X#
  584. X# program name:
  585. X#    xvi
  586. X# function:
  587. X#    PD version of UNIX "vi" editor, with extensions.
  588. X# module name:
  589. X#    makefile.qnx
  590. X# module function:
  591. X#    Makefile for QNX, using the CII C86 ANSI Compiler.
  592. X# history:
  593. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  594. X#    Originally by Tim Thompson (twitch!tjt)
  595. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  596. X#    Heavily modified by Chris & John Downey
  597. X#***
  598. X
  599. XMACHINE= qnx
  600. XMACHSRC= $(MACHINE).c
  601. XMACHOBJ= $(MACHINE).obj
  602. X
  603. X#DEBUGFLAGS=-Zf
  604. X
  605. XCQ= cq
  606. XCQFLAGS= -DQNX -c -Za -Ze5 $(DEBUGFLAGS) -G0 -AL -EL
  607. XCOMPILE = $(CC) $(CFLAGS)
  608. XLD=%sync; cq
  609. XLDFLAGS= -Za -G0 -AL -F8000 $(DEBUGFLAGS)
  610. XLIB=
  611. X
  612. XINCLUDE=ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h \
  613. X    virtscr.h qnx.h
  614. X
  615. XSRC=    defscr.c \
  616. X    alloc.c ascii.c buffers.c cmdline.c cursor.c \
  617. X    edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  618. X    find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  619. X    normal.c param.c pipe.c preserve.c ptrfunc.c \
  620. X    regexp.c screen.c search.c signal.c startup.c status.c \
  621. X    tags.c undo.c version.c windows.c yankput.c \
  622. X    $(MACHSRC)
  623. X
  624. XOBJ=    defscr.obj \
  625. X    alloc.obj ascii.obj buffers.obj cmdline.obj cursor.obj \
  626. X    edit.obj ex_cmds1.obj ex_cmds2.obj events.obj fileio.obj \
  627. X    find.obj flexbuf.obj map.obj mark.obj misccmds.obj movement.obj \
  628. X    normal.obj param.obj pipe.obj preserve.obj ptrfunc.obj \
  629. X    regexp.obj screen.obj search.obj signal.obj startup.obj status.obj \
  630. X    tags.obj undo.obj version.obj windows.obj yankput.obj \
  631. X    $(MACHOBJ)
  632. X
  633. Xxvi:    $(OBJ)
  634. X    $(LD) -Fexvi $(LDFLAGS) $(OBJ)
  635. X
  636. Xclean:
  637. X    rm *.obj
  638. X    rm *.lnk
  639. X    rm xvi
  640. END_OF_FILE
  641.   if test 1640 -ne `wc -c <'xvi/src/makefile.qnx'`; then
  642.     echo shar: \"'xvi/src/makefile.qnx'\" unpacked with wrong size!
  643.   fi
  644.   # end of 'xvi/src/makefile.qnx'
  645. fi
  646. if test -f 'xvi/src/makefile.sun' -a "${1}" != "-c" ; then 
  647.   echo shar: Will not clobber existing file \"'xvi/src/makefile.sun'\"
  648. else
  649.   echo shar: Extracting \"'xvi/src/makefile.sun'\" \(2198 characters\)
  650.   sed "s/^X//" >'xvi/src/makefile.sun' <<'END_OF_FILE'
  651. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  652. X#***
  653. X#
  654. X# @(#)makefile.sun    2.2 (Chris & John Downey) 7/31/92
  655. X#
  656. X# program name:
  657. X#    xvi
  658. X# function:
  659. X#    PD version of UNIX "vi" editor, with extensions.
  660. X# module name:
  661. X#    makefile.sun
  662. X# module function:
  663. X#    Makefile for SunOS
  664. X# history:
  665. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  666. X#    Originally by Tim Thompson (twitch!tjt)
  667. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  668. X#    Heavily modified by Chris & John Downey
  669. X#***
  670. X
  671. XSYSDEFS=    -DUNIX -DBSD -DTERMIOS
  672. XINCDIRS=
  673. X
  674. XLIBS=        -ltermcap
  675. XLDFLAGS=
  676. X
  677. XDEBUGFLAG=    -g
  678. XOPTFLAG=    -O2
  679. XCFLAGS=     $(SYSDEFS) $(INCDIRS) $(OPTFLAG)
  680. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  681. X
  682. XPURIFYHOME=    /common/purify
  683. XPURIFY=        $(PURIFYHOME)/purify
  684. X
  685. XMACHSRC=    unix.c termcap.c defscr.c
  686. XMACHOBJ=    unix.o termcap.o defscr.o
  687. XMACHINC=    unix.h termcap.h
  688. X
  689. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  690. X
  691. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  692. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  693. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  694. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  695. X        regexp.c screen.c search.c signal.c startup.c status.c \
  696. X        tags.c undo.c version.c windows.c yankput.c
  697. X
  698. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  699. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  700. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  701. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  702. X        regexp.o screen.o search.o signal.o startup.o status.o \
  703. X        tags.o undo.o version.o windows.o yankput.o
  704. X
  705. Xall:        xvi
  706. X
  707. Xxvi:        $(GENOBJ) $(MACHOBJ)
  708. X        $(CC) $(CFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  709. X
  710. Xpurify:        $(GENOBJ) $(MACHOBJ)
  711. X        $(CC) $(CFLAGS) -c -D_exit=exit unix.c
  712. X        PURIFYHOME=$(PURIFYHOME) $(PURIFY) $(CC) $(CFLAGS) -o xvi \
  713. X            $(GENOBJ) $(MACHOBJ) $(LIBS)
  714. X
  715. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  716. X        $(CC) $(CFLAGS) -c -o $@ $<
  717. X
  718. Xlint:
  719. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  720. X
  721. Xtags:        $(GENSRC) $(MACHSRC)
  722. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  723. X
  724. Xclean:
  725. X        csh -c 'rm -f *.{o,obj} xvi &'
  726. X
  727. X$(GENOBJ):     $(GENINC) $(MACHINC)
  728. X
  729. Xsources:
  730. X        sccs check || sccs delget `sccs tell`
  731. X
  732. Xinstall:
  733. X        mv xvi $(HOME)/bin/`arch`
  734. X
  735. Xmemtest:
  736. X        $(CC) $(CFLAGS) -DMEMTEST=1 -c unix.c
  737. END_OF_FILE
  738.   if test 2198 -ne `wc -c <'xvi/src/makefile.sun'`; then
  739.     echo shar: \"'xvi/src/makefile.sun'\" unpacked with wrong size!
  740.   fi
  741.   # end of 'xvi/src/makefile.sun'
  742. fi
  743. if test -f 'xvi/src/makefile.sv' -a "${1}" != "-c" ; then 
  744.   echo shar: Will not clobber existing file \"'xvi/src/makefile.sv'\"
  745. else
  746.   echo shar: Extracting \"'xvi/src/makefile.sv'\" \(1935 characters\)
  747.   sed "s/^X//" >'xvi/src/makefile.sv' <<'END_OF_FILE'
  748. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  749. X#***
  750. X#
  751. X# @(#)makefile.sv    2.2 (Chris & John Downey) 7/31/92
  752. X#
  753. X# program name:
  754. X#    xvi
  755. X# function:
  756. X#    PD version of UNIX "vi" editor, with extensions.
  757. X# module name:
  758. X#    makefile.sv
  759. X# module function:
  760. X#    Makefile for SunView version
  761. X# history:
  762. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  763. X#    Originally by Tim Thompson (twitch!tjt)
  764. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  765. X#    Heavily modified by Chris & John Downey
  766. X#***
  767. X
  768. XSYSDEFS=    -DUNIX -DBSD -DSUNVIEW
  769. XINCDIRS=
  770. X
  771. XFRONTLIB=    -lsuntool -lsunwindow -lpixrect
  772. XBACKLIB=
  773. XLDFLAGS=
  774. X
  775. XCFLAGS=        $(SYSDEFS) $(INCDIRS) -O2
  776. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  777. X
  778. XMACHINC=    unix.h sunview.h
  779. X
  780. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  781. X
  782. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  783. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  784. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  785. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  786. X        regexp.o screen.o search.o signal.o startup.o status.o \
  787. X        tags.o undo.o version.o windows.o yankput.o
  788. X
  789. XGENSRC=        $(GENOBJ:.o=.c)
  790. X
  791. XBACKOBJ=    $(GENOBJ) unix.o defscr.o sunback.o mouse.o
  792. XBACKSRC=    $(BACKOBJ:.o=.c)
  793. X
  794. XFRONTOBJ=    sunfront.o
  795. XFRONTSRC=    sunfront.c
  796. X
  797. XSRC=        $(FRONTSRC) $(BACKSRC)
  798. XOBJ=        $(FRONTOBJ) $(BACKOBJ)
  799. X
  800. XFRONT=        xvi.sunview
  801. XBACK=        xvi.main
  802. X
  803. XALL=        $(FRONT) $(BACK)
  804. X
  805. Xall:        $(ALL)
  806. X
  807. X$(FRONT):    $(FRONTOBJ)
  808. X        $(CC) $(CFLAGS) -o $@ $(FRONTOBJ) $(FRONTLIB)
  809. X
  810. X$(BACK):    $(BACKOBJ)
  811. X        $(CC) $(CFLAGS) -o $@ $(BACKOBJ) $(BACKLIB)
  812. X
  813. X$(FRONTOBJ):    $(FRONTSRC) $(GENINC) $(MACHINC)
  814. X        $(CC) $(CFLAGS) -DXVI_MAINPROG=\"$(BACK)\" \
  815. X        -c -o $@ $(FRONTSRC)
  816. X
  817. X.c.o:        $< $(GENINC) $(MACHINC)
  818. X        $(CC) $(CFLAGS) -o $@ -c $<
  819. X
  820. Xsources:
  821. X        sccs check || sccs delget `sccs tell`
  822. X
  823. Xlint:
  824. X        lint $(LINTFLAGS) $(SRC)
  825. X
  826. Xtags:        $(SRC)
  827. X        ctags -t $(SRC) $(GENINC) $(MACHINC)
  828. X
  829. Xclean:
  830. X        csh -c 'rm -f *.{o,obj} &'
  831. X
  832. Xinstall:
  833. X        mv $(ALL) $(HOME)/bin/`arch`
  834. X
  835. X$(OBJ):        $(GENINC) $(MACHINC)
  836. END_OF_FILE
  837.   if test 1935 -ne `wc -c <'xvi/src/makefile.sv'`; then
  838.     echo shar: \"'xvi/src/makefile.sv'\" unpacked with wrong size!
  839.   fi
  840.   # end of 'xvi/src/makefile.sv'
  841. fi
  842. if test -f 'xvi/src/makefile.tos' -a "${1}" != "-c" ; then 
  843.   echo shar: Will not clobber existing file \"'xvi/src/makefile.tos'\"
  844. else
  845.   echo shar: Extracting \"'xvi/src/makefile.tos'\" \(1786 characters\)
  846.   sed "s/^X//" >'xvi/src/makefile.tos' <<'END_OF_FILE'
  847. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  848. X#***
  849. X#
  850. X# @(#)makefile.tos    2.2 (Chris & John Downey) 7/31/92
  851. X#
  852. X# program name:
  853. X#    xvi
  854. X# function:
  855. X#    PD version of UNIX "vi" editor, with extensions.
  856. X# module name:
  857. X#    makefile.tos
  858. X# module function:
  859. X#    Makefile for the Atari ST - Megamax or Lattice 5.0 C compiler
  860. X# history:
  861. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  862. X#    Originally by Tim Thompson (twitch!tjt)
  863. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  864. X#    Heavily modified by Chris & John Downey
  865. X#***
  866. X
  867. X# This for MegaMax:
  868. X#CFLAGS=-DATARI -DMEGAMAX
  869. X# This for Lattice:
  870. XCFLAGS=    -ca -DATARI
  871. X
  872. XMACHOBJ=tos.o
  873. XMACHSRC=tos.c
  874. X
  875. XINCLUDE=ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h \
  876. X    virtscr.h tos.h
  877. X
  878. XOBJ=    defscr.o \
  879. X    alloc.o ascii.o buffers.o cmdline.o cursor.o \
  880. X    edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  881. X    find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  882. X    normal.o param.o pipe.o preserve.o ptrfunc.o \
  883. X    regexp.o screen.o search.o signal.o startup.o status.o \
  884. X    tags.o undo.o version.o windows.o yankput.o \
  885. X    $(MACHOBJ)
  886. X
  887. X#    Megamax rule
  888. X#.c.o:    $< $(INCLUDE) param.c
  889. X#    mmcc $(CFLAGS) $<
  890. X#    mmimp $*.o
  891. X#    mmlib rv vi.lib $*.o
  892. X
  893. X# Megamax:
  894. X#xvi.ttp : $(OBJ)
  895. X#    $(LINKER) vi.lib $(LIBS) -o xvi.ttp
  896. X
  897. X# Lattice:
  898. Xxvi.ttp : $(OBJ) tos.lnk
  899. X    clink with tos.lnk
  900. X
  901. Xtos.lnk: makefile
  902. X#
  903. X# Suitable commands to create the link file need to go here; see
  904. X# makefile.zc3 for an MS-DOS example.
  905. X#
  906. X    from c:\lib\c.o
  907. X    alloc.o ascii.o buffers.o cmdline.o defscr.o
  908. X    edit.o ex_cmds1.o ex_cmds2.o events.o
  909. X    fileio.o find.o flexbuf.o
  910. X    input.o startup.o mark.o misccmds.o movement.o normal.o param.o
  911. X    preserve.o ptrfunc.o regexp.o screen.o search.o signal.o
  912. X    status.o tos.o undo.o windows.o
  913. X    yankput.o
  914. X    lib c:\lib\lc.lib c:\lib\lcm.lib
  915. X    to xvi.ttp
  916. X    
  917. Xclean :
  918. X    $(RM) $(OBJ) vi.lib
  919. END_OF_FILE
  920.   if test 1786 -ne `wc -c <'xvi/src/makefile.tos'`; then
  921.     echo shar: \"'xvi/src/makefile.tos'\" unpacked with wrong size!
  922.   fi
  923.   # end of 'xvi/src/makefile.tos'
  924. fi
  925. if test -f 'xvi/src/makefile.ult' -a "${1}" != "-c" ; then 
  926.   echo shar: Will not clobber existing file \"'xvi/src/makefile.ult'\"
  927. else
  928.   echo shar: Extracting \"'xvi/src/makefile.ult'\" \(1793 characters\)
  929.   sed "s/^X//" >'xvi/src/makefile.ult' <<'END_OF_FILE'
  930. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  931. X#***
  932. X#
  933. X# @(#)makefile.ult    2.2 (Chris & John Downey) 7/31/92
  934. X#
  935. X# program name:
  936. X#    xvi
  937. X# function:
  938. X#    PD version of UNIX "vi" editor, with extensions.
  939. X# module name:
  940. X#    makefile.ult
  941. X# module function:
  942. X#    Makefile for DEC Ultrix
  943. X# history:
  944. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  945. X#    Originally by Tim Thompson (twitch!tjt)
  946. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  947. X#    Heavily modified by Chris & John Downey
  948. X#***
  949. X
  950. XSYSDEFS=    -DUNIX -DBSD
  951. XINCDIRS=
  952. X
  953. XLIBS=        -ltermcap
  954. XLDFLAGS=
  955. X
  956. XCFLAGS=        $(SYSDEFS) $(INCDIRS) -O
  957. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  958. X
  959. XMACHSRC=    unix.c termcap.c defscr.c
  960. XMACHOBJ=    unix.o termcap.o defscr.o
  961. XMACHINC=    unix.h termcap.h
  962. X
  963. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  964. X
  965. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  966. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  967. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  968. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  969. X        regexp.c screen.c search.c signal.c startup.c status.c \
  970. X        tags.c undo.c version.c windows.c yankput.c
  971. X
  972. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  973. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  974. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  975. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  976. X        regexp.o screen.o search.o signal.o startup.o status.o \
  977. X        tags.o undo.o version.o windows.o yankput.o
  978. X
  979. Xall:        xvi
  980. X
  981. Xxvi:        $(GENOBJ) $(MACHOBJ)
  982. X        $(CC) $(CFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  983. X
  984. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  985. X        $(CC) $(CFLAGS) -c -o $@ $<
  986. X
  987. Xlint:
  988. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  989. X
  990. Xtags:        $(GENSRC) $(MACHSRC)
  991. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  992. X
  993. Xclean:
  994. X        rm $(GENOBJ) $(MACHOBJ) xvi
  995. X
  996. X$(GENOBJ):     $(GENINC) $(MACHINC)
  997. END_OF_FILE
  998.   if test 1793 -ne `wc -c <'xvi/src/makefile.ult'`; then
  999.     echo shar: \"'xvi/src/makefile.ult'\" unpacked with wrong size!
  1000.   fi
  1001.   # end of 'xvi/src/makefile.ult'
  1002. fi
  1003. if test -f 'xvi/src/makefile.usg' -a "${1}" != "-c" ; then 
  1004.   echo shar: Will not clobber existing file \"'xvi/src/makefile.usg'\"
  1005. else
  1006.   echo shar: Extracting \"'xvi/src/makefile.usg'\" \(1799 characters\)
  1007.   sed "s/^X//" >'xvi/src/makefile.usg' <<'END_OF_FILE'
  1008. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  1009. X#***
  1010. X#
  1011. X# @(#)makefile.usg    2.2 (Chris & John Downey) 7/31/92
  1012. X#
  1013. X# program name:
  1014. X#    xvi
  1015. X# function:
  1016. X#    PD version of UNIX "vi" editor, with extensions.
  1017. X# module name:
  1018. X#    makefile.usg
  1019. X# module function:
  1020. X#    Makefile for System V UNIX.
  1021. X# history:
  1022. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  1023. X#    Originally by Tim Thompson (twitch!tjt)
  1024. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  1025. X#    Heavily modified by Chris & John Downey
  1026. X#***
  1027. X
  1028. XSYSDEFS=    -DUNIX -DTERMIO
  1029. XINCDIRS=
  1030. X
  1031. XLIBS=        -ltermcap
  1032. XLDFLAGS=
  1033. X
  1034. XCFLAGS=        $(SYSDEFS) $(INCDIRS) -O
  1035. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  1036. X
  1037. XMACHSRC=    unix.c termcap.c defscr.c
  1038. XMACHOBJ=    unix.o termcap.o defscr.o
  1039. XMACHINC=    unix.h termcap.h
  1040. X
  1041. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  1042. X
  1043. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  1044. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  1045. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  1046. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  1047. X        regexp.c screen.c search.c signal.c startup.c status.c \
  1048. X        tags.c undo.c version.c windows.c yankput.c
  1049. X
  1050. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  1051. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  1052. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  1053. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  1054. X        regexp.o screen.o search.o signal.o startup.o status.o \
  1055. X        tags.o undo.o version.o windows.o yankput.o
  1056. X
  1057. Xall:        xvi
  1058. X
  1059. Xxvi:        $(GENOBJ) $(MACHOBJ)
  1060. X        $(CC) $(CFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  1061. X
  1062. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  1063. X        $(CC) $(CFLAGS) -c -o $@ $<
  1064. X
  1065. Xlint:
  1066. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  1067. X
  1068. Xtags:        $(GENSRC) $(MACHSRC)
  1069. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  1070. X
  1071. Xclean:
  1072. X        rm $(GENOBJ) $(MACHOBJ) xvi
  1073. X
  1074. X$(GENOBJ):    $(GENINC) $(MACHINC)
  1075. END_OF_FILE
  1076.   if test 1799 -ne `wc -c <'xvi/src/makefile.usg'`; then
  1077.     echo shar: \"'xvi/src/makefile.usg'\" unpacked with wrong size!
  1078.   fi
  1079.   # end of 'xvi/src/makefile.usg'
  1080. fi
  1081. if test -f 'xvi/src/makefile.xen' -a "${1}" != "-c" ; then 
  1082.   echo shar: Will not clobber existing file \"'xvi/src/makefile.xen'\"
  1083. else
  1084.   echo shar: Extracting \"'xvi/src/makefile.xen'\" \(1795 characters\)
  1085.   sed "s/^X//" >'xvi/src/makefile.xen' <<'END_OF_FILE'
  1086. X# Copyright (c) 1990,1991,1992 Chris and John Downey
  1087. X#***
  1088. X#
  1089. X# @(#)makefile.xen    2.2 (Chris & John Downey) 7/31/92
  1090. X#
  1091. X# program name:
  1092. X#    xvi
  1093. X# function:
  1094. X#    PD version of UNIX "vi" editor, with extensions.
  1095. X# module name:
  1096. X#    makefile.xen
  1097. X# module function:
  1098. X#    Makefile for Xenix on a 386.
  1099. X# history:
  1100. X#    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  1101. X#    Originally by Tim Thompson (twitch!tjt)
  1102. X#    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  1103. X#    Heavily modified by Chris & John Downey
  1104. X#***
  1105. X
  1106. XSYSDEFS=    -DUNIX -DTERMIO -DNO_RENAME
  1107. XINCDIRS=
  1108. X
  1109. XLIBS=        -ltermcap
  1110. XLDFLAGS=
  1111. X
  1112. XCFLAGS=        $(SYSDEFS) $(INCDIRS) -Ox
  1113. XLINTFLAGS=    $(SYSDEFS) $(INCDIRS) -ah
  1114. X
  1115. XMACHSRC=    unix.c termcap.c defscr.c
  1116. XMACHOBJ=    unix.o termcap.o defscr.o
  1117. XMACHINC=    unix.h termcap.h
  1118. X
  1119. XGENINC=        ascii.h param.h ptrfunc.h regexp.h regmagic.h xvi.h virtscr.h
  1120. X
  1121. XGENSRC=        alloc.c ascii.c buffers.c cmdline.c cursor.c \
  1122. X        edit.c ex_cmds1.c ex_cmds2.c events.c fileio.c \
  1123. X        find.c flexbuf.c map.c mark.c misccmds.c movement.c \
  1124. X        normal.c param.c pipe.c preserve.c ptrfunc.c \
  1125. X        regexp.c screen.c search.c startup.c status.c tags.c \
  1126. X        undo.c version.c windows.c yankput.c
  1127. X
  1128. XGENOBJ=        alloc.o ascii.o buffers.o cmdline.o cursor.o \
  1129. X        edit.o ex_cmds1.o ex_cmds2.o events.o fileio.o \
  1130. X        find.o flexbuf.o map.o mark.o misccmds.o movement.o \
  1131. X        normal.o param.o pipe.o preserve.o ptrfunc.o \
  1132. X        regexp.o screen.o search.o startup.o status.o tags.o \
  1133. X        undo.o version.o windows.o yankput.o
  1134. X
  1135. Xall:        xvi
  1136. X
  1137. Xxvi:        $(GENOBJ) $(MACHOBJ)
  1138. X        $(CC) $(CFLAGS) -o xvi $(GENOBJ) $(MACHOBJ) $(LIBS)
  1139. X
  1140. X.c.o:        $< $(GENINC) $(MACHINC) param.c
  1141. X        $(CC) $(CFLAGS) -c -o $@ $<
  1142. X
  1143. Xlint:
  1144. X        lint $(LINTFLAGS) $(GENSRC) $(MACHSRC)
  1145. X
  1146. Xtags:        $(GENSRC) $(MACHSRC)
  1147. X        ctags -t $(GENSRC) $(MACHSRC) $(GENINC) $(MACHINC)
  1148. X
  1149. Xclean:
  1150. X        rm $(GENOBJ) $(MACHOBJ) xvi
  1151. X
  1152. X$(GENOBJ):    $(GENINC) $(MACHINC)
  1153. END_OF_FILE
  1154.   if test 1795 -ne `wc -c <'xvi/src/makefile.xen'`; then
  1155.     echo shar: \"'xvi/src/makefile.xen'\" unpacked with wrong size!
  1156.   fi
  1157.   # end of 'xvi/src/makefile.xen'
  1158. fi
  1159. if test -f 'xvi/src/pc386.h' -a "${1}" != "-c" ; then 
  1160.   echo shar: Will not clobber existing file \"'xvi/src/pc386.h'\"
  1161. else
  1162.   echo shar: Extracting \"'xvi/src/pc386.h'\" \(2101 characters\)
  1163.   sed "s/^X//" >'xvi/src/pc386.h' <<'END_OF_FILE'
  1164. X/* Copyright (c) 1990,1991,1992 Chris and John Downey */
  1165. X/***
  1166. X
  1167. X* @(#)pc386.h    2.1 (Chris & John Downey) 7/29/92
  1168. X
  1169. X* program name:
  1170. X    xvi
  1171. X* function:
  1172. X    PD version of UNIX "vi" editor, with extensions.
  1173. X* module name:
  1174. X    pc386.h
  1175. X* module function:
  1176. X    Definitions for MS-DOS 386 protected mode version.
  1177. X
  1178. X    See notes in pc386.c.
  1179. X* history:
  1180. X    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  1181. X    Originally by Tim Thompson (twitch!tjt)
  1182. X    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  1183. X    Heavily modified by Chris & John Downey
  1184. X
  1185. X***/
  1186. X
  1187. X#include <conio.h>
  1188. X#include <disp.h>
  1189. X#include <int.h>
  1190. X#include <msmouse.h>
  1191. X#include <sound.h>
  1192. X
  1193. X/*
  1194. X * Screen dimensions.
  1195. X */
  1196. Xextern unsigned    Rows,
  1197. X        Columns;
  1198. X
  1199. X/*
  1200. X * Colour handling: default screen colours for PC's.
  1201. X */
  1202. X#define DEF_COLOUR        7    /* white on black */
  1203. X#define DEF_STCOLOUR        112    /* black on white */
  1204. X#define DEF_SYSCOLOUR        7    /* white on black */
  1205. X
  1206. X#define alert()            sound_beep(0x299)
  1207. X#define can_ins_line        FALSE
  1208. X#define can_del_line        FALSE
  1209. X#define can_scroll_area        TRUE
  1210. X#define can_inschar        FALSE
  1211. X#define cost_goto        0    /* cost of tty_goto() */
  1212. X#define delete_line()
  1213. X#define erase_display()        (disp_move(0,0),disp_eeop())
  1214. X#define erase_line()        disp_eeol()
  1215. X#define flush_output()        disp_flush()
  1216. X#define hidemouse()        msm_hidecursor()
  1217. X#define inschar(c)
  1218. X#define insert_line()
  1219. X#define invis_cursor()
  1220. X#define mousestatus(x,y)    msm_getstatus(x,y)
  1221. X#define outchar(c)        disp_putc(c)
  1222. X#define outstr(s)        disp_puts(s)
  1223. X#define scroll_down(s,e,n)    pc_scroll((s),(e),-(n))
  1224. X#define scroll_up(s,e,n)    pc_scroll(s,e,n)
  1225. X#define set_colour(n)        disp_setattr(n)
  1226. X#define showmouse()        msm_showcursor()
  1227. X#define tty_goto(r,c)        disp_move(r,c)
  1228. X#define tty_close()        (disp_inited && disp_close())
  1229. X/*
  1230. X * tty_linefeed() isn't needed if can_scroll_area is TRUE.
  1231. X */
  1232. X#define tty_linefeed()
  1233. X#define vis_cursor()
  1234. X
  1235. X/*
  1236. X * Declarations for routines in ibmpc_c.c & pc386.c.
  1237. X */
  1238. Xextern int            inchar P((long));
  1239. Xextern void            pc_scroll P((unsigned, unsigned, int));
  1240. Xextern void            tty_endv P((void));
  1241. Xextern void            tty_open P((unsigned *, unsigned *));
  1242. Xextern void            tty_startv P((void));
  1243. END_OF_FILE
  1244.   if test 2101 -ne `wc -c <'xvi/src/pc386.h'`; then
  1245.     echo shar: \"'xvi/src/pc386.h'\" unpacked with wrong size!
  1246.   fi
  1247.   # end of 'xvi/src/pc386.h'
  1248. fi
  1249. if test -f 'xvi/src/ptrfunc.h' -a "${1}" != "-c" ; then 
  1250.   echo shar: Will not clobber existing file \"'xvi/src/ptrfunc.h'\"
  1251. else
  1252.   echo shar: Extracting \"'xvi/src/ptrfunc.h'\" \(705 characters\)
  1253.   sed "s/^X//" >'xvi/src/ptrfunc.h' <<'END_OF_FILE'
  1254. X/* Copyright (c) 1990,1991,1992 Chris and John Downey */
  1255. X/***
  1256. X
  1257. X* @(#)ptrfunc.h    2.1 (Chris & John Downey) 7/29/92
  1258. X
  1259. X* program name:
  1260. X    xvi
  1261. X* function:
  1262. X    PD version of UNIX "vi" editor, with extensions.
  1263. X* module name:
  1264. X    ptrfunc.h
  1265. X* module function:
  1266. X    Functions on Posn's - defined here for speed, since they
  1267. X    typically get called "on a per-character basis".
  1268. X* history:
  1269. X    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  1270. X    Originally by Tim Thompson (twitch!tjt)
  1271. X    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  1272. X    Heavily modified by Chris & John Downey
  1273. X
  1274. X***/
  1275. X
  1276. X/*
  1277. X * gchar(lp) - get the character at position "lp"
  1278. X */
  1279. X#define    gchar(lp)    ((lp)->p_line->l_text[(lp)->p_index])
  1280. END_OF_FILE
  1281.   if test 705 -ne `wc -c <'xvi/src/ptrfunc.h'`; then
  1282.     echo shar: \"'xvi/src/ptrfunc.h'\" unpacked with wrong size!
  1283.   fi
  1284.   # end of 'xvi/src/ptrfunc.h'
  1285. fi
  1286. if test -f 'xvi/src/version.c' -a "${1}" != "-c" ; then 
  1287.   echo shar: Will not clobber existing file \"'xvi/src/version.c'\"
  1288. else
  1289.   echo shar: Extracting \"'xvi/src/version.c'\" \(758 characters\)
  1290.   sed "s/^X//" >'xvi/src/version.c' <<'END_OF_FILE'
  1291. X/* Copyright (c) 1992 Chris and John Downey */
  1292. X#ifndef lint
  1293. Xstatic char *sccsid = "@(#)version.c    2.4 (Chris & John Downey) 10/15/92";
  1294. X#endif
  1295. X
  1296. X/***
  1297. X
  1298. X* program name:
  1299. X    xvi
  1300. X* function:
  1301. X    PD version of UNIX "vi" editor, with extensions.
  1302. X* module name:
  1303. X    version.c
  1304. X* module function:
  1305. X    Version string definition.
  1306. X* history:
  1307. X    STEVIE - ST Editor for VI Enthusiasts, Version 3.10
  1308. X    Originally by Tim Thompson (twitch!tjt)
  1309. X    Extensive modifications by Tony Andrews (onecom!wldrdg!tony)
  1310. X    Heavily modified by Chris & John Downey
  1311. X
  1312. X***/
  1313. X
  1314. X#ifndef lint
  1315. Xstatic char *copyright = "@(#)Copyright (c) 1992 Chris & John Downey";
  1316. X#endif
  1317. X
  1318. X#ifdef __DATE__
  1319. X    char    Version[] = "Xvi 2.15 " __DATE__;
  1320. X#else
  1321. X    char    Version[] = "Xvi 2.15 15th October 1992";
  1322. X#endif
  1323. END_OF_FILE
  1324.   if test 758 -ne `wc -c <'xvi/src/version.c'`; then
  1325.     echo shar: \"'xvi/src/version.c'\" unpacked with wrong size!
  1326.   fi
  1327.   # end of 'xvi/src/version.c'
  1328. fi
  1329. if test -f 'xvi/src/xvi.icn' -a "${1}" != "-c" ; then 
  1330.   echo shar: Will not clobber existing file \"'xvi/src/xvi.icn'\"
  1331. else
  1332.   echo shar: Extracting \"'xvi/src/xvi.icn'\" \(1933 characters\)
  1333.   sed "s/^X//" >'xvi/src/xvi.icn' <<'END_OF_FILE'
  1334. X/* Format_version=1, Width=64, Height=64, Depth=1, Valid_bits_per_item=16
  1335. X */
  1336. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1337. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1338. X    0x0000,0x0000,0x0000,0x0030,0x0000,0x0000,0x0000,0x00F0,
  1339. X    0x0000,0x0000,0x0000,0x00F0,0x0000,0x0000,0x0000,0x00F0,
  1340. X    0x0000,0x0000,0x0000,0x00F0,0x0000,0x0000,0x0000,0x00F0,
  1341. X    0x0000,0x0000,0x0000,0x00E0,0x0000,0x0000,0x0000,0x0000,
  1342. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0008,0x0000,0x0000,
  1343. X    0x0C00,0x011C,0x0000,0x0FF0,0x3E00,0x033E,0x0000,0x18F0,
  1344. X    0x7E00,0x067E,0x0000,0x30F0,0x1F00,0x041F,0x0000,0x60F0,
  1345. X    0x1F00,0x0C1F,0x0000,0x40F0,0x0F80,0x080F,0x8000,0xC0F0,
  1346. X    0x0F80,0x180F,0x8000,0x80F0,0x07C0,0x100F,0x8001,0x80F0,
  1347. X    0x07C0,0x3007,0xC001,0x00F0,0x03E0,0x2007,0xC003,0x00F0,
  1348. X    0x03E0,0x6007,0xC002,0x00F0,0x01F0,0x4003,0xE006,0x00F0,
  1349. X    0x01F0,0xC003,0xE004,0x00F0,0x00F8,0x8001,0xE00C,0x00F0,
  1350. X    0x00F9,0x8001,0xF008,0x00F0,0x00FD,0x0001,0xF018,0x00F0,
  1351. X    0x007F,0x0000,0xF010,0x00F0,0x007E,0x0000,0xF810,0x00F0,
  1352. X    0x003E,0x0000,0xF830,0x00F0,0x003E,0x0000,0xF820,0x00F0,
  1353. X    0x001F,0x0000,0x7860,0x00F0,0x001F,0x0000,0x7C40,0x00F0,
  1354. X    0x003F,0x8000,0x7C40,0x00F0,0x002F,0x8000,0x7CC0,0x00F0,
  1355. X    0x0067,0xC000,0x7C80,0x00F0,0x0047,0xC000,0x3C80,0x00F0,
  1356. X    0x00C3,0xE000,0x3E80,0x00F0,0x0083,0xE000,0x3E80,0x00F0,
  1357. X    0x0181,0xF000,0x3F80,0x00F0,0x0101,0xF000,0x1F00,0x00F0,
  1358. X    0x0300,0xF800,0x1F00,0x00F0,0x0200,0xF800,0x1F00,0x00F0,
  1359. X    0x0600,0x7C00,0x1F00,0x00F0,0x0400,0x7C00,0x0F00,0x00F0,
  1360. X    0x0C00,0x3F80,0x0F00,0x00F0,0x1800,0x3F00,0x0E00,0x00F2,
  1361. X    0x3000,0x1E00,0x0E00,0x00FC,0x6000,0x0C00,0x0C00,0x0078,
  1362. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1363. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1364. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1365. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1366. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
  1367. X    0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000
  1368. END_OF_FILE
  1369.   if test 1933 -ne `wc -c <'xvi/src/xvi.icn'`; then
  1370.     echo shar: \"'xvi/src/xvi.icn'\" unpacked with wrong size!
  1371.   fi
  1372.   # end of 'xvi/src/xvi.icn'
  1373. fi
  1374. echo shar: End of archive 18 \(of 18\).
  1375. cp /dev/null ark18isdone
  1376. MISSING=""
  1377. for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 ; do
  1378.     if test ! -f ark${I}isdone ; then
  1379.     MISSING="${MISSING} ${I}"
  1380.     fi
  1381. done
  1382. if test "${MISSING}" = "" ; then
  1383.     echo You have unpacked all 18 archives.
  1384.     rm -f ark[1-9]isdone ark[1-9][0-9]isdone
  1385. else
  1386.     echo You still must unpack the following archives:
  1387.     echo "        " ${MISSING}
  1388. fi
  1389. exit 0
  1390. exit 0 # Just in case...
  1391.