[comp.unix.xenix] jove 4.12 on SCO Xenix 286 ?

root@libove.UUCP (Jay M. Libove) (04/07/89)

Has anyone gotten JOVE version 4.12 to compile on SCO Xenix 80286
(version 2.2.1 just if it matters) ?

I have worked through a number of small things, and finally ended
up with:

	cc -O -LARGE -F 3000 -K -Ml2e -c io.c
io.c
/usr/include/sys/file.h(24) : error 25: `file' : enum/struct/union type redefinition
io.c(97) : error 38: `f_flags' : not struct/union member
io.c(131) : error 38: `f_cnt' : not struct/union member
io.c(131) : error 38: `f_ptr' : not struct/union member
io.c(141) : error 38: `f_cnt' : not struct/union member
io.c(141) : error 38: `f_ptr' : not struct/union member
io.c(191) : error 38: `f_flags' : not struct/union member
io.c(753) : error 38: `f_flags' : not struct/union member
io.c(757) : error 38: `f_flags' : not struct/union member
io.c(1039) : error 38: `f_cnt' : not struct/union member
io.c(1039) : error 38: `f_ptr' : not struct/union member
*** Error code 11
Stop.


I have traced the tree of #include's through the sources and header
files, quite exhaustively, and can't find any problems with it.

Thanks in advance for any help offered!
------------- 
Jay Libove		jl42@andrew.cmu.edu, libove@cs.cmu.edu,
5731 Centre Ave, Apt 3	gateway.sei.cmu.edu!libove!libove, jl42@andrew.BITnet,
Pittsburgh, PA 15206	psuvax1!pitt!darth!libove!libove,
(412) 362-8983		or uunet!nfsun!libove!libove

root@mjbtn.MFEE.TN.US (Mark J. Bailey) (04/08/89)

In article <237@libove.UUCP>, root@libove.UUCP (Jay M. Libove) writes:
> 
> Has anyone gotten JOVE version 4.12 to compile on SCO Xenix 80286
> (version 2.2.1 just if it matters) ?
> 
> io.c
> /usr/include/sys/file.h(24) : error 25: `file' : enum/struct/union type redefinition

	[error msgs deleted]

> I have traced the tree of #include's through the sources and header
> files, quite exhaustively, and can't find any problems with it.

Within one of the header files for Jove 4.12, there is an attempt 
to provide (I assume for DOS) the equivalent of sys/file.h.  It adds
in more stuff that the xenix sys/file.h, which i haven't had time
yet to determine its use.  However, what is happening is that within
the Jove header file, 'struct file' is being defined also.  That is
where you get your redifintion error.  What I did (on the fly, not
a viable, long-term solution, yet) was to take the Jove 'struct file'
and rename it to 'struct fiLe' (or anything would do).  I could not
perceive this to be too much of a problem as the struct was immediately
typedefed and an fgrep of *.c *.h didn't reveal where the struct name
was specifically referred to again.  I do not have the sources online
currently, but I thought I would pass this along.

Also, the Jove sources defines its own set of file manipulation 
routines (open_file() = fopen() ???) and there seems to be additional
problems in some of these functions be declared int some spots (probably
thru no particular definition in some function) and a pointer of the 
type 'struct fiLe' (what I assume it should be).  Once you get thru
the file.h error, you certainly won't miss these.  

I compiled 4.9 just a few weeks ago with almost no hitch.  The config
for 4.12 was noticeably different than 4.9.  Since my first attempts
to get 4.12 compiled, I have had to devote to time other worthy causes
such as paying bills! :-)

Hope this helps.

Mark.

-- 
Mark J. Bailey                                    "Ya'll com bak naw, ya hear!"
USMAIL: 511 Memorial Blvd., Murfreesboro, TN 37129 ___________________________
VOICE:  +1 615 893 0098                            |         JobSoft
UUCP:   ...!{ames,mit-eddie}!killer!mjbtn!mjb      | Design & Development Co.
DOMAIN: mjb@mjbtn.MFEE.TN.US                       |  Murfreesboro, TN  USA

skrenta@blekko.home.nwu.edu (Rich Skrenta) (04/10/89)

I got Jove 4.9 to compile hassle-free on Xenix, but it's not finding the
function gldav() when it goes to link.  Does anyone know what this is?  Is
it in its own file?  Is it a library call?  I'm wondering if I'm missing a
small part of Jove.

About the problems compiling Jove 4.12:  I see those sorts of problems
when a header file, typically something like <sys/file.h> is included more
than once.  While I think <466@mjbtn.MFEE.TN.US> explained the particular
problem for Jove 4.12, if you ran into the problem again I'd say look for
multiple includes of the same file.

-- 
Rich Skrenta                 skrenta@blekko.home.nwu.edu
skrenta@eecs.nwu.edu         ...nucsrl!blekko!skrenta

buhrt@sawmill.UUCP (Jeffery A Buhrt) (04/10/89)

I have jove4.12 running on a sequent symmetry, AT&T 3b1 (blah), and
Uport 2.4 on a '286 (changes should also apply to xenix).

Things in that area are int vs (char *), a pointer comparision out
of the current segment, minor preprocessor bugs (order dependent stuff),
plus some other little things....

As for the sysV i-shells, it is great to have them put BACK into jove...
Yes back, 4.[56] had working i-shells but they soon were removed.

sysV:
1) Things to make sure: kbd && portsrv MUST be in place (/usr/local/lib/jove)
before starting an i-proc (the exec messages by default don't help).

2) If size_t is not defined in sys/types.h (uport doesn't), define it to
	be int (yes int).

3) I included the 3b1 and uport specific files for reference from each port.

Bugs/things to do:
1) (sysV) If you have an iproc running and pause jove (ie: push a shell)
	kbd will still be left running....
	(this means it will fight for the keyboard)
	I have tried calling kbd_{strt, stop} to get around this
	but kbd then dies when the kbd_strt() is called on the way back in.
	I haven't had enough time to track this one down yet (ideas?)


2) (gen) The IPROCS define is recursive between tune.h and sysdep.h, for
	now patched by having a second copy of the define.

3) (sysV) recover doesn't compile....
	I have a working version from jove.? and haven't yet even tried
	the 4.12 version.

4) (uport) term.c the code:
	if (termp > tspace+ sizeof(tspace))
		goto wimperr;
	core dumps on a '286, didn't even try to fix.

5) As Jonathan pointed out, the docs are out of date w/ the new features.

6) I still don't have it compiling on a 3b2 yet.... Whenever time permits.


						-Jeff Buhrt
						Grauel Ent., Inc.
						(317) 477-6000
		{newton.physics.purdue.edu (aka: pur-phy), sequent, ...}!
						sawmill!buhrt

Here is my .joverc (the process-bind-to-keys are needed to use i-shells)
----
auto-execute-command show-match-mode .*$
auto-execute-command auto-indent-mode .*\.[chyls]$
auto-execute-command auto-fill-mode /tmp/Re\|/tmp/article
auto-execute-command show-match .*\.[lchyf]$\|.*\.lisp$\|.*\.scm$
auto-execute-command c-mode .*\.[chy]$
auto-execute-command lisp-mode .*\.l$\|.*\.lisp$\|.*\.scm$

set make-backup-files on
set mode-line-should-standout off
set paren-flash-delay 2

make-keymap prefix3
bind-keymap-to-key prefix3 ^C
bind-to-key exit-jove ^X^Z
bind-to-key buffer-position ^X=
bind-to-key fill-comment ^Xj
bind-to-key filter-region ^C^F
bind-to-key i-search-forward ^S
bind-to-key i-search-forward ^\
bind-to-key i-search-reverse ^R
bind-to-key pause-jove ^C^Z
bind-to-key pause-jove ^[S
bind-to-key pause-jove ^[s

process-bind-to-key interrupt-process ^C
process-bind-to-key process-newline ^M

set mode-line %3c %[%sJOVE (%M) Buffer: %b "%f" %]%s%m*- %((%t %l)%s%)%e
-----

*** Diffs from my sequent/3b1/uport version to 4.12 

# This is a shell archive.  Remove anything before this line,
# then unpack it by saving it in a file and typing "sh file".
#
# Wrapped by sawmill!buhrt on Mon Apr 10 09:05:50 EST 1989
# Contents:  Makefile Makefile.uport extend.c fp.h io.h iproc-pipes.c iproc.c
#	iproc.h jove.h malloc.c portsrv.c proc.c sysdep.3b1 sysdep.h
#	sysdep.uport term.c tune.3b1 tune.h tune.uport util.c
 
echo x - Makefile
sed 's/^@//' > "Makefile" <<'@//E*O*F Makefile//'
*** Makefile	Thu Mar  2 20:39:18 1989
--- ../Makefile	Fri Mar 31 14:00:34 1989
***************
*** 17,29
  # JOVE, RECOVER and TEACHJOVE.  MANEXT is the extension for the man pages,
  # e.g., jove.1 or jove.l or jove.m.
  
  DESTDIR =
  TMPDIR = /tmp
! LIBDIR = /home/chacha/jpayne/lib/jove
! BINDIR = /home/chacha/jpayne/bin
! MANDIR = /home/chacha/jpayne/lib/manl
  MANEXT = l
  JSHELL = /bin/csh
  
  # These should all just be right if the above ones are.
  JOVE = $(DESTDIR)$(BINDIR)/jove

--- 17,29 -----
  # JOVE, RECOVER and TEACHJOVE.  MANEXT is the extension for the man pages,
  # e.g., jove.1 or jove.l or jove.m.
  
  DESTDIR =
  TMPDIR = /tmp
! LIBDIR = /usr/local/lib/jove
! BINDIR = /usr/local/bin
! MANDIR = /usr/man/manl
  MANEXT = l
  JSHELL = /bin/ksh
  
  # These should all just be right if the above ones are.
  JOVE = $(DESTDIR)$(BINDIR)/jove
***************
*** 21,31
  TMPDIR = /tmp
  LIBDIR = /home/chacha/jpayne/lib/jove
  BINDIR = /home/chacha/jpayne/bin
  MANDIR = /home/chacha/jpayne/lib/manl
  MANEXT = l
! JSHELL = /bin/csh
  
  # These should all just be right if the above ones are.
  JOVE = $(DESTDIR)$(BINDIR)/jove
  TEACHJOVE = $(DESTDIR)$(BINDIR)/teachjove
  RECOVER = $(DESTDIR)$(LIBDIR)/recover

--- 21,31 -----
  TMPDIR = /tmp
  LIBDIR = /usr/local/lib/jove
  BINDIR = /usr/local/bin
  MANDIR = /usr/man/manl
  MANEXT = l
! JSHELL = /bin/ksh
  
  # These should all just be right if the above ones are.
  JOVE = $(DESTDIR)$(BINDIR)/jove
  TEACHJOVE = $(DESTDIR)$(BINDIR)/teachjove
  RECOVER = $(DESTDIR)$(LIBDIR)/recover
@//E*O*F Makefile//
chmod u=rw,g=rw,o=r Makefile
 
echo x - Makefile.uport
sed 's/^@//' > "Makefile.uport" <<'@//E*O*F Makefile.uport//'
###########################################################################
# This program is Copyright (C) 1986, 1987, 1988 by Jonathan Payne.  JOVE #
# is provided to you without charge, and with no warranty.  You may give  #
# away copies of JOVE, including sources, provided that this notice is    #
# included in all the files.                                              #
###########################################################################

# TMPDIR is where the tmp files get stored, usually /tmp or /tmp/jove.  If
# your system does not remove subdirectories of /tmp on reboot (lots do
# remove them these days) then it makes sense to make TMPDIR be /tmp/jove.
# But if you want to recover buffers on system crashes, you should create a
# directory that doesn't get clearned upon reboot, and use that instead.
# You would probably want to clean out that directory periodically with
# /etc/cron.  LIBDIR is for online documentation, the PORTSRV process,
# RECOVER, and the system-wide .joverc file.  BINDIR is where to put the
# executables JOVE and TEACHJOVE.  MANDIR is where the manual pages go for
# JOVE, RECOVER and TEACHJOVE.  MANEXT is the extension for the man pages,
# e.g., jove.1 or jove.l or jove.m.

DESTDIR =
TMPDIR = /tmp
LIBDIR = /usr/local/lib/jove
BINDIR = /usr/local/bin
MANDIR = /usr/man/manl
MANEXT = l
JSHELL = /bin/csh

# These should all just be right if the above ones are.
JOVE = $(DESTDIR)$(BINDIR)/jove
TEACHJOVE = $(DESTDIR)$(BINDIR)/teachjove
RECOVER = $(DESTDIR)$(LIBDIR)/recover
PORTSRV = $(DESTDIR)$(LIBDIR)/portsrv
KBD = $(DESTDIR)$(LIBDIR)/kbd
JOVERC = $(DESTDIR)$(LIBDIR)/jove.rc
CMDS.DOC = $(DESTDIR)$(LIBDIR)/cmds.doc
TEACH-JOVE = $(DESTDIR)$(LIBDIR)/teach-jove
JOVEM = $(DESTDIR)$(MANDIR)/jove.$(MANEXT)
TEACHJOVEM = $(DESTDIR)$(MANDIR)/teachjove.$(MANEXT)

# Select the right libraries for your system.
#	2.10BSD:LIBS = -ltermcap
#	v7:	LIBS = -ltermcap
#	4.1BSD:	LIBS = -ltermcap -ljobs
#	4.2BSD:	LIBS = -ltermcap
#	4.3BSD:	LIBS = -ltermcap
#	SysV Rel. 2: LIBS = -lcurses
#	SCO Xenix: LIBS = -ltermcap -lx

LIBS = -lcurses

# If you are not VMUNIX (vax running Berkeley Version 4), you must specify
# the -i flags (split I/D space) and maybe the -x option (for adb to work).
#	2.10BSD:LDFLAGS =
#	v7:	LDFLAGS =
#	4.1BSD:	LDFLAGS =
#	4.2BSD:	LDFLAGS =
#	4.3BSD:	LDFLAGS =
#	SysV Rel. 2: LDFLAGS = -Ml
#	SCO Xenix: LDFLAGS = -Ml -F 3000
#
# SEPFLAG should be:
#	not on a PDP-11:		SEPFLAG =
#	PDP-11 with separate I&D:	SEPFLAG = -i
#	PDP-11 without separate I&D:	SEPFLAG = -n
#

LDFLAGS = -Ml

SEPFLAG =

# for SCO Xenix, set
#	MEMFLAGS = -Mle
#	CFLAGS = -LARGE -O -F 3000 -K -Mle  (say -Mle2 for an 80286)

#CFLAGS = -O -Ml -DSigHold(x)="" -DSigRelse(x)="" -DSIGCHLD=SIGCLD -DUPORT
CFLAGS = -Ml -DSIGCHLD=SIGCLD -DUPORT

BASESEG = funcdefs.o keys.o argcount.o ask.o buf.o ctype.o delete.o \
	  disp.o insert.o io.o jove.o malloc.o marks.o misc.o re.o \
	  screen.o tune.o util.o vars.o version.o list.o keymaps.o dup2.o
OVLAY1 = abbrev.o rec.o paragraph.o fmt.o
OVLAY2 = c.o wind.o fp.o move.o
OVLAY3 = extend.o macros.o
OVLAY4 = iproc.o re1.o
OVLAY5 = proc.o scandir.o term.o case.o

OBJECTS = $(BASESEG) $(OVLAY1) $(OVLAY2) $(OVLAY3) $(OVLAY4) $(OVLAY5)

C_SRC = funcdefs.c abbrev.c argcount.c ask.c buf.c c.c case.c ctype.c \
	delete.c disp.c extend.c fp.c fmt.c insert.c io.c iproc.c \
	jove.c list.c macros.c malloc.c marks.c misc.c move.c paragraph.c \
	proc.c re.c re1.c rec.c scandir.c screen.c term.c util.c \
	vars.c version.c wind.c getch.c mac.c keymaps.c pcscr.c

SOURCES = $(C_SRC) portsrv.c recover.c setmaps.c teachjove.c kbd.c

HEADERS = argcount.h buf.h chars.h ctype.h dataobj.h disp.h \
	externs.h fp.h io.h iproc.h jove.h keymaps.h list.h mac.h \
	re.h rec.h scandir.h screen.h style.h sysdep.h temp.h termcap.h \
	ttystate.h tune.h util.h vars.h wait.h wind.h


DOCS1 =	doc/example.rc doc/jove.1 doc/jove.2 doc/jove.3 \
	doc/jove.4 doc/jove.5 doc/jove.nr doc/system.rc \
	doc/teach-jove doc/teachjove.nr doc/README doc/jove.qref
DOCS2 = doc/cmds.doc.nr
DOCS3 = doc/joveman doc/cmds.doc doc/manpage
DOCS = $(DOCS1) $(DOCS2)

MISC = Makefile Makefile.dos tune.dos tune.template README Readme.dos \
	Readme.mac iproc-pipes.c iproc-ptys.c

SUPPORT = teachjove.c recover.c setmaps.c portsrv.c kbd.c keys.txt \
	macvert.c menumaps.txt mjovers.Hqx

BACKUPS = $(HEADERS) $(C_SRC) $(DOCS) $(SUPPORT) $(MISC)

all:	sdate xjove recover teachjove portsrv kbd macvert edate

sdate:
	@echo "**** make started at `date` ****"

edate:
	@echo "**** make completed at `date` ****"

xjove:	$(OBJECTS)
	$(CC) $(LDFLAGS) -o xjove $(OBJECTS) $(LIBS)
	@-size xjove

gjove:	$(OBJECTS)
	ld -X /lib/gcrt0.o -o gjove $(OBJECTS) -lc $(LIBS)
	@-size gjove

ovjove:	$(OBJECTS)
	ld $(SEPFLAG) $(LDFLAGS) -X /lib/crt0.o \
		-Z $(OVLAY1) \
		-Z $(OVLAY2) \
		-Z $(OVLAY3) \
		-Z $(OVLAY4) \
		-Z $(OVLAY5) \
		-Y $(BASESEG) \
		-o xjove $(LIBS) -lc
	@-size xjove

portsrv:	portsrv.o dup2.o
	$(CC) $(LDFLAGS) -o portsrv $(SEPFLAG) portsrv.o dup2.o $(LIBS)

kbd:	kbd.o
	$(CC) $(LDFLAGS) -o kbd $(SEPFLAG) kbd.o $(LIBS)

recover:	recover.o tune.o rec.h temp.h
	$(CC) $(LDFLAGS) -o recover $(SEPFLAG) recover.o tune.o $(LIBS)

teachjove:	teachjove.o
	$(CC) $(LDFLAGS) -o teachjove $(SEPFLAG) teachjove.o $(LIBS)

setmaps:	setmaps.o funcdefs.c
	$(CC) -o setmaps setmaps.o

teachjove.o:	teachjove.c /usr/include/sys/types.h /usr/include/sys/file.h
	cc -c $(CFLAGS) -DTEACHJOVE=\"$(TEACH-JOVE)\" teachjove.c

# don't optimize setmaps.c because it produces bad code in some places
# for some reason
setmaps.o:	funcdefs.c keys.txt
	$(CC) $(MEMFLAGS) -c setmaps.c

# ignore error messages from setmaps
# it doesn't understand ifdefs

keys.c:	setmaps keys.txt
	-./setmaps < keys.txt > keys.c

keys.o:	keys.c jove.h

tune.c: Makefile tune.template
	@echo "/* Changes should be made in Makefile, not to this file! */" > tune.c
	@echo "" >> tune.c
	@sed -e 's;TMPDIR;$(TMPDIR);' \
	     -e 's;LIBDIR;$(LIBDIR);' \
	     -e 's;BINDIR;$(BINDIR);' \
	     -e 's;SHELL;$(JSHELL);' tune.template >> tune.c

iproc.o: iproc-ptys.c iproc-pipes.c iproc.c
	$(CC) -c $(CFLAGS) iproc.c

macvert:	macvert.c
	$(CC) $(CFLAGS) -o macvert macvert.c

# install doesn't work for Xenix (no install program)

install: $(DESTDIR)$(LIBDIR) $(TEACH-JOVE) $(CMDS.DOC) $(JOVERC) \
	 $(PORTSRV) $(KBD) $(RECOVER) $(JOVE) $(TEACHJOVE) $(JOVEM) \
	 $(RECOVERM) $(TEACHJOVEM)

$(DESTDIR)$(LIBDIR):
	-mkdir $(DESTDIR)$(LIBDIR)

$(TEACH-JOVE): doc/teach-jove
	install -c -m 644 doc/teach-jove $(TEACH-JOVE)

doc/cmds.doc:	doc/cmds.doc.nr doc/jove.4 doc/jove.5
	nroff doc/cmds.doc.nr doc/jove.4 doc/jove.5 > doc/cmds.doc

$(CMDS.DOC): doc/cmds.doc
	install -c -m 644 doc/cmds.doc $(CMDS.DOC)

$(JOVERC): doc/system.rc
	install -c -m 644 doc/system.rc $(JOVERC)

$(PORTSRV): portsrv
	install -c -s -m 755 portsrv $(PORTSRV)

$(KBD): kbd
	install -c -s -m 755 kbd $(KBD)

$(RECOVER): recover
	install -c -s -m 755 recover $(RECOVER)

$(JOVE): xjove
	install -c -m 755 xjove $(JOVE)

$(TEACHJOVE): teachjove
	install -c -s -m 755 teachjove $(TEACHJOVE)

$(JOVEM): doc/jove.nr
	@sed -e 's;TMPDIR;$(TMPDIR);' \
	     -e 's;LIBDIR;$(LIBDIR);' \
	     -e 's;SHELL;$(JSHELL);' doc/jove.nr > /tmp/jove.nr
	install -m 644 /tmp/jove.nr $(JOVEM)

$(TEACHJOVEM): doc/teachjove.nr
	@sed -e 's;TMPDIR;$(TMPDIR);' \
	     -e 's;LIBDIR;$(LIBDIR);' \
	     -e 's;SHELL;$(JSHELL);' doc/teachjove.nr > /tmp/teachjove.nr
	install -m 644 /tmp/teachjove.nr $(TEACHJOVEM)

echo:
	@echo $(C-FILES) $(HEADERS)

lint:
	lint -n $(C_SRC) tune.c keys.c
	@echo Done

tags:
	ctags -w $(C_SRC) $(HEADERS) iproc-ptys.c

ciall:
	ci $(BACKUPS)

coall:
	co $(BACKUPS)

jove.shar:
	shar $(BACKUPS) > jove.shar

backup: $(BACKUPS)
	tar chf backup $(BACKUPS)

tape-backup:
	tar c $(BACKUPS)

srcdownload:
	kermit -s $(SUPPORT) $(MISC) $(HEADERS) $(C_SRC)

docdownload:
	kermit -s $(DOCS1) $(DOCS3)
	kermit -s doc/cmds.doc.nr -a cmdsdoc.nr

touch:
	touch $(OBJECTS)

clean:
	rm -f a.out core *.o keys.c tune.c xjove portsrv kbd recover setmaps \
	teachjove macvert

# This version only works under 4.3BSD
# To enable, remove single # from start of following lines
depend:
	for i in ${SOURCES} ; do \
		cc -M ${CFLAGS} $$i | \
		awk ' /[/]usr[/]include/ { next } \
			{ if ($$1 != prev) \
		    { if (rec != "") print rec; rec = $$0; prev = $$1; } \
		    else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \
		    else rec = rec " " $$2 } } \
		    END { print rec } ' >> makedep; \
	done
	echo '$$a' >eddep
	echo '' >>eddep
	echo '.' >>eddep
	echo '/^# DO NOT DELETE THIS LINE/+1,$$d' >>eddep
	echo '$$r makedep' >>eddep
	echo 'w' >>eddep
	cp Makefile Makefile.bak
	ed - Makefile < eddep
	rm eddep makedep
	echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
	echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
	echo '# see make depend above' >> Makefile

# DO NOT DELETE THIS LINE -- make depend uses it
funcdefs.o: funcdefs.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
funcdefs.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
funcdefs.o: ./screen.h ./style.h ./externs.h ./ctype.h
abbrev.o: abbrev.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
abbrev.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
abbrev.o: ./screen.h ./style.h ./externs.h ./fp.h ./ctype.h
argcount.o: argcount.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
argcount.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
argcount.o: ./screen.h ./style.h ./externs.h
ask.o: ask.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
ask.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
ask.o: ./style.h ./externs.h ./termcap.h ./ctype.h ./chars.h ./disp.h
buf.o: buf.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
buf.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
buf.o: ./style.h ./externs.h ./ctype.h ./disp.h
c.o: c.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
c.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
c.o: ./style.h ./externs.h ./re.h ./ctype.h
case.o: case.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
case.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
case.o: ./style.h ./externs.h ./disp.h ./ctype.h
ctype.o: ctype.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
ctype.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
ctype.o: ./style.h ./externs.h ./ctype.h
delete.o: delete.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
delete.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
delete.o: ./screen.h ./style.h ./externs.h ./disp.h
disp.o: disp.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
disp.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
disp.o: ./style.h ./externs.h ./ctype.h ./termcap.h ./chars.h ./fp.h ./disp.h
extend.o: extend.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
extend.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
extend.o: ./screen.h ./style.h ./externs.h ./fp.h ./termcap.h ./ctype.h
extend.o: ./chars.h ./disp.h
fp.o: fp.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
fp.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
fp.o: ./style.h ./externs.h ./fp.h ./ctype.h ./termcap.h
fmt.o: fmt.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
fmt.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
fmt.o: ./style.h ./externs.h ./fp.h ./termcap.h ./ctype.h ./disp.h
insert.o: insert.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
insert.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
insert.o: ./screen.h ./style.h ./externs.h ./ctype.h ./list.h ./chars.h
insert.o: ./disp.h
io.o: io.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
io.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
io.o: ./style.h ./externs.h ./list.h ./fp.h ./termcap.h ./ctype.h ./disp.h
io.o: ./io.h ./temp.h
iproc.o: iproc.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
iproc.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
iproc.o: ./style.h ./externs.h ./re.h ./ctype.h ./disp.h ./iproc-ptys.c
iproc.o: ./wait.h
jove.o: jove.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
jove.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
jove.o: ./style.h ./externs.h ./fp.h ./termcap.h ./ctype.h ./chars.h ./disp.h
list.o: list.c ./list.h ./tune.h ./sysdep.h
macros.o: macros.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
macros.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
macros.o: ./screen.h ./style.h ./externs.h ./ctype.h ./fp.h ./chars.h ./disp.h
malloc.o: malloc.c ./tune.h ./sysdep.h
marks.o: marks.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
marks.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
marks.o: ./style.h ./externs.h
misc.o: misc.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
misc.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
misc.o: ./style.h ./externs.h ./ctype.h
move.o: move.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
move.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
move.o: ./style.h ./externs.h ./re.h ./ctype.h
paragraph.o: paragraph.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
paragraph.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
paragraph.o: ./screen.h ./style.h ./externs.h
proc.o: proc.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
proc.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
proc.o: ./style.h ./externs.h ./ctype.h ./fp.h ./re.h ./termcap.h ./wait.h
re.o: re.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
re.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
re.o: ./style.h ./externs.h ./re.h ./ctype.h
re1.o: re1.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
re1.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
re1.o: ./style.h ./externs.h ./fp.h ./re.h ./ctype.h ./chars.h ./disp.h
rec.o: rec.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
rec.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
rec.o: ./style.h ./externs.h ./fp.h ./rec.h
scandir.o: scandir.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
scandir.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
scandir.o: ./screen.h ./style.h ./externs.h
screen.o: screen.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
screen.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
screen.o: ./screen.h ./style.h ./externs.h ./fp.h ./ctype.h ./termcap.h
screen.o: ./disp.h
term.o: term.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
term.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
term.o: ./style.h ./externs.h ./fp.h ./termcap.h
util.o: util.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
util.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
util.o: ./style.h ./externs.h ./ctype.h ./termcap.h ./disp.h
vars.o: vars.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
vars.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
vars.o: ./style.h ./externs.h
version.o: version.c
wind.o: wind.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
wind.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
wind.o: ./style.h ./externs.h ./termcap.h ./chars.h ./disp.h
getch.o: getch.c ./tune.h ./sysdep.h
mac.o: mac.c ./tune.h ./sysdep.h
keymaps.o: keymaps.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
keymaps.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
keymaps.o: ./screen.h ./style.h ./externs.h ./list.h ./fp.h ./termcap.h
keymaps.o: ./chars.h
pcscr.o: pcscr.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h ./iproc.h
pcscr.o: ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h ./screen.h
pcscr.o: ./style.h ./externs.h
portsrv.o: portsrv.c ./tune.h ./sysdep.h
recover.o: recover.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h ./io.h
recover.o: ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h ./vars.h
recover.o: ./screen.h ./style.h ./externs.h ./temp.h ./rec.h ./ctype.h
setmaps.o: setmaps.c ./funcdefs.c ./jove.h ./tune.h ./sysdep.h ./buf.h ./wind.h
setmaps.o: ./io.h ./iproc.h ./dataobj.h ./keymaps.h ./argcount.h ./util.h
setmaps.o: ./vars.h ./screen.h ./style.h ./externs.h ./ctype.h
teachjove.o: teachjove.c
kbd.o: kbd.c ./tune.h ./sysdep.h
# DEPENDENCIES MUST END AT END OF FILE
# IF YOU PUT STUFF HERE IT WILL GO AWAY
# see make depend above
@//E*O*F Makefile.uport//
chmod u=rw,g=r,o=r Makefile.uport
 
echo x - extend.c
sed 's/^@//' > "extend.c" <<'@//E*O*F extend.c//'
*** extend.c	Tue Feb 28 15:54:33 1989
--- ../extend.c	Thu Apr  6 13:21:41 1989
***************
*** 11,21
  #include "ctype.h"
  #include "chars.h"
  #include "disp.h"
  #include "re.h"
  
! #ifdef JOB_CONTROL
  # include <signal.h>
  #endif
  
  #ifdef MAC
  # include "mac.h"

--- 11,21 -----
  #include "ctype.h"
  #include "chars.h"
  #include "disp.h"
  #include "re.h"
  
! #if defined JOB_CONTROL || defined IPROCS
  # include <signal.h>
  #endif
  
  #ifdef MAC
  # include "mac.h"
@//E*O*F extend.c//
chmod u=rw,g=rw,o=r extend.c
 
echo x - fp.h
sed 's/^@//' > "fp.h" <<'@//E*O*F fp.h//'
*** fp.h	Tue Feb 28 15:54:34 1989
--- ../fp.h	Thu Apr  6 16:27:12 1989
***************
*** 3,12
   * is provided to you without charge, and with no warranty.  You may give  *
   * away copies of JOVE, including sources, provided that this notice is    *
   * included in all the files.                                              *
   ***************************************************************************/
  
  extern void	putchar proto((int c));	/* hidden by macro */
  
  #define putchar(c)	putc(c, stdout)
  #define putc(c, fp)	(--(fp)->f_cnt >= 0 ? (*(fp)->f_ptr++ = (c)) : _flush((c), fp))
  #define getc(fp)	(((--(fp)->f_cnt < 0) ? filbuf(fp) : *(fp)->f_ptr++))

--- 3,16 -----
   * is provided to you without charge, and with no warranty.  You may give  *
   * away copies of JOVE, including sources, provided that this notice is    *
   * included in all the files.                                              *
   ***************************************************************************/
  
+ #ifndef FPDEFINED
+ 
+ #define FPDEFINED
+ 
  extern void	putchar proto((int c));	/* hidden by macro */
  
  #define putchar(c)	putc(c, stdout)
  #define putc(c, fp)	(--(fp)->f_cnt >= 0 ? (*(fp)->f_ptr++ = (c)) : _flush((c), fp))
  #define getc(fp)	(((--(fp)->f_cnt < 0) ? filbuf(fp) : *(fp)->f_ptr++))
***************
*** 10,20
  #define putchar(c)	putc(c, stdout)
  #define putc(c, fp)	(--(fp)->f_cnt >= 0 ? (*(fp)->f_ptr++ = (c)) : _flush((c), fp))
  #define getc(fp)	(((--(fp)->f_cnt < 0) ? filbuf(fp) : *(fp)->f_ptr++))
  #define f_eof(fp)	(fp->f_flags & F_EOF)
  
! typedef struct file {
  	int	f_cnt,		/* number of characters left in buffer */
  		f_bufsize,	/* size of what f_base points to */
  		f_fd,		/* fildes */
  		f_flags;	/* various flags */
  	char	*f_ptr,		/* current offset */

--- 14,24 -----
  #define putchar(c)	putc(c, stdout)
  #define putc(c, fp)	(--(fp)->f_cnt >= 0 ? (*(fp)->f_ptr++ = (c)) : _flush((c), fp))
  #define getc(fp)	(((--(fp)->f_cnt < 0) ? filbuf(fp) : *(fp)->f_ptr++))
  #define f_eof(fp)	(fp->f_flags & F_EOF)
  
! typedef struct jove_file {
  	int	f_cnt,		/* number of characters left in buffer */
  		f_bufsize,	/* size of what f_base points to */
  		f_fd,		/* fildes */
  		f_flags;	/* various flags */
  	char	*f_ptr,		/* current offset */
***************
*** 67,71
  	flush proto((File *fp)),
  	flusho proto((void)),
  	fputnchar proto((char *s,int n,File *fp)),
  	gc_openfiles proto((void)),
  	putstr proto((char *s));

--- 71,76 -----
  	flush proto((File *fp)),
  	flusho proto((void)),
  	fputnchar proto((char *s,int n,File *fp)),
  	gc_openfiles proto((void)),
  	putstr proto((char *s));
+ #endif /* !FPDEFINED */
@//E*O*F fp.h//
chmod u=rw,g=rw,o=r fp.h
 
echo x - io.h
sed 's/^@//' > "io.h" <<'@//E*O*F io.h//'
*** io.h	Tue Feb 28 15:54:38 1989
--- ../io.h	Thu Apr  6 10:34:07 1989
***************
*** 21,31
  extern char
  	*lbptr proto((struct line *line)),
  	*pr_name proto((char *fname,int okay_home)),
  	*sprint proto((char *, ...));
  
! extern struct file
  	*open_file proto((char *fname,char *buf,int how,int complainifbad,int loudness));
  
  extern void
  	setCWD proto((char *d)),
  	getCWD proto((void)),

--- 21,31 -----
  extern char
  	*lbptr proto((struct line *line)),
  	*pr_name proto((char *fname,int okay_home)),
  	*sprint proto((char *, ...));
  
! extern struct jove_file
  	*open_file proto((char *fname,char *buf,int how,int complainifbad,int loudness));
  
  extern void
  	setCWD proto((char *d)),
  	getCWD proto((void)),
@//E*O*F io.h//
chmod u=rw,g=rw,o=r io.h
 
echo x - iproc-pipes.c
sed 's/^@//' > "iproc-pipes.c" <<'@//E*O*F iproc-pipes.c//'
*** iproc-pipes.c	Tue Feb 28 15:54:38 1989
--- ../iproc-pipes.c	Mon Apr 10 08:46:20 1989
***************
*** 122,132
  		p->p_toproc = -1;	/* writes will fail */
  		NumProcs -= 1;
  	}
  }
  
! void void
  proc_write(p, buf, nbytes)
  Process	*p;
  char	*buf;
  int	nbytes;
  {

--- 122,132 -----
  		p->p_toproc = -1;	/* writes will fail */
  		NumProcs -= 1;
  	}
  }
  
! void
  proc_write(p, buf, nbytes)
  Process	*p;
  char	*buf;
  int	nbytes;
  {
***************
*** 181,191
  	}
  
  	newp = (Process *) malloc(sizeof *newp);
  	newp->p_next = procs;
  	newp->p_state = NEW;
! 	newp->p_cmd = 0;
  
  	cmdbuf[0] = '\0';
  	va_init(ap, clobber);
  	while (cp = va_arg(ap, char *))
  		swritef(&cmdbuf[strlen(cmdbuf)], "%s ", cp);

--- 181,191 -----
  	}
  
  	newp = (Process *) malloc(sizeof *newp);
  	newp->p_next = procs;
  	newp->p_state = NEW;
! /*	newp->p_cmd = 0;*/
  
  	cmdbuf[0] = '\0';
  	va_init(ap, clobber);
  	while (cp = va_arg(ap, char *))
  		swritef(&cmdbuf[strlen(cmdbuf)], "%s ", cp);
***************
*** 235,245
  	if (kbd_pid == 0) {
  		signal(SIGINT, SIG_IGN);
  		signal(SIGALRM, SIG_IGN);
  		close(1);
  		dup(ProcOutput);
! 		execl(Kbd_Proc, "kbd", 0);
  		exit(-1);
  	}
  }
  
  private int	kbd_state = OFF;

--- 235,245 -----
  	if (kbd_pid == 0) {
  		signal(SIGINT, SIG_IGN);
  		signal(SIGALRM, SIG_IGN);
  		close(1);
  		dup(ProcOutput);
! 		execl(Kbd_Proc, "kbd", (char *)0);
  		exit(-1);
  	}
  }
  
  private int	kbd_state = OFF;
@//E*O*F iproc-pipes.c//
chmod u=rw,g=rw,o=r iproc-pipes.c
 
echo x - iproc.c
sed 's/^@//' > "iproc.c" <<'@//E*O*F iproc.c//'
*** iproc.c	Tue Feb 28 15:54:39 1989
--- ../iproc.c	Mon Apr 10 08:46:28 1989
***************
*** 174,183
  register Process	*p;
  int	sig;
  {
  	if (isdead(p))
  		return;
  	if (killpg(p->p_pid, sig) == -1)
  		s_mess("Cannot kill %s!", proc_buf(p));
  }
  
  /* Free process CHILD.  Do all the necessary cleaning up (closing fd's,

--- 174,186 -----
  register Process	*p;
  int	sig;
  {
  	if (isdead(p))
  		return;
+ #if defined u3b1 || defined UPORT
+ 	if (kill(p->p_pid, sig) == -1)
+ #else
  	if (killpg(p->p_pid, sig) == -1)
  #endif /* u3b1 || UPORT */
  		s_mess("Cannot kill %s!", proc_buf(p));
  }
  
***************
*** 175,184
  int	sig;
  {
  	if (isdead(p))
  		return;
  	if (killpg(p->p_pid, sig) == -1)
  		s_mess("Cannot kill %s!", proc_buf(p));
  }
  
  /* Free process CHILD.  Do all the necessary cleaning up (closing fd's,
     etc.). */

--- 178,188 -----
  		return;
  #if defined u3b1 || defined UPORT
  	if (kill(p->p_pid, sig) == -1)
  #else
  	if (killpg(p->p_pid, sig) == -1)
+ #endif /* u3b1 || UPORT */
  		s_mess("Cannot kill %s!", proc_buf(p));
  }
  
  /* Free process CHILD.  Do all the necessary cleaning up (closing fd's,
     etc.). */
***************
*** 402,412
  private int
  proc_child()
  {
  	union wait	w;
  	register int	pid;
! 
  	for (;;) {
  #ifndef BSD4_2
  		pid = wait2(&w.w_status, (WNOHANG | WUNTRACED));
  #else
  		pid = wait3(&w, (WNOHANG | WUNTRACED), (struct rusage *) 0);

--- 406,419 -----
  private int
  proc_child()
  {
  	union wait	w;
  	register int	pid;
! #if defined u3b1 || defined UPORT
! 	pid = wait();
! 	kill_off(pid, w);
! #else
  	for (;;) {
  #ifndef BSD4_2
  		pid = wait2(&w.w_status, (WNOHANG | WUNTRACED));
  #else
  		pid = wait3(&w, (WNOHANG | WUNTRACED), (struct rusage *) 0);
***************
*** 413,422
  #endif
  		if (pid <= 0)
  			break;
  		kill_off(pid, w);
  	}
  	return 0;	/* signal handlers return something! */
  }
  
  void
  kill_off(pid, w)

--- 420,430 -----
  #endif
  		if (pid <= 0)
  			break;
  		kill_off(pid, w);
  	}
+ #endif /* u3b1 || UPORT */
  	return 0;	/* signal handlers return something! */
  }
  
  void
  kill_off(pid, w)
@//E*O*F iproc.c//
chmod u=rw,g=rw,o=r iproc.c
 
echo x - iproc.h
sed 's/^@//' > "iproc.h" <<'@//E*O*F iproc.h//'
*** iproc.h	Tue Feb 28 15:54:41 1989
--- ../iproc.h	Thu Apr  6 16:31:58 1989
***************
*** 27,36
  };
  
  extern int  NumProcs;
  
  #ifdef PIPEPROCS
  extern File	*ProcInput;
  extern int	kbd_pid;
  #else
  extern long global_fd;
  #endif

--- 27,37 -----
  };
  
  extern int  NumProcs;
  
  #ifdef PIPEPROCS
+ #include "fp.h"
  extern File	*ProcInput;
  extern int	kbd_pid;
  #else
  extern long global_fd;
  #endif
@//E*O*F iproc.h//
chmod u=rw,g=rw,o=r iproc.h
 
echo x - jove.h
sed 's/^@//' > "jove.h" <<'@//E*O*F jove.h//'
*** jove.h	Tue Feb 28 15:54:42 1989
--- ../jove.h	Thu Apr  6 16:32:45 1989
***************
*** 12,21
  # include "tune.h"
  #endif
  
  #if !defined(MAC)
  # include <sys/types.h>
  # include <string.h>
  #else
  # include <types.h>
  #endif
  

--- 12,22 -----
  # include "tune.h"
  #endif
  
  #if !defined(MAC)
  # include <sys/types.h>
+ #ifdef u3b1
  # include <string.h>
  #else
  # include <strings.h>
  #endif /* u3b1 */
  #else
***************
*** 13,22
  #endif
  
  #if !defined(MAC)
  # include <sys/types.h>
  # include <string.h>
  #else
  # include <types.h>
  #endif
  
  #if defined(__STDC__) || defined(USE_PROTOTYPES)

--- 14,26 -----
  
  #if !defined(MAC)
  # include <sys/types.h>
  #ifdef u3b1
  # include <string.h>
+ #else
+ # include <strings.h>
+ #endif /* u3b1 */
  #else
  # include <types.h>
  #endif
  
  #if defined(__STDC__) || defined(USE_PROTOTYPES)
@//E*O*F jove.h//
chmod u=rw,g=rw,o=r jove.h
 
echo x - malloc.c
sed 's/^@//' > "malloc.c" <<'@//E*O*F malloc.c//'
*** malloc.c	Tue Feb 28 15:54:49 1989
--- ../malloc.c	Wed Mar 29 09:07:40 1989
***************
*** 4,14
   * away copies of JOVE, including sources, provided that this notice is    *
   * included in all the files.                                              *
   ***************************************************************************/
  
  #include "tune.h"
! 
  #ifdef MY_MALLOC
  
  /*	avoid break bug */
  #ifdef pdp11
  # define GRANULE 64

--- 4,14 -----
   * away copies of JOVE, including sources, provided that this notice is    *
   * included in all the files.                                              *
   ***************************************************************************/
  
  #include "tune.h"
! #include "sys/types.h"
  #ifdef MY_MALLOC
  
  /*	avoid break bug */
  #ifdef pdp11
  # define GRANULE 64
@//E*O*F malloc.c//
chmod u=rw,g=rw,o=r malloc.c
 
echo x - portsrv.c
sed 's/^@//' > "portsrv.c" <<'@//E*O*F portsrv.c//'
*** portsrv.c	Tue Feb 28 15:54:53 1989
--- ../portsrv.c	Thu Apr  6 16:34:07 1989
***************
*** 14,23
  
  #define EOF	-1
  
  #include <signal.h>
  #include <sys/ioctl.h>
  #include "wait.h"
  
  struct header {
  	int	pid;
  	int	nbytes;

--- 14,24 -----
  
  #define EOF	-1
  
  #include <signal.h>
  #include <sys/ioctl.h>
+ #include "jove.h"
  #include "wait.h"
  
  struct header {
  	int	pid;
  	int	nbytes;
@//E*O*F portsrv.c//
chmod u=rw,g=rw,o=r portsrv.c
 
echo x - proc.c
sed 's/^@//' > "proc.c" <<'@//E*O*F proc.c//'
*** proc.c	Tue Feb 28 15:54:53 1989
--- ../proc.c	Mon Apr 10 08:46:35 1989
***************
*** 504,515
  void
  dowait(pid, status)
  int	pid,
  	*status;
  {
! # ifndef IPROCS
! 
  	int	rpid;
  
  	while ((rpid = wait(status)) != pid)
  		;
  # else

--- 504,514 -----
  void
  dowait(pid, status)
  int	pid,
  	*status;
  {
! # if !defined IPROCS || defined u3b1 || defined UPORT
  	int	rpid;
  
  	while ((rpid = wait(status)) != pid)
  		;
  # else
@//E*O*F proc.c//
chmod u=rw,g=rw,o=r proc.c
 
echo x - sysdep.3b1
sed 's/^@//' > "sysdep.3b1" <<'@//E*O*F sysdep.3b1//'
/***************************************************************************
 * This program is Copyright (C) 1986, 1987, 1988 by Jonathan Payne.  JOVE *
 * is provided to you without charge, and with no warranty.  You may give  *
 * away copies of JOVE, including sources, provided that this notice is    *
 * included in all the files.                                              *
 ***************************************************************************/

#ifdef THINK_C
# define MAC 1
# define defined(x) (x)	/* take this out and you're in trouble... */
#endif

#ifdef	MAC
    extern int	errno;
#endif	/* MAC */

#if !(defined(MSDOS) || defined(MAC) || defined(__STDC__))
# define void int
#endif

#ifndef	__STDC__
#define	const
#endif

/* The operating system (MSDOS or MAC) must be defined by this point.
   IBMPC is defined in the Makefile. All MAC defines should be
   numerical (i.e. #define MAC 1) so that defined() will work. */

#if !(defined(MSDOS) || defined(MAC))
# define UNIX
#endif

#ifdef UNIX
# if !sun
    extern int	errno;
# endif
/*# define YP_PASSWD	/* if you are a sun running the yellow pages */
/*# define VFORK		/* if you have vfork(2) */
/*# define JOB_CONTROL	/* if you have job stopping */
# ifdef JOB_CONTROL
#  define MENLO_JCL
# endif
# define KILL0		/* kill(pid, 0) returns 0 if proc exists */
#endif /* UNIX */

#ifdef UNIX
# ifdef pdp11
#  define SMALL
#  define BUFSIZ	512	/* or 1024 */
#  define NBUF		3
# else
#  define VMUNIX		/* Virtual Memory UNIX */
#  define BUFSIZ	1024
#  ifdef iAPX286
#   define NBUF		48	/* NBUF*BUFSIZ must be less than 64 kB */
#  else
#   define NBUF	64	/* number of disk buffers */
#  endif /* iAPX286 */
# endif
#endif

#ifdef SMALL
  typedef unsigned short	daddr;
#else
# if defined(iAPX286) || defined(MSDOS) || defined(MAC)
   typedef long	daddr;
# else
   typedef	int	daddr;
# endif /* iAPX286 */
#endif /* SMALL */

#ifdef UNIX
			/* pick your version of Unix */
/*# define BSD4_2		/* Berkeley 4.2 BSD */
/*# define BSD4_3		/* Berkeley 4.3 BSD and 2.10 BSD */
/*# define SYSV		-- for (System III/System V) UNIX systems */
# define SYSVR2	-- system 5, rel. 2 */
			/* M_XENIX is defined by the Compiler */
#endif /* UNIX */

#ifdef SYSVR2
# ifndef SYSV
#  define SYSV	/* SYSV is a subset of SYSVR2 */
# endif
#endif

#ifdef BSD4_3
# ifndef BSD4_2
#  define BSD4_2	/* 4.3 is 4.2 only different. */
# endif
#endif

#ifdef M_XENIX
# define iAPX286 1	/* we have segments */
#endif

#ifdef MSDOS
# ifdef M_I86LM		/* large memory model */
#  define NBUF 		64
# else
#  define NBUF 		3
#  define SMALL
# endif
# define BUFSIZ		512		/* or 1024 */
#endif

#if !sun && !iAPX286
/*# define MY_MALLOC	/* use more memory efficient malloc (not on suns) */
#endif

#if (defined(BSD4_3) || defined(MAC))
# define RESHAPING	/* enable windows to handle reshaping */
#endif

#ifdef BSD4_2			/* byte_copy(from, to, len) */
# define byte_copy	bcopy	/* use fast assembler version */
#endif

#if defined(IPROCS) && !defined(BSD4_2)
# define PIPEPROCS		/* do it with pipes */
#endif

#if defined(SYSV) || defined(MSDOS) || defined(M_XENIX)
# define byte_copy(s2, s1, n)	memcpy(s1, s2, n)
# define bzero(s, n)		memset(s, 0, n)
# define index	strchr
# define rindex	strrchr
#endif

#ifndef BSD4_2
# ifdef MENLO_JCL
#  define signal	sigset
# endif /* MENLO_JCL */
#endif

#if !(defined(IBMPC) || defined(MAC))
# define TERMCAP
# define ASCII
#endif

#ifdef ASCII	/* seven bit characters */
# define NCHARS 0200
#else
# define NCHARS 0400
#endif

#define CHARMASK (NCHARS - 1)

#ifndef MSDOS
# define FILESIZE	256
#else /* MSDOS */
# define FILESIZE	64
#endif /* MSDOS */

#if defined(BSD4_2)
extern long	SigMask;

# define SigHold(s)	sigblock(SigMask |= sigmask(s))
# define SigRelse(s)	sigsetmask(SigMask &= ~sigmask(s))
#endif
@//E*O*F sysdep.3b1//
chmod u=rw,g=rw,o=r sysdep.3b1
 
echo x - sysdep.h
sed 's/^@//' > "sysdep.h" <<'@//E*O*F sysdep.h//'
*** sysdep.h	Tue Feb 28 15:55:00 1989
--- ../sysdep.h	Mon Apr 10 08:51:58 1989
***************
*** 32,42
  
  #ifdef UNIX
  # if !sun
      extern int	errno;
  # endif
! # define YP_PASSWD	/* if you are a sun running the yellow pages */
  # define VFORK		/* if you have vfork(2) */
  # define JOB_CONTROL	/* if you have job stopping */
  # ifdef JOB_CONTROL
  #  define MENLO_JCL
  # endif

--- 32,42 -----
  
  #ifdef UNIX
  # if !sun
      extern int	errno;
  # endif
! /*# define YP_PASSWD	/* if you are a sun running the yellow pages */
  # define VFORK		/* if you have vfork(2) */
  # define JOB_CONTROL	/* if you have job stopping */
  # ifdef JOB_CONTROL
  #  define MENLO_JCL
  # endif
***************
*** 70,80
  #endif /* SMALL */
  
  #ifdef UNIX
  			/* pick your version of Unix */
  # define BSD4_2		/* Berkeley 4.2 BSD */
! # define BSD4_3		/* Berkeley 4.3 BSD and 2.10 BSD */
  /*# define SYSV		-- for (System III/System V) UNIX systems */
  /*# define SYSVR2	-- system 5, rel. 2 */
  			/* M_XENIX is defined by the Compiler */
  #endif /* UNIX */
  

--- 70,80 -----
  #endif /* SMALL */
  
  #ifdef UNIX
  			/* pick your version of Unix */
  # define BSD4_2		/* Berkeley 4.2 BSD */
! /*# define BSD4_3		/* Berkeley 4.3 BSD and 2.10 BSD */
  /*# define SYSV		-- for (System III/System V) UNIX systems */
  /*# define SYSVR2	-- system 5, rel. 2 */
  			/* M_XENIX is defined by the Compiler */
  #endif /* UNIX */
  
***************
*** 103,113
  # endif
  # define BUFSIZ		512		/* or 1024 */
  #endif
  
  #if !sun && !iAPX286
! # define MY_MALLOC	/* use more memory efficient malloc (not on suns) */
  #endif
  
  #if (defined(BSD4_3) || defined(MAC))
  # define RESHAPING	/* enable windows to handle reshaping */
  #endif

--- 103,113 -----
  # endif
  # define BUFSIZ		512		/* or 1024 */
  #endif
  
  #if !sun && !iAPX286
! /*# define MY_MALLOC	/* use more memory efficient malloc (not on suns) */
  #endif
  
  #if (defined(BSD4_3) || defined(MAC))
  # define RESHAPING	/* enable windows to handle reshaping */
  #endif
***************
*** 155,160
  #if defined(BSD4_2)
  extern long	SigMask;
  
  # define SigHold(s)	sigblock(SigMask |= sigmask(s))
  # define SigRelse(s)	sigsetmask(SigMask &= ~sigmask(s))
  #endif

--- 155,163 -----
  #if defined(BSD4_2)
  extern long	SigMask;
  
  # define SigHold(s)	sigblock(SigMask |= sigmask(s))
  # define SigRelse(s)	sigsetmask(SigMask &= ~sigmask(s))
+ #else
+ # define SigHold(s)
+ # define SigRelse(s)
  #endif
@//E*O*F sysdep.h//
chmod u=rw,g=rw,o=r sysdep.h
 
echo x - sysdep.uport
sed 's/^@//' > "sysdep.uport" <<'@//E*O*F sysdep.uport//'
/***************************************************************************
 * This program is Copyright (C) 1986, 1987, 1988 by Jonathan Payne.  JOVE *
 * is provided to you without charge, and with no warranty.  You may give  *
 * away copies of JOVE, including sources, provided that this notice is    *
 * included in all the files.                                              *
 ***************************************************************************/

#ifdef THINK_C
# define MAC 1
# define defined(x) (x)	/* take this out and you're in trouble... */
#endif

#ifdef	MAC
    extern int	errno;
#endif	/* MAC */

#if !(defined(MSDOS) || defined(MAC) || defined(__STDC__))
# define void int
#endif

#ifndef	__STDC__
#define	const
#endif

/* The operating system (MSDOS or MAC) must be defined by this point.
   IBMPC is defined in the Makefile. All MAC defines should be
   numerical (i.e. #define MAC 1) so that defined() will work. */

#if !(defined(MSDOS) || defined(MAC))
# define UNIX
#endif

#ifdef UNIX
# if !sun
    extern int	errno;
# endif
/*# define YP_PASSWD	/* if you are a sun running the yellow pages */
# define VFORK		/* if you have vfork(2) */
# define JOB_CONTROL	/* if you have job stopping */
# ifdef JOB_CONTROL
#  define MENLO_JCL
# endif
# define KILL0		/* kill(pid, 0) returns 0 if proc exists */
#endif /* UNIX */

#ifdef UNIX
# ifdef pdp11
#  define SMALL
#  define BUFSIZ	512	/* or 1024 */
#  define NBUF		3
# else
#  define VMUNIX		/* Virtual Memory UNIX */
#  define BUFSIZ	1024
#  ifdef iAPX286
#   define NBUF		48	/* NBUF*BUFSIZ must be less than 64 kB */
#  else
#   define NBUF	64	/* number of disk buffers */
#  endif /* iAPX286 */
# endif
#endif

#ifdef SMALL
  typedef unsigned short	daddr;
#else
# if defined(iAPX286) || defined(MSDOS) || defined(MAC)
   typedef long	daddr;
# else
   typedef	int	daddr;
# endif /* iAPX286 */
#endif /* SMALL */

#ifdef UNIX
			/* pick your version of Unix */
# define BSD4_2		/* Berkeley 4.2 BSD */
/*# define BSD4_3		/* Berkeley 4.3 BSD and 2.10 BSD */
/*# define SYSV		-- for (System III/System V) UNIX systems */
/*# define SYSVR2	-- system 5, rel. 2 */
			/* M_XENIX is defined by the Compiler */
#endif /* UNIX */

#ifdef SYSVR2
# ifndef SYSV
#  define SYSV	/* SYSV is a subset of SYSVR2 */
# endif
#endif

#ifdef BSD4_3
# ifndef BSD4_2
#  define BSD4_2	/* 4.3 is 4.2 only different. */
# endif
#endif

#ifdef M_XENIX
# define iAPX286 1	/* we have segments */
#endif

#ifdef MSDOS
# ifdef M_I86LM		/* large memory model */
#  define NBUF 		64
# else
#  define NBUF 		3
#  define SMALL
# endif
# define BUFSIZ		512		/* or 1024 */
#endif

#if !sun && !iAPX286
/*# define MY_MALLOC	/* use more memory efficient malloc (not on suns) */
#endif

#if (defined(BSD4_3) || defined(MAC))
# define RESHAPING	/* enable windows to handle reshaping */
#endif

#ifdef BSD4_2			/* byte_copy(from, to, len) */
# define byte_copy	bcopy	/* use fast assembler version */
#endif

#if defined(IPROCS) && !defined(BSD4_2)
# define PIPEPROCS		/* do it with pipes */
#endif

#if defined(SYSV) || defined(MSDOS) || defined(M_XENIX)
# define byte_copy(s2, s1, n)	memcpy(s1, s2, n)
# define bzero(s, n)		memset(s, 0, n)
# define index	strchr
# define rindex	strrchr
#endif

#ifndef BSD4_2
# ifdef MENLO_JCL
#  define signal	sigset
# endif /* MENLO_JCL */
#endif

#if !(defined(IBMPC) || defined(MAC))
# define TERMCAP
# define ASCII
#endif

#ifdef ASCII	/* seven bit characters */
# define NCHARS 0200
#else
# define NCHARS 0400
#endif

#define CHARMASK (NCHARS - 1)

#ifndef MSDOS
# define FILESIZE	256
#else /* MSDOS */
# define FILESIZE	64
#endif /* MSDOS */

#if defined(BSD4_2)
extern long	SigMask;

# define SigHold(s)	sigblock(SigMask |= sigmask(s))
# define SigRelse(s)	sigsetmask(SigMask &= ~sigmask(s))
#else
# define SigHold(s)
# define SigRelse(s)
#endif
@//E*O*F sysdep.uport//
chmod u=rw,g=rw,o=r sysdep.uport
 
echo x - term.c
sed 's/^@//' > "term.c" <<'@//E*O*F term.c//'
*** term.c	Tue Feb 28 15:55:02 1989
--- ../term.c	Mon Apr 10 08:48:17 1989
***************
*** 84,93
  	TABS,
  	UPlen,
  	HOlen,
  	LLlen;
  
  #ifdef notdef
  	/*
  	 * Are you sure about this one Jon?  On the SYSV system I tried this
  	 * on I got a multiple definition of PC because it was already
  	 * defined in -ltermcap.  Similarly for BC and UP ...

--- 84,99 -----
  	TABS,
  	UPlen,
  	HOlen,
  	LLlen;
  
+ #ifdef UPORT
+ char	PC,
+ 	*BC,		/* back space */
+ 	*UP;	/* Scroll reverse, or up */
+ short	ospeed;
+ #endif
  #ifdef notdef
  	/*
  	 * Are you sure about this one Jon?  On the SYSV system I tried this
  	 * on I got a multiple definition of PC because it was already
  	 * defined in -ltermcap.  Similarly for BC and UP ...
***************
*** 180,190
  		static char	nm[3] = "xx";
  
  		nm[0] = *tsp++;
  		nm[1] = *tsp++;
  		*(meas[i]) = (char *) tgetstr(nm, &termp);
! 		if (termp > tspace + sizeof(tspace))
  			goto wimperr;
  	}
  	if (lPC)
  		PC = *lPC;
  	if (XS)

--- 188,200 -----
  		static char	nm[3] = "xx";
  
  		nm[0] = *tsp++;
  		nm[1] = *tsp++;
  		*(meas[i]) = (char *) tgetstr(nm, &termp);
! #ifndef UPORT
! 		if (termp > tspace+ sizeof(tspace))
  			goto wimperr;
  }
  #endif
  	}
  	if (lPC)
***************
*** 182,191
  		nm[0] = *tsp++;
  		nm[1] = *tsp++;
  		*(meas[i]) = (char *) tgetstr(nm, &termp);
  		if (termp > tspace + sizeof(tspace))
  			goto wimperr;
  	}
  	if (lPC)
  		PC = *lPC;
  	if (XS)
  		SO = SE = 0;

--- 192,203 -----
  		*(meas[i]) = (char *) tgetstr(nm, &termp);
  #ifndef UPORT
  		if (termp > tspac e+ sizeof(tspace))
  			goto wimperr;
+ #endif
  	}
  	if (lPC)
  		PC = *lPC;
  	if (XS)
  		SO = SE = 0;
@//E*O*F term.c//
chmod u=rw,g=rw,o=r term.c
 
echo x - tune.3b1
sed 's/^@//' > "tune.3b1" <<'@//E*O*F tune.3b1//'
/***************************************************************************
 * This program is Copyright (C) 1986, 1987, 1988 by Jonathan Payne.  JOVE *
 * is provided to you without charge, and with no warranty.  You may give  *
 * away copies of JOVE, including sources, provided that this notice is    *
 * included in all the files.                                              *
 ***************************************************************************/

#define TUNED		/* don't touch this */

# define IPROCS		/* interactive processes */
#include "sysdep.h"

#ifdef UNIX
# define SUBPROCS	/* only on UNIX systems (NOT INCORPORATED YET) */
# define IPROCS		/* interactive processes */
#endif /* UNIX */

#ifndef VFORK
# define vfork	fork
#endif

#define BACKUPFILES	/* enable the backup files code */
#define F_COMPLETION	/* filename completion */
#define ABBREV		/* word abbreviation mode */
#if !(defined(IBMPC) || defined(MAC))
# define ID_CHAR	/* include code to IDchar */
/*# define WIRED_TERMS	/* include code for wired terminals */
#endif
#define LISP		/* include the code for Lisp Mode */
#define CMT_FMT		/* include the comment formatting routines */

#ifdef UNIX
/*# define LOAD_AV	/* Use the load average for various commands.
#			   Do not define this if you lack a load average
#			   system call and kmem is read protected. */
#
/*# define BIFF		/* if you have biff (or the equivalent) */
# define SPELL		/* spell words and buffer commands */
#endif

#define DFLT_MODE	0664	/* file will be created with this mode */

#ifdef MAC
# undef F_COMPLETION
# define F_COMPLETION 1
# define rindex strrchr
# define bzero(s,n) setmem(s,n,0)
# define swritef sprintf
# define USE_PROTOTYPES	1
# define NBUF 64
# define BUFSIZ 1024
# undef LISP
# define LISP 1
# undef ABBREV
# define ABBREV 1
# undef CMT_FMT
# define CMT_FMT 1
#endif

/* These are here since they define things in tune.c.  If you add things to
   tune.c, add them here too, if necessary. */

extern char
	*d_tempfile,
	*p_tempfile,
	*Recover,
	*Joverc,

#ifdef PIPEPROCS
	*Portsrv,
	*Kbd_Proc,
#endif

#ifdef MSDOS
	CmdDb[],
#else
	*CmdDb,
#endif

	TmpFilePath[],
	Shell[],
	ShFlags[];
@//E*O*F tune.3b1//
chmod u=rw,g=r,o=r tune.3b1
 
echo x - tune.h
sed 's/^@//' > "tune.h" <<'@//E*O*F tune.h//'
*** tune.h	Tue Feb 28 15:55:04 1989
--- ../tune.h	Mon Apr 10 08:50:34 1989
***************
*** 5,14
   * included in all the files.                                              *
   ***************************************************************************/
  
  #define TUNED		/* don't touch this */
  
  #include "sysdep.h"
  
  #ifdef UNIX
  # define SUBPROCS	/* only on UNIX systems (NOT INCORPORATED YET) */
  # define IPROCS		/* interactive processes */

--- 5,18 -----
   * included in all the files.                                              *
   ***************************************************************************/
  
  #define TUNED		/* don't touch this */
  
+ #if defined u3b1 || defined UPORT	/* fix this? */
+ # define IPROCS		/* interactive processes */
+ #endif /* u3b1 || UPORT */
+ 
  #include "sysdep.h"
  
  #ifdef UNIX
  # define SUBPROCS	/* only on UNIX systems (NOT INCORPORATED YET) */
  # define IPROCS		/* interactive processes */
***************
*** 21,31
  #define BACKUPFILES	/* enable the backup files code */
  #define F_COMPLETION	/* filename completion */
  #define ABBREV		/* word abbreviation mode */
  #if !(defined(IBMPC) || defined(MAC))
  # define ID_CHAR	/* include code to IDchar */
! # define WIRED_TERMS	/* include code for wired terminals */
  #endif
  #define LISP		/* include the code for Lisp Mode */
  #define CMT_FMT		/* include the comment formatting routines */
  
  #ifdef UNIX

--- 25,35 -----
  #define BACKUPFILES	/* enable the backup files code */
  #define F_COMPLETION	/* filename completion */
  #define ABBREV		/* word abbreviation mode */
  #if !(defined(IBMPC) || defined(MAC))
  # define ID_CHAR	/* include code to IDchar */
! /*# define WIRED_TERMS	/* include code for wired terminals */
  #endif
  #define LISP		/* include the code for Lisp Mode */
  #define CMT_FMT		/* include the comment formatting routines */
  
  #ifdef UNIX
***************
*** 35,45
  #
  # define BIFF		/* if you have biff (or the equivalent) */
  # define SPELL		/* spell words and buffer commands */
  #endif
  
! #define DFLT_MODE	0666	/* file will be created with this mode */
  
  #ifdef MAC
  # undef F_COMPLETION
  # define F_COMPLETION 1
  # define rindex strrchr

--- 39,49 -----
  #
  # define BIFF		/* if you have biff (or the equivalent) */
  # define SPELL		/* spell words and buffer commands */
  #endif
  
! #define DFLT_MODE	0664	/* file will be created with this mode */
  
  #ifdef MAC
  # undef F_COMPLETION
  # define F_COMPLETION 1
  # define rindex strrchr
@//E*O*F tune.h//
chmod u=rw,g=rw,o=r tune.h
 
echo x - tune.uport
sed 's/^@//' > "tune.uport" <<'@//E*O*F tune.uport//'
/***************************************************************************
 * This program is Copyright (C) 1986, 1987, 1988 by Jonathan Payne.  JOVE *
 * is provided to you without charge, and with no warranty.  You may give  *
 * away copies of JOVE, including sources, provided that this notice is    *
 * included in all the files.                                              *
 ***************************************************************************/

#define TUNED		/* don't touch this */

#if defined u3b1 || defined UPORT	/* fix this? */
# define IPROCS		/* interactive processes */
#endif /* u3b1 || UPORT */
#include "sysdep.h"

#ifdef UNIX
# define SUBPROCS	/* only on UNIX systems (NOT INCORPORATED YET) */
# define IPROCS		/* interactive processes */
#endif /* UNIX */

#ifndef VFORK
# define vfork	fork
#endif

#define BACKUPFILES	/* enable the backup files code */
#define F_COMPLETION	/* filename completion */
#define ABBREV		/* word abbreviation mode */
#if !(defined(IBMPC) || defined(MAC))
# define ID_CHAR	/* include code to IDchar */
/*# define WIRED_TERMS	/* include code for wired terminals */
#endif
#define LISP		/* include the code for Lisp Mode */
#define CMT_FMT		/* include the comment formatting routines */

#ifdef UNIX
/*# define LOAD_AV	/* Use the load average for various commands.
#			   Do not define this if you lack a load average
#			   system call and kmem is read protected. */
#
/*# define BIFF		/* if you have biff (or the equivalent) */
# define SPELL		/* spell words and buffer commands */
#endif

#define DFLT_MODE	0664	/* file will be created with this mode */

#ifdef MAC
# undef F_COMPLETION
# define F_COMPLETION 1
# define rindex strrchr
# define bzero(s,n) setmem(s,n,0)
# define swritef sprintf
# define USE_PROTOTYPES	1
# define NBUF 64
# define BUFSIZ 1024
# undef LISP
# define LISP 1
# undef ABBREV
# define ABBREV 1
# undef CMT_FMT
# define CMT_FMT 1
#endif

/* These are here since they define things in tune.c.  If you add things to
   tune.c, add them here too, if necessary. */

extern char
	*d_tempfile,
	*p_tempfile,
	*Recover,
	*Joverc,

#ifdef PIPEPROCS
	*Portsrv,
	*Kbd_Proc,
#endif

#ifdef MSDOS
	CmdDb[],
#else
	*CmdDb,
#endif

	TmpFilePath[],
	Shell[],
	ShFlags[];
@//E*O*F tune.uport//
chmod u=rw,g=r,o=r tune.uport
 
echo x - util.c
sed 's/^@//' > "util.c" <<'@//E*O*F util.c//'
*** util.c	Tue Feb 28 15:55:05 1989
--- ../util.c	Thu Apr  6 11:10:20 1989
***************
*** 7,16
  
  #include "jove.h"
  #include "ctype.h"
  #include "termcap.h"
  #include "disp.h"
  #include <signal.h>
  
  #ifdef MAC
  # include "mac.h"
  #else

--- 7,17 -----
  
  #include "jove.h"
  #include "ctype.h"
  #include "termcap.h"
  #include "disp.h"
+ #include "fp.h"
  #include <signal.h>
  
  #ifdef MAC
  # include "mac.h"
  #else
***************
*** 767,776
  static struct	nlist nl[] = {
  	{ "_avenrun" },
  #define	X_AVENRUN	0
  	{ "" }
  };
  
  void
  get_la(dp)
  double	*dp;
  {

--- 768,782 -----
  static struct	nlist nl[] = {
  	{ "_avenrun" },
  #define	X_AVENRUN	0
  	{ "" }
  };
+ #ifdef sequent
+ #define	LA_UNIX	"/dynix"
+ #else
+ #define	LA_UNIX	"/vmunix"
+ #endif
  
  void
  get_la(dp)
  double	*dp;
  {
***************
*** 772,782
  
  void
  get_la(dp)
  double	*dp;
  {
! #ifdef sun
  	long	avenrun[3];
  #else
  	double	avenrun[3];
  #endif
  	static int	kmem = 0;

--- 778,791 -----
  
  void
  get_la(dp)
  double	*dp;
  {
! #ifdef sequent
! 	unsigned long	avenrun[3];
! #else
! #if sun
  	long	avenrun[3];
  #else
  	double	avenrun[3];
  #endif
  #endif
***************
*** 777,786
  #ifdef sun
  	long	avenrun[3];
  #else
  	double	avenrun[3];
  #endif
  	static int	kmem = 0;
  	extern long	lseek proto((int, long, int));
  
  	if (kmem == -1) {
  		*dp = 4.0;	/* So shell commands will say "Chugging" */

--- 786,796 -----
  #if sun
  	long	avenrun[3];
  #else
  	double	avenrun[3];
  #endif
+ #endif
  	static int	kmem = 0;
  	extern long	lseek proto((int, long, int));
  
  	if (kmem == -1) {
  		*dp = 4.0;	/* So shell commands will say "Chugging" */
***************
*** 789,799
  		if ((kmem = open("/dev/kmem", 0)) == -1) {
  			f_mess("Can't open kmem for load average.");
  			*dp = 4.0;
  			return;
  		}
! 		nlist("/vmunix", nl);
  	}
  	lseek(kmem, (long) nl[X_AVENRUN].n_value, 0);
  	read(kmem, (char *) avenrun, sizeof(avenrun));
  #ifdef sun
  	*dp = (double) avenrun[0] / FSCALE;

--- 799,809 -----
  		if ((kmem = open("/dev/kmem", 0)) == -1) {
  			f_mess("Can't open kmem for load average.");
  			*dp = 4.0;
  			return;
  		}
! 		nlist(LA_UNIX, nl);
  	}
  	lseek(kmem, (long) nl[X_AVENRUN].n_value, 0);
  	read(kmem, (char *) avenrun, sizeof(avenrun));
  #ifdef sun
  	*dp = (double) avenrun[0] / FSCALE;
***************
*** 796,805
  	lseek(kmem, (long) nl[X_AVENRUN].n_value, 0);
  	read(kmem, (char *) avenrun, sizeof(avenrun));
  #ifdef sun
  	*dp = (double) avenrun[0] / FSCALE;
  #else
  	*dp = avenrun[0];
  #endif
  }
  
  #    endif

--- 806,819 -----
  	lseek(kmem, (long) nl[X_AVENRUN].n_value, 0);
  	read(kmem, (char *) avenrun, sizeof(avenrun));
  #ifdef sun
  	*dp = (double) avenrun[0] / FSCALE;
  #else
+ #ifdef sequent
+ #define	FSCALE 1000.0
+ 	*dp = (double) avenrun[0] / FSCALE;
+ #else
  	*dp = avenrun[0];
  #endif
  #endif
  }
  
***************
*** 797,806
  	read(kmem, (char *) avenrun, sizeof(avenrun));
  #ifdef sun
  	*dp = (double) avenrun[0] / FSCALE;
  #else
  	*dp = avenrun[0];
  #endif
  }
  
  #    endif
  #  else /* !BSD4_2 || BSD2_10 */

--- 811,821 -----
  #ifdef sequent
  #define	FSCALE 1000.0
  	*dp = (double) avenrun[0] / FSCALE;
  #else
  	*dp = avenrun[0];
+ #endif
  #endif
  }
  
  #    endif
  #  else /* !BSD4_2 || BSD2_10 */
@//E*O*F util.c//
chmod u=rw,g=rw,o=r util.c
 
exit 0

reynolds@dasys1.UUCP (Brian Reynolds) (04/13/89)

In article <237@libove.UUCP> root@libove.UUCP (Jay M. Libove) writes:
>Has anyone gotten JOVE version 4.12 to compile on SCO Xenix 80286
>(version 2.2.1 just if it matters) ?
[deleted]
>/usr/include/sys/file.h(24) : error 25: `file' : enum/struct/union type redefinition
>io.c(97) : error 38: `f_flags' : not struct/union member
[deleted]

This looks like some of the trouble I am having with jove on a Stride
460 running System V.  Go into sysdep.h and change the #defines to
allow System V instead of BSD.  After this change you may get an error
when making setmaps.  If you get this working let me know.  I still
can't get jove to make on the Stride. 

>Jay Libove		jl42@andrew.cmu.edu, libove@cs.cmu.edu,


ttfn,
Brian


-- 
     # ## #     |Brian Reynolds
     # ## #     |UUCP:          ...!sun!gotham\
    ## ## ##    |         ...!cmcl2!phri!dasys1!marine!reynolds
 ####  ##  #### |             ...!uunet/

allbery@ncoast.ORG (Brandon S. Allbery) (04/14/89)

As quoted from <237@libove.UUCP> by root@libove.UUCP (Jay M. Libove):
+---------------
| Has anyone gotten JOVE version 4.12 to compile on SCO Xenix 80286
| (version 2.2.1 just if it matters) ?
| 
| I have worked through a number of small things, and finally ended
| up with:
| 
| 	cc -O -LARGE -F 3000 -K -Ml2e -c io.c
| io.c
| /usr/include/sys/file.h(24) : error 25: `file' : enum/struct/union type redefinition
+---------------

Jove 4.12 is NOT directly portable to System V.  I'm still working on diffs.

The problem is that Jove uses a "struct file" internally, then #include's
<sys/file.h> -- which is the Berkeley version of what we call <fcntl.h>.
Under AT&T-derived Unixes, <sys/file.h> defines the kernel's struct file,
causing a collision.

Quick fix:

	#ifdef SYSV
	#include <fcntl.h>
	#define FREAD O_RDONLY	/* working from memory, here -- the actual */
	#define FWRITE O_WRONLY	/* BSD flag names may be different */
	#define FCREAT O_CREAT
	#else
	#include <sys/file.h>
	#endif

This isn't the only System V incompatibility, however.  I'll post my diffs
when they're complete; I'm still working on things like using SVR3 signal
handling to compensate for interruptable I/O where possible (a big win over
the SVR2 version when editing large files).  I'm also working in my modified
C-mode backspace code as an option controlled by both #define and variable.

++Brandon
-- 
Brandon S. Allbery, moderator of comp.sources.misc	     allbery@ncoast.org
uunet!hal.cwru.edu!ncoast!allbery		    ncoast!allbery@hal.cwru.edu
      Send comp.sources.misc submissions to comp-sources-misc@<backbone>
NCoast Public Access UN*X - (216) 781-6201, 300/1200/2400 baud, login: makeuser