From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,eb90bc1efbb819f4,start X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1993-06-09 12:07:24 PST Newsgroups: comp.unix.osf.osf1 Path: gmd.de!newsserver.jvnc.net!howland.reston.ans.net!usc!sol.ctr.columbia.edu!news.kei.com!ssd.intel.com!cfj From: cfj@ssd.intel.com (Charlie Johnson) Subject: tcsh 6.03 mods for Intel Paragon OSF/1 Message-ID: Sender: usenet@SSD.intel.com Nntp-Posting-Host: alaska Organization: Intel Corporation Date: Wed, 9 Jun 1993 19:00:33 GMT Here are the files I ether changed or added to get tcsh 6.03 up on Intel Paragon OSF/1. This is a shar archive. -- Charles Johnson Intel Corporation Supercomputer Systems Division MS CO1-01 15201 NW Greenbrier Pkwy Beaverton, OR 97006 phone: (503)629-7605 email: cfj@ssd.intel.com -------------------------------------------------------------- # This is a shell archive. Save it in a file, remove anything before # this line, and then unpack it by entering "sh file". Note, it may # create directories; files and directories will be owned by you and # have default permissions. # # This archive contains: # # ./Makefile # ./tc.sig.c # ./tc.vers.c # ./config/config.paragon-osf1 # echo x - ./Makefile sed 's/^X//' >./Makefile << 'END-of-./Makefile' X# $Id: Makefile,v 1.42 1992/11/20 08:56:38 christos Exp $ X# Makefile 4.3 6/11/83 X# X# C Shell with process control; VM/UNIX VAX Makefile X# Bill Joy UC Berkeley; Jim Kulp IIASA, Austria X# X# With an input editor, command completion, etc. and ported to all sorts of X# things; Paul Placeway, CIS Dept., Ohio State University X# XSHELL=/bin/sh XVERSION=6.03 XBUILD=tcsh X#BUILD=jump # Build tcsh.a and link it with jump table libraries (linux) X#BUILD=nojump # Build tcsh.a and link it with shared libraries (linux) X#BUILD=static # Build tcsh.a and link it with static libraries (linux) X X################################################################ X## CFLAGS. For various -D things, see config.h X################################################################ X# X# These are the default suffixes from .c to .o and -c to get there X# but to use the global optimizer on the mips boxes, see below X# XSUF=o XCF=-c X XINCLUDES=-I. -I.. X XLFLAGS=$(INCLUDES) X#LFLAGS=$(INCLUDES) -Zn10000 # hpux lint X X X#CFLAGS= $(INCLUDES) -g # debug X#CFLAGS= $(INCLUDES) -O # production X#CFLAGS= $(INCLUDES) # Broken optimizers.... X X#CFLAGS= -g -pg $(INCLUDES) -DPROF X#CFLAGS= -O -pg $(INCLUDES) -DPROF X X# gcc 1.00-1.37 X#CFLAGS=-O $(INCLUDES) -finline-functions -fstrength-reduce X X# gcc 1.37-1.40 X#CFLAGS=-O $(INCLUDES) -fcombine-regs -finline-functions -fstrength-reduce X# add -msoft-float for 68881 machines. X X# gcc 2.0 X# On the sparc, don't use -O2; it breaks setjmp() and vfork() X#CFLAGS=-O $(INCLUDES) X X# gcc-2.1 X#CFLAGS=-O2 $(INCLUDES) X X# gcc 2.1 on linux X#CFLAGS=-O6 -fomit-frame-pointer $(INCLUDES) X X#hpux 8.0 X#CFLAGS= $(INCLUDES) +O3 -Aa X X# Ultrix 4.2a X#CFLAGS= $(INCLUDES) -O -Olimit 2000 X X# Intel Paragon OSF/1 with PGI compilers XCFLAGS=-O -Mnodebug -Mnoperfmon $(INCLUDES) X X# for silicon graphics (and other mips compilers) -- use the X# global optimizer! (-O3). X# On SGI 4.0+ you need to add -D__STDC__ too. X#CFLAGS= -O3 $(INCLUDES) X#CF=-j X#SUF=u X#.SUFFIXES: .u ## Ultrix needs that X X# mips systems X# CFLAGS= $(INCLUDES) -O -systype bsd43 -Wf,-XNd5000 -Wf,-XNp6000 -Olimit 2000 X X# for at&t machines X#CFLAGS= -O -Ksd $(INCLUDES) X X# Stardent Titan X#CFLAGS = $(INCLUDES) -O -43 X X# Stardent Stellar or sunos4 w/o gcc X#CFLAGS = $(INCLUDES) -O4 X X# Dnix 5.3 X#CFLAGS = -O -X7 X X# Apollo's with cc [apollo builtins don't work with gcc] X# and apollo should not define __STDC__ if it does not have X# the standard header files. RT's (aos4.3) need that too; X# you might want to skip the -O on the rt's... Not very wise. X# AIX/ESA needs -D_IBMESA on command line (this may disappear by GA) X#DFLAGS=-U__STDC__ X#DFLAGS=-D_IBMESA X# On aix2.2.1 we need more compiler space. X#DFLAGS=-Nd4000 -Nn3000 X# AU/X 2.0 needs a flag for POSIX (read the config file) X#DFLAGS=-Zp X# Tektronix 4300 running UTek 4.0 (BSD 4.2) needs: X#DFLAGS = -DUTek X# VMS_POSIX needs: X#DFLAGS=-D_VMS_POSIX X# DEC/osf-1 on the alpha X#DFLAGS=-D_BSD XDFLAGS= X X X################################################################ X## LDLAGS. Define something here if you need to X################################################################ XLDFLAGS= ## The simplest, suitable for all. X#LDFLAGS= -s ## Stripped. Takes less space on disk. X#LDFLAGS= -s -n ## Pure executable. Spares paging over X# ## the network for machines with local X# ## swap but external /usr/local/bin . X#LDFLAGS= -s -n -Bstatic ## Without dynamic links. (SunOS) X#LDFLAGS= -Wl,-s,-n ## Stripped, shared text (Unicos) X X################################################################ X## LIBES. Pick one, or roll your own. X################################################################ X#LIBES= -ltermcap ## BSD style things, hpux X#LIBES= -ltermc ## emx under OS/2 X#LIBES= -ltermcap -lsec ## Tek XD88/10 (UTekV) with PW_SHADOW X#LIBES= -ltermcap -lsec ## Motorola MPC (sysV88) with PW_SHADOW X#LIBES= -ltermcap -lcs ## Mach X#LIBES= -lcurses ## Sys V3 w/o networking (and Sys V4) X#LIBES= -lcurses -lc /usr/ucblib/libucb.a ## Sys V4 with BSDTIMES X#LIBES= -lcurses ## Sys V4 w/o BSDTIMES or Solaris 2 X#LIBES= -lcurses -lnet ## Sys V3 with networking X#LIBES= -lcurses -ldir ## Sys V2 w/o networking [needs directory lib] X#LIBES= -lcurses -ldir -lnet ## Sys V2 with networking [needs directory lib] X#LIBES= -lcurses -lsocket -lbsd ## Amdahl UTS 2.1 X#LIBES= -lcurses -lbsd ## For Irix3.1 on SGI-IRIS4D or ETA10 X#LIBES= -lcurses -lsun -lbsd -lc_s ## For Irix3.3 on SGI-IRIS4D (w/ yp) X#LIBES= -lcurses -lbsd -lc_s ## For Irix3.3 on SGI-IRIS4D (wo/ yp) X#LIBES= -lcurses -lbsd ## For aix on an IBM 370 or rs6000 or ps2 X#LIBES= -lcurses ## For aix on the rt X#LIBES= -lcurses -lcposix ## ISC 2.2 X#LIBES= -lcposix -lc_s -lcurses -linet ## ISC 2.2 with networking X#LIBES= -lcurses -linet -lsec -lc_s ## ISC 2.0.2 with networking X#LIBES= -lcurses -lsec -lc_s ## ISC 2.0.2 without networking X#LIBES= -ltermcap -ldir -lx ## Xenix 386 style things X#LIBES= -lcurses -lintl ## SCO SysVR3.2v2.0 X#LIBES= -lcurses -lintl -lsocket ## SCO+ODT1.1 X#LIBES= -lposix -ltermcap ## A/UX 2.0 X#LIBES= -ltermcap -lbsd ## DEC osf1 on the alpha X#LIBES= -ltermcap -lseq ## Sequent's Dynix X#LIBES= -lcurses -lsocket ## Intel's hypercube and ns32000 based Opus. X#LIBES= -ldirent -lcurses ## att3b1 stk cc w/o shared lib & directory lib X#LIBES= -shlib -ldirent -lcurses ## att3b1 gcc1.40 w/ shared lib & directory lib X#LIBES= ## Minix, VMS_POSIX X#LIBES= -lcurses ## For a stellar X#LIBES= -lcurses -lnsl -lsocket -lc /usr/ucblib/libucb.a ## Stardent Vistra X#LIBES= -ltermcap -lndir -lsocket -ljobs ## masscomp RTU6.0 X#LIBES= -ltermcap -lauth ## for Ultrix with Enhanced Security XLIBES= -ltermcap ## Intel Paragon OSF/1 X X X# The difficult choice of a c-compiler... X# First, you should try your own c-compiler. X# Gcc -traditional is also a safe choice. X# If you think that you have good include files try gcc -Wall... X# If you want to take out -traditional, make sure that your sys/ioctl.h X# is fixed correctly, otherwise you'll be stopped for tty input, or you X# will lose the editor and job control. X X# The -B tells gcc to use /bin/ld. This is to avoid using the gnu ld, which X# on the suns does not know how to make dynamically linked binaries. X#CC= gcc -Wall -B/bin/ X#CC= gcc -m486 -Wall # Generate code for Intel 486 (linux) XCC= cc X#CC= occ X#CC= acc X#CC= c89 # For VMS/POSIX X#CC= /bin/cc # For suns, w/o gcc and SVR4 X#CC= /usr/lib/sun.compile/cc # FPS 500 (+FPX) with Sun C compiler X#CC= scc # Alliant fx2800 XED= ed XAS= as XRM= rm XCXREF= /usr/ucb/cxref XVGRIND= csh /usr/ucb/vgrind XCTAGS= /usr/ucb/ctags X#XSTR= /usr/ucb/xstr XSCCS= /usr/local/sccs XPARALLEL=12 # Make the multi-max run fast. X#P=& # Use Sequent's parallel make XP= XDESTDIR=/usr/local XMANSECT=1 XDESTBIN=${DESTDIR}/bin XDESTMAN=${DESTDIR}/man/man${MANSECT} X# DESTMAN=${DESTDIR}/catman/man${MANSECT} # A/UX X# DESTMAN=${DESTDIR}/usr/share/man/man${MANSECT} # Stardent Vistra (SysVR4) X# DESTMAN=/usr/catman/1l # Amiga unix (SysVR4) XFTPAREA=/usr/spool/ftp X XASSRCS= sh.c sh.dir.c sh.dol.c sh.err.c sh.exec.c sh.char.c \ X sh.exp.c sh.file.c sh.func.c sh.glob.c sh.hist.c sh.init.c \ X sh.lex.c sh.misc.c sh.parse.c sh.print.c sh.proc.c sh.sem.c \ X sh.set.c sh.time.c sh.char.h sh.dir.h sh.proc.h sh.h XPSSRCS= sh.decls.h glob.c glob.h mi.termios.c mi.wait.h mi.varargs.h ma.setp.c \ X vms.termcap.c XSHSRCS= ${ASSRCS} ${PSSRCS} XSHOBJS= sh.${SUF} sh.dir.${SUF} sh.dol.${SUF} sh.err.${SUF} sh.exec.${SUF} \ X sh.char.${SUF} sh.exp.${SUF} sh.func.${SUF} sh.glob.${SUF} \ X sh.hist.${SUF} sh.init.${SUF} sh.lex.${SUF} sh.misc.${SUF} \ X sh.parse.${SUF} sh.print.${SUF} sh.proc.${SUF} sh.sem.${SUF} \ X sh.set.${SUF} sh.time.${SUF} glob.${SUF} mi.termios.${SUF} \ X ma.setp.${SUF} vms.termcap.${SUF} X XTWSRCS= tw.decls.h tw.h tw.help.c tw.init.c tw.parse.c tw.spell.c \ X tw.comp.c XTWOBJS= tw.help.${SUF} tw.init.${SUF} tw.parse.${SUF} tw.spell.${SUF} \ X tw.comp.${SUF} X XEDSRCS= ed.chared.c ed.decls.h ed.defns.c ed.h ed.init.c ed.inputl.c \ X ed.refresh.c ed.screen.c ed.xmap.c ed.term.c ed.term.h XEDOBJS= ed.chared.${SUF} ed.refresh.${SUF} ed.screen.${SUF} ed.init.${SUF} \ X ed.inputl.${SUF} ed.defns.${SUF} ed.xmap.${SUF} ed.term.${SUF} X XTCSRCS= tc.alloc.c tc.bind.c tc.const.c tc.decls.h tc.disc.c \ X tc.func.c tc.os.c tc.os.h tc.printf.c tc.prompt.c \ X tc.sched.c tc.sig.c tc.sig.h tc.str.c sh.types.h tc.vers.c tc.wait.h \ X tc.who.c tc.h XTCOBJS= tc.alloc.${SUF} tc.bind.${SUF} tc.const.${SUF} tc.disc.${SUF} \ X tc.func.${SUF} tc.os.${SUF} tc.printf.${SUF} \ X tc.prompt.${SUF} tc.sched.${SUF} tc.sig.${SUF} tc.str.${SUF} \ X tc.vers.${SUF} tc.who.${SUF} X XPVSRCS= Makefile Makefile.vms XAVSRCS= Fixes MAKEDIFFS MAKESHAR NewThings README FAQ \ X WishList config_f.h eight-bit.me glob.3 patchlevel.h \ X pathnames.h tcsh.man Ported src.desc Imakefile imake.config \ X README.imake complete.tcsh vmsreadme.txt termcap.vms XVHSRCS=${PVSRCS} ${AVSRCS} X XCONFSRCS=config/config.* X XALLSRCS= ${SHSRCS} ${TWSRCS} ${EDSRCS} ${TCSRCS} ${VHSRCS} XDISTSRCS= ${PSSRCS} ${TWSRCS} ${EDSRCS} ${TCSRCS} ${AVSRCS} X X XOBJS= ${SHOBJS} ${TWOBJS} ${EDOBJS} ${TCOBJS} X X Xall: ${BUILD} X Xtcsh:$(P) ${OBJS} X rm -f tcsh core X ${CC} -o tcsh ${LDFLAGS} ${CFLAGS} ${OBJS} ${LIBES} X X# Linux distribution Xjump: tcsh.a X ${CC} ${LDFLAGS} ${CFLAGS} -o tcsh tcsh.a ${LIBES} X Xnojump: tcsh.a X ${CC} ${LDFLAGS} -nojump ${CFLAGS} -o tcsh tcsh.a ${LIBES} X Xstatic: tcsh.a X ${CC} ${LDFLAGS} -static ${CFLAGS} -o tcsh tcsh.a ${LIBES} X Xtcsh.a:$(P) ${OBJS} X $(LD) -x -r -o tcsh.a ${OBJS} X Xtcsh.ps: tcsh.man X rm -f tcsh.ps X -ptroff -man tcsh.man > tcsh.ps X X X.c.${SUF}: X ${CC} ${CF} ${CFLAGS} ${DFLAGS} $< X X# _VMS_POSIX #module addition X#.c.${SUF}: X# @(echo '#module '`echo $< | sed -e 's/\./_/g'`; cat $<) > $*..c X# @echo ${CC} ${CF} ${CFLAGS} ${DFLAGS} $*.c X# @${CC} ${CF} ${CFLAGS} ${DFLAGS} $*..c X# @mv $*..o $*.o X# @rm -f $*..c X X X# Don't do any special massaging of C files for sharing of strings!! X# it causes weird segmentation faults on some systems. X#.c.o: X# ${CC} -E ${CFLAGS} $*.c | ${XSTR} -c - X# ${CC} ${CF} ${CFLAGS} x.c X# mv -f x.o $*.o X# rm -f x.c X X#ed.init.o: ed.init.c X# ${CC} -E ${CFLAGS} $*.c | ${XSTR} -c - X# ${CC} -R ${CF} ${CF} x.c X# mv -f x.o $*.o X# rm -f x.c X X#strings.o: strings X# ${XSTR} X# ${CC} -c -R xs.c X# mv -f xs.o strings.o X# rm -f xs.c X X##.DEFAULT: X## ${SCCS} get $< X X##.DEFAULT: X## co $< X Xed.defns.h: ed.defns.c X @rm -f $@ X @echo '/* Do not edit this file, make creates it. */' > $@ X @echo '#ifndef _h_ed_defns' >> $@ X @echo '#define _h_ed_defns' >> $@ X grep '[FV]_' ed.defns.c | grep '^#define' >> $@ X @echo '#endif /* _h_ed_defns */' >> $@ X Xsh.err.h: sh.err.c X @rm -f $@ X @echo '/* Do not edit this file, make creates it. */' > $@ X @echo '#ifndef _h_sh_err' >> $@ X @echo '#define _h_sh_err' >> $@ X grep 'ERR_' sh.err.c | grep '^#define' >> $@ X @echo '#endif /* _h_sh_err */' >> $@ X Xtc.const.h: tc.const.c sh.char.h config.h config_f.h sh.types.h sh.err.h X @rm -f $@ X @echo '/* Do not edit this file, make creates it. */' > $@ X ${CC} -E $(INCLUDES) ${DFLAGS} tc.const.c | grep 'Char STR' | \ X sed -e 's/Char \([a-zA-Z0-9_]*\)\(.*\)/extern Char \1[];/' | \ X sort >> $@ X Xcsh.prof: ${OBJS} sh.prof.${SUF} mcrt0.${SUF} X rm -f csh.prof X ld -X mcrt0.${SUF} ${OBJS} -o csh.prof ${LIBES} -lc X Xsh.prof.${SUF}: X cp sh.c sh.prof.c X ${CC} ${CF} ${CFLAGS} -DPROF sh.prof.c X Xlint: tc.const.h ed.defns.h X lint ${LFLAGS} sh*.c tw*.c ed*.c tc.*.c ${LIBES} X Xalint: tc.const.h ed.defns.h X alint ${LFLAGS} sh*.c tw*.c ed*.c tc.*.c ${LIBES} X Xprint: X @pr READ_ME X @pr makefile makefile.* X @(size -l a.out; size *.${SUF}) | pr -h SIZES X @${CXREF} sh*.c | pr -h XREF X @ls -l | pr X @pr sh*.h [a-rt-z]*.h sh*.c alloc.c X Xvprint: X @pr -l84 READ_ME TODO X @pr -l84 makefile makefile.* X @(size -l a.out; size *.${SUF}) | pr -l84 -h SIZES X @${CXREF} sh*.c | pr -l84 -h XREF X @ls -l | pr -l84 X @${CXREF} sh*.c | pr -l84 -h XREF X @pr -l84 sh*.h [a-rt-z]*.h sh*.c alloc.c X Xvgrind: X @cp /dev/null index X @for i in *.h; do vgrind -t -h "C Shell" $$i >/crp/bill/csh/$$i.t; done X @for i in *.c; do vgrind -t -h "C Shell" $$i >/crp/bill/csh/$$i.t; done X @vgrind -t -x -h Index index >/crp/bill/csh/index.t X Xinstall: tcsh X -mv -f ${DESTBIN}/tcsh ${DESTBIN}/tcsh.old X cp tcsh ${DESTBIN}/tcsh X -strip ${DESTBIN}/tcsh X chmod 555 ${DESTBIN}/tcsh X Xmanpage: tcsh.man X -rm -f ${DESTMAN}/tcsh.${MANSECT} X cp tcsh.man ${DESTMAN}/tcsh.${MANSECT} X chmod 444 ${DESTMAN}/tcsh.${MANSECT} X X# Amiga Unix X#manpage: tcsh.man X# compress tcsh.man X# cp tcsh.man.Z ${DESTMAN}/tcsh.Z X# chmod 444 ${DESTMAN}/tcsh.Z X X# Apple A/UX X#manpage: tcsh.man X# -rm -f ${DESTMAN}/tcsh.${MANSECT}.Z X# nroff -man tcsh.man | compress > ${DESTMAN}/tcsh.${MANSECT}.Z X# chmod 444 ${DESTMAN}/tcsh.${MANSECT}.Z X Xclean: X ${RM} -f a.out strings x.c xs.c tcsh tcsh.a _MAKE_LOG core X ${RM} -f *.${SUF} sh.prof.c ed.defns.h tc.const.h sh.err.h X Xveryclean: clean X ${RM} -f *~ #* X Xtags: /tmp X ${CTAGS} sh*.c X Xtar: X rm -f tcsh-${VERSION}.tar.Z X rm -rf tcsh-${VERSION} X mkdir tcsh-${VERSION} tcsh-${VERSION}/config X cp ${ALLSRCS} tcsh-${VERSION} X cp ${CONFSRCS} tcsh-${VERSION}/config X tar cvf - tcsh-${VERSION} | compress > tcsh-${VERSION}.tar.Z X rm -rf tcsh-${VERSION} X Xshar: X rm -f tcsh-*.shar X rm -rf tcsh-${VERSION} X mkdir tcsh-${VERSION} tcsh-${VERSION}/config X cp ${ALLSRCS} tcsh-${VERSION} X cp ${CONFSRCS} tcsh-${VERSION}/config X MAKESHAR -v -n tcsh-${VERSION} tcsh-${VERSION} \ X tcsh-${VERSION}/* tcsh-${VERSION}/config/* X rm -rf tcsh-${VERSION} X Xtcsh-${VERSION}.tar.Z: X rm -rf tcsh-${VERSION} X rm -f tcsh-${VERSION}.tar tcsh-${VERSION}.tar.Z DIFFS.[123] X mkdir tcsh-${VERSION} X ./MAKEDIFFS bsd X mv DIFFS.1 DIFFS.2 DIFFS.3 tcsh-${VERSION} X cp ${DISTSRCS} tcsh-${VERSION} X mkdir tcsh-${VERSION}/config X cp ${CONFSRCS} tcsh-${VERSION}/config X cp Makefile tcsh-${VERSION}/Makefile.new X tar cvf - tcsh-${VERSION} | compress > tcsh-${VERSION}.tar.Z X rm -rf tcsh-${VERSION} X Xtcsh.tahoe-${VERSION}.tar.Z: X rm -rf tcsh.tahoe-${VERSION} X rm -f tcsh.tahoe-${VERSION}.tar tcsh.tahoe-${VERSION}.tar.Z DIFFS.[123] X mkdir tcsh.tahoe-${VERSION} X ./MAKEDIFFS tahoe X mv DIFFS.1 DIFFS.2 DIFFS.3 tcsh.tahoe-${VERSION} X cp ${DISTSRCS} tcsh.tahoe-${VERSION} X mkdir tcsh.tahoe-${VERSION}/config X cp ${CONFSRCS} tcsh.tahoe-${VERSION}/config X cp Makefile tcsh.tahoe-${VERSION}/Makefile.new X tar cvf - tcsh.tahoe-${VERSION} | compress > tcsh.tahoe-${VERSION}.tar.Z X rm -rf tcsh.tahoe-${VERSION} X Xtcsh.reno-${VERSION}.tar.Z: X rm -rf tcsh.reno-${VERSION} X rm -f tcsh.reno-${VERSION}.tar tcsh.reno-${VERSION}.tar.Z DIFFS.[123] X mkdir tcsh.reno-${VERSION} X ./MAKEDIFFS reno X mv DIFFS.1 DIFFS.2 DIFFS.3 tcsh.reno-${VERSION} X cp ${DISTSRCS} tcsh.reno-${VERSION} X mkdir tcsh.reno-${VERSION}/config X cp ${CONFSRCS} tcsh.reno-${VERSION}/config X cp Makefile tcsh.reno-${VERSION}/Makefile.new X tar cvf - tcsh.reno-${VERSION} | compress > tcsh.reno-${VERSION}.tar.Z X rm -rf tcsh.reno-${VERSION} X Xftp: tcsh-${VERSION}.tar.Z tcsh.tahoe-${VERSION}.tar.Z X cp tcsh-${VERSION}.tar.Z tcsh.tahoe-${VERSION}.tar.Z ${FTPAREA} X cp tcsh.man ${FTPAREA} X X# X# Dependencies X# Xconfig.h: config_f.h X XTCH=tc.h tc.const.h tc.decls.h tc.os.h tc.sig.h XSHH=sh.h sh.types.h sh.char.h sh.err.h sh.dir.h sh.proc.h pathnames.h \ X sh.decls.h ${TCH} XTWH=tw.h tw.decls.h XEDH=ed.h ed.decls.h X X# EDH XEDINC=sh.${SUF} sh.func.${SUF} sh.lex.${SUF} sh.print.${SUF} sh.proc.${SUF} \ X sh.set.${SUF} tc.bind.${SUF} tc.os.${SUF} tc.prompt.${SUF} \ X tc.sched.${SUF} tw.parse.${SUF} X${EDOBJS} ${EDINC} : ${EDH} X X# SHH X${OBJS}: config.h ${SHH} X X# TWH XTWINC=ed.chared.${SUF} ed.inputl.${SUF} sh.exec.${SUF} sh.func.${SUF} \ X sh.set.${SUF} tc.func.${SUF} X${TWOBJS} ${TWINC}: ${TWH} X X# glob.h Xglob.${SUF} sh.glob.${SUF}: glob.h X X# ed.defns.h XEDDINC=tc.bind.${SUF} tc.func.${SUF} tc.os.${SUF} X${EDOBJS} ${EDDINC}: ed.defns.h END-of-./Makefile echo x - ./tc.sig.c sed 's/^X//' >./tc.sig.c << 'END-of-./tc.sig.c' X/* $Header: /u/christos/src/tcsh-6.03/RCS/tc.sig.c,v 3.13 1992/10/14 20:19:19 christos Exp $ */ X/* X * tc.sig.c: Signal routine emulations X */ X/*- X * Copyright (c) 1980, 1991 The Regents of the University of California. X * All rights reserved. X * X * Redistribution and use in source and binary forms, with or without X * modification, are permitted provided that the following conditions X * are met: X * 1. Redistributions of source code must retain the above copyright X * notice, this list of conditions and the following disclaimer. X * 2. Redistributions in binary form must reproduce the above copyright X * notice, this list of conditions and the following disclaimer in the X * documentation and/or other materials provided with the distribution. X * 3. All advertising materials mentioning features or use of this software X * must display the following acknowledgement: X * This product includes software developed by the University of X * California, Berkeley and its contributors. X * 4. Neither the name of the University nor the names of its contributors X * may be used to endorse or promote products derived from this software X * without specific prior written permission. X * X * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND X * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE X * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE X * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL X * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS X * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) X * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT X * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY X * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF X * SUCH DAMAGE. X */ X#include "sh.h" X XRCSID("$Id: tc.sig.c,v 3.13 1992/10/14 20:19:19 christos Exp $") X X#include "tc.wait.h" X X#ifndef BSDSIGS X X/* this stack is used to queue signals X * we can handle up to MAX_CHLD outstanding children now; X */ X#define MAX_CHLD 50 Xstatic struct mysigstack { X int s_w; /* wait report */ X int s_errno; /* errno returned; */ X pid_t s_pid; /* pid returned */ X} stk[MAX_CHLD]; Xstatic int stk_ptr = -1; X X X# ifdef UNRELSIGS X/* queue child signals X */ Xstatic sigret_t Xsig_ch_queue() X{ X# ifdef JOBDEBUG X xprintf("queue SIGCHLD\n"); X flush(); X# endif /* JOBDEBUG */ X stk_ptr++; X stk[stk_ptr].s_pid = (pid_t) wait(&stk[stk_ptr].s_w); X stk[stk_ptr].s_errno = errno; X (void) signal(SIGCHLD, sig_ch_queue); X# ifndef SIGVOID X return(0); X# endif /* SIGVOID */ X} X X/* process all awaiting child signals X */ Xstatic sigret_t Xsig_ch_rel() X{ X while (stk_ptr > -1) X pchild(SIGCHLD); X# ifdef JOBDEBUG X xprintf("signal(SIGCHLD, pchild);\n"); X# endif /* JOBDEBUG */ X (void) signal(SIGCHLD, pchild); X# ifndef SIGVOID X return(0); X# endif /* SIGVOID */ X} X X X/* libc.a contains these functions in SYSVREL >= 3. */ Xsigret_t X(*xsigset(a, b)) () X int a; X sigret_t (*b) __P((int)); X{ X return (signal(a, b)); X} X X/* release signal X * release all queued signals and X * set the default signal handler X */ Xvoid Xsigrelse(what) X int what; X{ X if (what == SIGCHLD) X sig_ch_rel(); X X# ifdef COHERENT X (void) signal(what, what == SIGINT ? pintr : SIG_DFL); X# endif /* COHERENT */ X} X X/* hold signal X * only works with child and interrupt X */ Xvoid Xxsighold(what) X int what; X{ X if (what == SIGCHLD) X (void) signal(SIGCHLD, sig_ch_queue); X X# ifdef COHERENT X (void) signal(what, SIG_IGN); X# endif /* COHERENT */ X} X X/* ignore signal X */ Xvoid Xxsigignore(a) X int a; X{ X (void) signal(a, SIG_IGN); X} X X/* atomically release one signal X */ Xvoid Xxsigpause(what) X int what; X{ X /* From: Jim Mattson */ X if (what == SIGCHLD) X pchild(SIGCHLD); X} X X X/* return either awaiting processes or do a wait now X */ Xpid_t Xourwait(w) X int *w; X{ X pid_t pid; X X# ifdef JOBDEBUG X xprintf("our wait %d\n", stk_ptr); X flush(); X# endif /* JOBDEBUG */ X X if (stk_ptr == -1) { X /* stack empty return signal from stack */ X pid = (pid_t) wait(w); X# ifdef JOBDEBUG X xprintf("signal(SIGCHLD, pchild);\n"); X# endif /* JOBDEBUG */ X (void) signal(SIGCHLD, pchild); X return (pid); X } X else { X /* return signal from stack */ X errno = stk[stk_ptr].s_errno; X *w = stk[stk_ptr].s_w; X stk_ptr--; X return (stk[stk_ptr + 1].s_pid); X } X} /* end ourwait */ X X# ifdef COHERENT X# undef signal Xsigret_t X(*xsignal(a, b)) () X int a; X sigret_t (*b) __P((int)); X{ X if (a == SIGCHLD) X return SIG_DFL; X else X return (signal(a, b)); X} X# endif /* COHERENT */ X X# endif /* UNRELSIGS */ X X# ifdef SXA X/* X * SX/A is SYSVREL3 but does not have sys5-sigpause(). X * I've heard that sigpause() is not defined in SYSVREL3. X */ X/* This is not need if you make tcsh by BSD option's cc. */ Xvoid Xsigpause(what) X{ X if (what == SIGCHLD) { X bsd_sigpause(bsd_sigblock((sigmask_t) 0) & ~sigmask(SIGBSDCHLD)); X } X else if (what == 0) { X pause(); X } X else { X xprintf("sigpause(%d)\n", what); X pause(); X } X} X# endif /* SXA */ X X#endif /* !BSDSIGS */ X X#ifdef NEEDsignal X/* turn into bsd signals */ Xsigret_t(* X xsignal(s, a)) () X int s; X sigret_t (*a) __P((int)); X{ X sigvec_t osv, sv; X X (void) mysigvec(s, NULL, &osv); X sv = osv; X sv.sv_handler = a; X#ifdef SIG_STK X sv.sv_onstack = SIG_STK; X#endif /* SIG_STK */ X#ifdef SV_BSDSIG X sv.sv_flags = SV_BSDSIG; X#endif /* SV_BSDSIG */ X X if (mysigvec(s, &sv, NULL) < 0) X return (BADSIG); X return (osv.sv_handler); X} X X#endif /* NEEDsignal */ X X#ifdef POSIXSIGS X/* X * Support for signals. X */ X Xextern int errno; X X/* Set and test a bit. Bits numbered 1 to 32 */ X X#define SETBIT(x, y) x |= sigmask(y) X#define ISSET(x, y) ((x & sigmask(y)) != 0) X X#ifdef DEBUG X# define SHOW_SIGNALS 1 /* to assist in debugging signals */ X#endif /* DEBUG */ X X#ifdef SHOW_SIGNALS Xchar *show_sig_mask(); X#endif /* SHOW_SIGNALS */ X Xint debug_signals = 0; X X/* X * sigsetmask(mask) X * X * Set a new signal mask. Return old mask. X */ X#ifndef __PARAGON__ Xsigmask_t Xsigsetmask(mask) X sigmask_t mask; X{ X sigset_t set, oset; X int m; X register int i; X X sigemptyset(&set); X sigemptyset(&oset); X X for (i = 1; i <= MAXSIG; i++) X if (ISSET(mask, i)) X sigaddset(&set, i); X X if (sigprocmask(SIG_SETMASK, &set, &oset)) X xprintf("sigsetmask(0x%x) - sigprocmask failed, errno %d", X mask, errno); X X m = 0; X for (i = 1; i <= MAXSIG; i++) X if (sigismember(&oset, i)) X SETBIT(m, i); X X return (m); X} X X/* X * sigblock(mask) X * X * Add "mask" set of signals to the present signal mask. X * Return old mask. X */ Xsigmask_t Xsigblock(mask) X sigmask_t mask; X{ X sigset_t set, oset; X int m; X register int i; X X sigemptyset(&set); X sigemptyset(&oset); X X /* Get present set of signals. */ X if (sigprocmask(SIG_SETMASK, NULL, &set)) X xprintf("sigblock(0x%x) - sigprocmask failed, errno %d", X mask, errno); X X /* Add in signals from mask. */ X for (i = 1; i <= MAXSIG; i++) X if (ISSET(mask, i)) X sigaddset(&set, i); X X sigprocmask(SIG_SETMASK, &set, &oset); X X /* Return old mask to user. */ X m = 0; X for (i = 1; i <= MAXSIG; i++) X if (sigismember(&oset, i)) X SETBIT(m, i); X X return (m); X} X#endif /* __PARAGON__ */ X X X/* X * bsd_sigpause(mask) X * X * Set new signal mask and wait for signal; X * Old mask is restored on signal. X */ Xvoid Xbsd_sigpause(mask) X sigmask_t mask; X{ X sigset_t set; X register int i; X X sigemptyset(&set); X X for (i = 1; i <= MAXSIG; i++) X if (ISSET(mask, i)) X sigaddset(&set, i); X sigsuspend(&set); X} X X/* X * bsd_signal(sig, func) X * X * Emulate bsd style signal() X */ Xsigret_t (*bsd_signal(sig, func))() X int sig; X sigret_t (*func)(); X{ X struct sigaction act, oact; X sigset_t set; X sigret_t (*r_func)(); X X if (sig < 0 || sig > MAXSIG) { X xprintf("error: bsd_signal(%d) signal out of range\n", sig); X return((sigret_t(*)()) SIG_IGN); X } X X sigemptyset(&set); X X act.sa_handler = (sigret_t(*)()) func; /* user function */ X act.sa_mask = set; /* signal mask */ X act.sa_flags = 0; /* no special actions */ X X if (sigaction(sig, &act, &oact)) { X xprintf("error: bsd_signal(%d) - sigaction failed, errno %d\n", X sig, errno); X return((sigret_t(*)()) SIG_IGN); X } X X r_func = (sigret_t(*)()) oact.sa_handler; X return(r_func); X} X#endif /* POSIXSIG */ X X X#ifdef SIGSYNCH Xstatic long Synch_Cnt = 0; X Xsigret_t Xsynch_handler(sno) Xint sno; X{ X if (sno != SIGSYNCH) X abort(); X Synch_Cnt++; X} X#endif /* SIGSYNCH */ END-of-./tc.sig.c echo x - ./tc.vers.c sed 's/^X//' >./tc.vers.c << 'END-of-./tc.vers.c' X/* $Header: /u/christos/src/tcsh-6.03/RCS/tc.vers.c,v 3.25 1992/10/14 20:19:19 christos Exp $ */ X/* X * tc.vers.c: Version dependent stuff X */ X/*- X * Copyright (c) 1980, 1991 The Regents of the University of California. X * All rights reserved. X * X * Redistribution and use in source and binary forms, with or without X * modification, are permitted provided that the following conditions X * are met: X * 1. Redistributions of source code must retain the above copyright X * notice, this list of conditions and the following disclaimer. X * 2. Redistributions in binary form must reproduce the above copyright X * notice, this list of conditions and the following disclaimer in the X * documentation and/or other materials provided with the distribution. X * 3. All advertising materials mentioning features or use of this software X * must display the following acknowledgement: X * This product includes software developed by the University of X * California, Berkeley and its contributors. X * 4. Neither the name of the University nor the names of its contributors X * may be used to endorse or promote products derived from this software X * without specific prior written permission. X * X * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND X * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE X * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE X * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE X * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL X * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS X * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) X * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT X * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY X * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF X * SUCH DAMAGE. X */ X#include "sh.h" X XRCSID("$Id: tc.vers.c,v 3.25 1992/10/14 20:19:19 christos Exp $") X X#include "patchlevel.h" X X Xchar * Xgethosttype() X{ X char *hosttype; X X#ifdef HOSTTYPE /* Override any system determined hosttypes */ X hosttype = HOSTTYPE; X#else X X# ifdef __PARAGON__ X# define _havehosttype_ X hosttype="Paragon OSF/1"; X# endif /* __PARAGON__ */ X X# ifdef AMIX /* Amiga UNIX */ X# define _havehosttype_ X hosttype = "amiga"; X# endif /* AMIX */ X X# ifdef _VMS_POSIX X# define _havehosttype_ X hosttype = "VMS-POSIX"; X# endif /* _VMS_POSIX */ X X# if (defined(vax) || defined(__vax)) && !defined(_havehosttype_) X# define _havehosttype_ X hosttype = "vax"; X# endif /* vax || __vax && !_havehosttype_ */ X X# ifdef hp9000 /* hp9000 running MORE/bsd */ X# ifdef hp300 X# define _havehosttype_ X hosttype = "hp300"; X# endif X# ifdef hp800 X# define _havehosttype_ X hosttype = "hp800"; X# endif X# ifndef _havehosttype_ X# define _havehosttype_ X hosttype = "hp9000"; X# endif X# endif /* hp9000 */ X X# if defined(sun) || defined(__sun__) X# if defined(mc68010) || defined(__mc68010__) X# define _havehosttype_ X hosttype = "sun2"; X# endif /* mc68010 */ X# if defined(mc68020) || defined(__mc68010__) X# define _havehosttype_ X hosttype = "sun3"; X# endif /* mc68020 */ X# if defined(sparc) || defined(__sparc__) X# define _havehosttype_ X hosttype = "sun4"; X# endif /* sparc */ X# if defined(i386) || defined(__i386__) X# define _havehosttype_ X hosttype = "sun386i"; X# endif /* i386 */ X# ifndef _havehosttype_ X# define _havehosttype_ X hosttype = "sun"; X# endif X# endif /* sun */ X X# ifdef pyr /* pyramid */ X# define _havehosttype_ X hosttype = "pyramid"; X# endif /* pyr */ X X# ifdef tahoe /* tahoe */ X# define _havehosttype_ X hosttype = "tahoe"; X# endif /* tahoe */ X X# ifdef ibm032 /* from Jak Kirman */ X# define _havehosttype_ X hosttype = "rt"; X# endif /* ibm032 */ X X# ifdef aiws /* not to be confused with the above */ X# define _havehosttype_ X hosttype = "rtpc"; X# endif /* aiws */ X X# ifdef _AIX370 X# define _havehosttype_ X hosttype = "aix370"; X# endif /* _AIX370 */ X X# ifdef _IBMESA X# define _havehosttype_ X hosttype = "aixESA"; X# endif /* _IBMESA */ X X# ifdef _IBMR2 X# define _havehosttype_ X hosttype = "rs6000"; X# endif /* _IBMR2 */ X X# ifdef _AIXPS2 /* AIX on a PS/2 */ X# define _havehosttype_ X hosttype = "ps2"; X# endif /* _AIXPS2 */ X X# ifdef OREO X# define _havehosttype_ X hosttype = "mac2"; X# endif /* OREO */ X X# ifdef hpux X# if defined(__hp9000s700) && !defined(_havehosttype_) X# define _havehosttype_ X hosttype = "hp9000s700"; X# endif /* __hp9000s700 */ X# if (defined(__hp9000s800) || defined(hp9000s800)) && !defined(_havehosttype_) X# define _havehosttype_ X hosttype = "hp9000s800"; /* maybe "spectrum" */ X# endif /* __hp9000s800 || hp9000s800 */ X# if (defined(__hp9000s300) || defined(hp9000s300)) && !defined(_havehosttype_) X# define _havehosttype_ X hosttype = "hp9000s300"; X# endif /* __hp9000s800 || hp9000s300 */ X# if defined(hp9000s500) && !defined(_havehosttype_) X# define _havehosttype_ X hosttype = "hp9000s500"; X# endif /* hp9000s500 */ X# ifndef _havehosttype_ X# define _havehosttype_ X hosttype = "hp"; X# endif /* _havehosttype_ */ X# endif /* hpux */ X X# ifdef apollo X# define _havehosttype_ X hosttype = "apollo"; X# endif X X# ifdef u3b20d X# define _havehosttype_ X hosttype = "att3b20"; X# endif /* u3b20d */ X X# ifdef u3b15 X# define _havehosttype_ X hosttype = "att3b15"; X# endif /* u3b15 */ X X# ifdef u3b5 X# define _havehosttype_ X hosttype = "att3b5"; X# endif /* u3b5 */ X X# ifdef u3b2 X# define _havehosttype_ X hosttype = "att3b2"; X# endif /* u3b2 */ X X#ifdef _MINIX X# define _havehosttype_ X# ifdef i386 X hosttype = "minix386"; X# else /* minix ? amoeba or mac? */ X hosttype = "minix"; X# endif /* i386 */ X#endif /* _MINIX */ X X#if defined(i386) && defined(linux) X# define _havehosttype_ X hosttype = "i386-linux"; X#endif X X#if defined(i386) && defined(__EMX__) X# define _havehosttype_ X hosttype = "i386-emx"; X#endif /* i386 && __EMX__ */ X X# ifdef __386BSD__ X# define _havehosttype_ X hosttype = "386BSD"; X# endif /* __386BSD__ */ X X# if defined(i386) && defined(bsdi) X# define _havehosttype_ X hosttype = "bsd386"; /* BSD/386*/ X# endif /* i386 && bsdi */ X X# ifdef COHERENT X# define _havehosttype_ X# ifdef _I386 X hosttype = "coh386"; X# else X hosttype = "coherent"; X# endif /* _I386 */ X# endif /* COHERENT */ X X# if defined(i386) && SYSVREL > 0 X X# if !defined(_havehosttype_) && (defined(ISC) || defined(ISC202)) X# define _havehosttype_ X hosttype = "isc386"; X# endif /* !_havehosttype_ && (ISC || ISC202) */ X X# if !defined(_havehosttype_) && defined(SCO) X# define _havehosttype_ X hosttype = "sco386"; X# endif /* !_havehosttype_ && SCO */ X X# if !defined(_havehosttype_) && defined(INTEL) X# define _havehosttype_ X hosttype = "intel386"; X# endif /* !_havehosttype_ && INTEL */ X X# ifndef _havehosttype_ X# define _havehosttype_ X hosttype = "i386"; X# endif /* _havehosttype_ */ X X# endif X X#ifdef UNIXPC X# define _havehosttype_ X hosttype = "unixpc"; X#endif /* UNIXPC/att3b1/att7300 */ X X#ifdef alliant X# ifdef mc68000 X# define _havehosttype_ X hosttype = "alliant-fx80"; X# endif /* mc68000 */ X# ifdef i860 X# define _havehosttype_ X hosttype = "alliant-fx2800"; X# endif /* i860 */ X# ifndef _havehosttype_ X# define _havehosttype_ X hosttype = "alliant"; /* for Alliant FX Series */ X# endif /* _havehosttype_ */ X#endif /* alliant */ X X# if defined(i386) && defined(MACH) X# define _havehosttype_ X hosttype = "i386-mach"; X# endif X X# if defined(sequent) || defined(_SEQUENT_) X# define _havehosttype_ X# ifdef i386 X# ifdef sequent X hosttype = "symmetry"; /* Sequent Symmetry Dynix/3 */ X# ifndef LOCALSTR X# define LOCALSTR " (Dynix/3)" X# endif /* LOCALSTR */ X# else X hosttype = "ptx"; /* Sequent Symmetry Dynix/ptx */ X# ifndef LOCALSTR X# define LOCALSTR " (Dynix/ptx)" X# endif /* LOCALSTR */ X# endif X# else X hosttype = "balance"; /* for Sequent Balance Series */ X# ifndef LOCALSTR X# define LOCALSTR " (Dynix/3)" X# endif /* LOCALSTR */ X# endif X# else /* !sequent */ X# ifdef ns32000 X# define _havehosttype_ X# ifdef CMUCS /* hack for Mach (in the true spirit of CMU) */ X hosttype = "multimax"; X# else /* CMUCS */ X hosttype = !access("/Umax.image", F_OK) ? "multimax" : "ns32000"; X# endif /* CMUCS */ X# endif /* ns32000 */ X# endif /* sequent */ X X# ifdef convex X# define _havehosttype_ X /* From: Brian Allison */ X hosttype = "convex"; X# endif /* convex */ X X# ifdef butterfly X# define _havehosttype_ X /* this will work _until_ the bfly with 88000s comes out */ X hosttype = "butterfly"; /* BBN Butterfly 1000 */ X# endif /* butterfly */ X X# ifdef NeXT X# define _havehosttype_ X hosttype = "next"; X# endif /* NeXT */ X X/* From Kazuhiro Honda */ X# ifdef sony_news X# define _havehosttype_ X# ifdef mips /* Sony NEWS based on a r3000 */ X hosttype = "news_mips"; X# else X hosttype = "news"; X# endif X# endif /* sony_news */ X X# if defined(mips) || defined(__mips) X# define _havehosttype_ X# if defined(MIPSEL) || defined(__MIPSEL) X# if defined(ultrix) || defined(__ultrix) X hosttype = "decstation"; X# else X hosttype = "mips"; X# endif /* ultrix || __ultrix */ X# endif /* MIPSEL || __MIPSEL */ X# if defined(MIPSEB) || defined(__MIPSEB) X# if defined(ultrix) || defined(__ultrix) X hosttype = "decmips"; X# else X# ifdef sgi /* sgi iris 4d */ X hosttype = "iris4d"; X# else X# ifdef sony_news X hosttype = "news_mips"; X# else X hosttype = "mips"; X# endif /* sony_news */ X# endif /* sgi */ X# endif /* ultrix || __ultrix */ X# endif /* MIPSEB || __MIPSEB */ X# endif /* mips || __mips */ X X#if defined(__alpha) X# define _havehosttype_ X hosttype = "alpha"; X#endif X X# if defined(m88k) || defined(__m88k__) X# define _havehosttype_ X hosttype = "m88k"; /* Motorola 88100 system */ X# endif X X# ifdef masscomp /* Added, DAS DEC-90. */ X# define _havehosttype_ X hosttype = "masscomp";/* masscomp == concurrent */ X# endif /* masscomp */ X X# ifdef GOULD_NP1 X# define _havehosttype_ X hosttype = "gould_np1"; X# endif /* GOULD_NP1 */ X X# ifdef SXA X# define _havehosttype_ X hosttype = "pfa50"; X# ifdef _BSDX_ X# ifndef LOCALSTR X# define LOCALSTR " (SX/A E60+BSDX)" X# endif /* LOCALSTR */ X# else X# ifndef LOCALSTR X# define LOCALSTR " (SX/A E60)" X# endif /* LOCALSTR */ X# endif X# endif /* PFU/Fujitsu A-xx computer */ X X# ifdef titan X# define _havehosttype_ X /* Ken Laprade */ X hosttype = "titan"; X# endif /* titan */ X X# ifdef stellar X# define _havehosttype_ X hosttype = "stellar"; X# endif /* stellar */ X X# ifdef sgi X/* Iris 4D is in the mips section; these are the 68k machines. */ X# ifdef m68000 X# define _havehosttype_ X /* Vince Del Vecchio */ X hosttype = "iris3d"; X# endif X# endif /* sgi */ X X# ifdef uts X# define _havehosttype_ X hosttype = "amdahl"; X# endif /* uts */ X X# ifdef UTek X# define _havehosttype_ X hosttype = "tek4300"; X# endif /* UTek */ X X# ifdef UTekV X# define _havehosttype_ X hosttype = "tekXD88"; X# endif /* UTekV */ X X# ifdef OPUS X# define _havehosttype_ X hosttype = "opus"; X# endif /* OPUS */ X X# ifdef eta10 X# define _havehosttype_ X /* Bruce Woodcock */ X hosttype = "eta10"; X# endif /* eta10 */ X X# ifdef cray X# define _havehosttype_ X hosttype = "cray"; X# endif /* cray */ X X# ifdef NDIX X# define _havehosttype_ X /* B|rje Josefsson */ X hosttype = "nd500"; X# endif /* NDIX */ X X# if defined(sysV68) X# define _havehosttype_ X hosttype = "sysV68"; X# endif /* sysV68 */ X X# if defined(sysV88) X# define _havehosttype_ X hosttype = "sysV88"; X# endif /* sysV88 */ X X# if defined(i860) && !defined(_havehosttype_) X# define _havehosttype_ X /* Tasos Kotsikonas */ X hosttype = "vistra800"; /* Stardent Vistra */ X# endif /* i860 && !_havehosttype_ */ X X# ifndef _havehosttype_ X# if defined(mc68000) || defined(__mc68000__) || defined(mc68k32) X# define _havehosttype_ X hosttype = "m68k"; /* Motorola 68000 system */ X# endif X# endif X X# ifndef _havehosttype_ X# define _havehosttype_ X /* Default to something reasonable */ X hosttype = "unknown"; X# endif X# undef _havehosttype_ X#endif /* HOSTTYPE */ X return hosttype; X} /* end gethosttype */ X X X/* fix_version(): X * Print a reasonable version string, printing all compile time X * options that might affect the user. X */ Xvoid Xfix_version() X{ X char version[BUFSIZE]; X X#ifdef SHORT_STRINGS X# define SSSTR "8b" X#else X# define SSSTR "7b" X#endif X#ifdef NLS X# define NLSSTR ",nls" X#else X# define NLSSTR "" X#endif X#ifdef LOGINFIRST X# define LFSTR ",lf" X#else X# define LFSTR "" X#endif X#ifdef DOTLAST X# define DLSTR ",dl" X#else X# define DLSTR "" X#endif X#ifdef VIDEFAULT X# define VISTR ",vi" X#else X# define VISTR "" X#endif X#ifdef TESLA X# define DTRSTR ",dtr" X#else X# define DTRSTR "" X#endif X#ifdef KAI X# define BYESTR ",bye" X#else X# define BYESTR "" X#endif X#ifdef AUTOLOGOUT X# define ALSTR ",al" X#else X# define ALSTR "" X#endif X#ifdef KANJI X# define KANSTR ",kan" X#else X# define KANSTR "" X#endif X#ifdef SYSMALLOC X# define SMSTR ",sm" X#else X# define SMSTR "" X#endif X#ifdef HASHBANG X# define HBSTR ",hb" X#else X# define HBSTR "" X#endif X/* if you want your local version to say something */ X#ifndef LOCALSTR X# define LOCALSTR "" X#endif /* LOCALSTR */ X X xsprintf(version, X "tcsh %d.%.2d.%.2d (%s) %s (%s) options %s%s%s%s%s%s%s%s%s%s%s%s", X REV, VERS, PATCHLEVEL, ORIGIN, DATE, gethosttype(), X SSSTR, NLSSTR, LFSTR, DLSTR, VISTR, DTRSTR, X BYESTR, ALSTR, KANSTR, SMSTR, HBSTR, LOCALSTR); X set(STRversion, SAVE(version)); X xsprintf(version, "%d.%.2d.%.2d", REV, VERS, PATCHLEVEL); X set(STRtcsh, SAVE(version)); X} END-of-./tc.vers.c echo x - ./config/config.paragon-osf1 sed 's/^X//' >./config/config.paragon-osf1 << 'END-of-./config/config.paragon-osf1' X/* X * config.h -- configure various defines for tcsh X * X * All source files should #include this FIRST. X * X * Edit this to match your system type. X */ X X/****************** System dependant compilation flags ****************/ X/* X * POSIX This system supports IEEE Std 1003.1-1988 (POSIX). X */ X#define POSIX X X/* X * POSIXJOBS This system supports the optional IEEE Std 1003.1-1988 (POSIX) X * job control facilities. X */ X#define POSIXJOBS X X/* X * POSIXSIGS Use the POSIX signal facilities to emulate BSD signals. X */ X#define POSIXSIGS X X/* X * VFORK This machine has a vfork(). X * It used to be that for job control to work, this define X * was mandatory. This is not the case any more. X * If you think you still need it, but you don't have vfork, X * define this anyway and then do #define vfork fork. X * I do this anyway on a Sun because of yellow pages brain damage, X * [should not be needed under 4.1] X * and on the iris4d cause SGI's fork is sufficiently "virtual" X * that vfork isn't necessary. (Besides, SGI's vfork is weird). X * Note that some machines eg. rs6000 have a vfork, but not X * with the berkeley semantics, so we cannot use it there either. X */ X#undef VFORK X X/* X * BSDJOBS You have BSD-style job control (both process groups and X * a tty that deals correctly X */ X#undef BSDJOBS X X/* X * BSDSIGS You have 4.2-style signals, rather than USG style. X * Note: POSIX systems should not define this unless they X * have sigvec() and friends (ie: 4.3BSD-RENO, HP-UX). X */ X#undef BSDSIGS X X/* X * BSDTIMES You have BSD-style process time stuff (like rusage) X * This may or may not be true. For example, Apple Unix X * (OREO) has BSDJOBS and BSDSIGS but not BSDTIMES. X */ X#define BSDTIMES X X/* X * BSDLIMIT You have BSD-style resource limit stuff (getrlimit/setrlimit) X */ X#define BSDLIMIT X X/* X * BSDNICE Your system uses setpriority() instead of nice, to X * change a processes scheduling priority X */ X#define BSDNICE X X/* X * TERMIO You have struct termio instead of struct sgttyb. X * This is usually the case for SYSV systems, where X * BSD uses sgttyb. POSIX systems should define this X * anyway, even though they use struct termios. X */ X#undef TERMIO X X/* X * SYSVREL Your machine is SYSV based (HPUX, A/UX) X * NOTE: don't do this if you are on a Pyramid -- tcsh is X * built in a BSD universe. X * Set SYSVREL to 1, 2, 3, or 4, depending the version of System V X * you are running. Or set it to 0 if you are not SYSV based X */ X#define SYSVREL 0 X X/* X * YPBUGS Work around Sun YP bugs that cause expansion of ~username X * to send command output to /dev/null X */ X#undef YPBUGS X X/* X * SIGVOID Define this if your signal handlers return void. On older X * systems, signal returns int, but on newer ones, it returns void. X */ X#define SIGVOID X X/* X * HAVEDUP2 Define this if your system supports dup2(). X */ X#define HAVEDUP2 X X/* X * UTHOST Does the utmp file have a host field? X */ X#define UTHOST X X/* X * DIRENT Your system has instead of X */ X#define DIRENT X/****************** local defines *********************/ X X#define MACH X X#undef PW_AUTH /* Define this if you are running the security gunk */ X X/****************** configurable hacks ****************/ X/* have been moved to config_f.h */ X#include "config_f.h" END-of-./config/config.paragon-osf1 exit