|
|
1.1 ! root 1: # ! 2: # Copyright (c) 1980 Regents of the University of California. ! 3: # All rights reserved. The Berkeley software License Agreement ! 4: # specifies the terms and conditions for redistribution. ! 5: # ! 6: # @(#)makefile.u3 1.3 (Berkeley) 5/31/85 ! 7: # ! 8: VERSION=3.7 ! 9: # ! 10: # Ex skeletal makefile for USG Unix 4.0 on a VAX. ! 11: # ! 12: # NB: This makefile doesn't indicate any dependencies on header files. ! 13: # ! 14: # Ex is very large - this version will not fit on PDP-11's without overlay ! 15: # software. Things that can be turned off to save ! 16: # space include LISPCODE (-l flag, showmatch and lisp options), UCVISUAL ! 17: # (visual \ nonsense on upper case only terminals), CHDIR (the undocumented ! 18: # chdir command.) CRYPT includes the code to edit encrypted files (the -x ! 19: # option, like ed.) VMUNIX makes ex considerably larger, raising many limits ! 20: # and improving speed and simplicity of maintenance. It is suitable only ! 21: # for a VAX or other large machine, and then probably only in a paged system. ! 22: # ! 23: # Don't define VFORK unless your system has the VFORK system call, ! 24: # which is like fork but the two processes have only one data space until the ! 25: # child execs. This speeds up ex by saving the memory copy. ! 26: # ! 27: # If your system expands tabs to 4 spaces you should -DTABS=4 below ! 28: # ! 29: BINDIR= /usr/bin ! 30: NBINDIR=/usr/ucb/new ! 31: LIBDIR= /usr/lib ! 32: FOLD= ${BINDIR}/fold ! 33: CTAGS= ctags ! 34: XSTR= /usr/ucb/bin/xstr ! 35: DEBUGFLAGS= -DTRACE -g ! 36: NONDEBUGFLAGS= -O ! 37: DEB= ${NONDEBUGFLAGS} # or ${DEBUGFLAGS} to to debug ! 38: OPTIONS= -DCRYPT -DLISPCODE -DCHDIR -DUCVISUAL -DUSG3TTY -DSTDIO ! 39: CFLAGS= -I/usr/ucb/include -DTABS=8 ${OPTIONS} ${DEB} ! 40: LDFLAGS= -n # or -i or -z ! 41: TERMLIB= -ltermcap ! 42: MKSTR= /usr/ucb/bin/mkstr ! 43: CXREF= cxref ! 44: INCLUDE=/usr/include ! 45: PR= pr ! 46: OBJS= ex.o ex_addr.o ex_cmds.o ex_cmds2.o ex_cmdsub.o \ ! 47: ex_data.o ex_extern.o ex_get.o ex_io.o ex_put.o ex_re.o \ ! 48: ex_set.o ex_subr.o ex_temp.o ex_tty.o ex_unix.o \ ! 49: ex_v.o ex_vadj.o ex_vget.o ex_vmain.o ex_voper.o \ ! 50: ex_vops.o ex_vops2.o ex_vops3.o ex_vput.o ex_vwind.o \ ! 51: printf.o bcopy.o strings.o ! 52: HDRS= ex.h ex_argv.h ex_re.h ex_temp.h ex_tty.h ex_tune.h ex_vars.h ex_vis.h ! 53: SRC1= ex.c ex_addr.c ex_cmds.c ex_cmds2.c ex_cmdsub.c ! 54: SRC2= ex_data.c ex_get.c ex_io.c ex_put.c ex_re.c ! 55: SRC3= ex_set.c ex_subr.c ex_temp.c ex_tty.c ex_unix.c ! 56: SRC4= ex_v.c ex_vadj.c ex_vget.c ex_vmain.c ex_voper.c ! 57: SRC5= ex_vops.c ex_vops2.c ex_vops3.c ex_vput.c ex_vwind.c ! 58: SRC6= printf.c bcopy.c expreserve.c exrecover.c ! 59: MISC= makefile READ_ME rofix ! 60: VGRIND= csh /usr/ucb/vgrind ! 61: VHDR= "Ex Version ${VERSION}" ! 62: ! 63: .c.o: ! 64: # ifdef VMUNIX ! 65: # ${CC} -E ${CFLAGS} $*.c | ${XSTR} -c - ! 66: # else ! 67: ${MKSTR} - ex${VERSION}strings x $*.c ! 68: ${CC} -E ${CFLAGS} x$*.c | ${XSTR} -c - ! 69: rm -f x$*.c ! 70: # endif ! 71: ${CC} ${CFLAGS} -c x.c ! 72: mv x.o $*.o ! 73: ! 74: a.out: ${OBJS} ! 75: ${CC} ${LDFLAGS} ${OBJS} ${TERMLIB} ! 76: ! 77: all:: a.out exrecover expreserve ! 78: ! 79: tags: /tmp ! 80: ${CTAGS} -w ex.[hc] ex_*.[hc] ! 81: ! 82: ${OBJS}: ex_vars.h ! 83: ! 84: # ex_vars.h: ! 85: # csh makeoptions ${CFLAGS} ! 86: ! 87: bcopy.o: bcopy.c ! 88: ${CC} -c ${CFLAGS} bcopy.c ! 89: ! 90: # xstr: hands off! ! 91: strings.o: strings ! 92: ${XSTR} ! 93: ${CC} -c -S xs.c ! 94: ed - <rofix xs.s ! 95: ${AS} -o strings.o xs.s ! 96: rm xs.s ! 97: ! 98: exrecover: exrecover.o ! 99: ${CC} ${CFLAGS} exrecover.o ex_extern.o -o exrecover ! 100: ! 101: exrecover.o: exrecover.c ! 102: ${CC} ${CFLAGS} -c -O exrecover.c ! 103: ! 104: expreserve: expreserve.o ! 105: ${CC} expreserve.o -o expreserve ! 106: ! 107: expreserve.o: ! 108: ${CC} ${CFLAGS} -c -O expreserve.c ! 109: ! 110: clean: ! 111: # If we dont have ex we cant make it so dont rm ex_vars.h ! 112: -rm -f a.out exrecover expreserve strings core errs trace ! 113: -rm -f *.o x*.[cs] ! 114: ! 115: # install a new version for testing in /usr/new ! 116: ninstall: a.out ! 117: -rm -f ${DESTDIR}${NBINDIR}/ex ${DESTDIR}${NBINDIR}/vi ${DESTDIR}${NBINDIR}/view ! 118: cp a.out ${DESTDIR}${NBINDIR}/ex ! 119: # -cp ex${VERSION}strings ${LIBDIR}/ex${VERSION}strings ! 120: ln ${DESTDIR}${NBINDIR}/ex ${DESTDIR}${NBINDIR}/vi ! 121: ln ${DESTDIR}${NBINDIR}/ex ${DESTDIR}${NBINDIR}/view ! 122: chmod 1755 ${DESTDIR}${NBINDIR}/ex ! 123: ! 124: # install in standard place (/usr/ucb) ! 125: install: a.out exrecover expreserve ! 126: -strip a.out ! 127: -rm -f ${DESTDIR}${BINDIR}/ex ! 128: -rm -f ${DESTDIR}${BINDIR}/vi ! 129: -rm -f ${DESTDIR}${BINDIR}/view ! 130: -rm -f ${DESTDIR}${BINDIR}/edit ! 131: cp a.out ${DESTDIR}${BINDIR}/ex ! 132: cp ex${VERSION}strings ${DESTDIR}/${LIBDIR}/ex${VERSION}strings ! 133: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/edit ! 134: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/vi ! 135: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/view ! 136: chmod 1755 ${DESTDIR}${BINDIR}/ex ! 137: cp exrecover ${DESTDIR}${LIBDIR}/ex${VERSION}recover ! 138: cp expreserve ${DESTDIR}${LIBDIR}/ex${VERSION}preserve ! 139: chmod 4755 ${DESTDIR}${LIBDIR}/ex${VERSION}recover ${DESTDIR}${LIBDIR}/ex${VERSION}preserve ! 140: # The following line normally fails. This is OK. ! 141: -mkdir ${DESTDIR}/usr/preserve ! 142: ! 143: # move from /usr/new to /usr/ucb ! 144: newucb: a.out ! 145: -rm -f ${DESTDIR}${BINDIR}/ex ! 146: -rm -f ${DESTDIR}${BINDIR}/vi ! 147: -rm -f ${DESTDIR}${BINDIR}/edit ! 148: -rm -f ${DESTDIR}${BINDIR}/e ! 149: -rm -f ${DESTDIR}/usr/bin/ex ! 150: mv ${DESTDIR}${NBINDIR}/ex ${DESTDIR}${NBINDIR}/ex ! 151: -rm -f ${DESTDIR}${NBINDIR}/vi ! 152: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/edit ! 153: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/e ! 154: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}${BINDIR}/vi ! 155: ln ${DESTDIR}${BINDIR}/ex ${DESTDIR}/usr/bin/ex ! 156: chmod 1755 ${DESTDIR}${BINDIR}/ex ! 157: ! 158: lint: ! 159: lint ${CFLAGS} ex.c ex_?*.c ! 160: lint ${CFLAGS} -u exrecover.c ! 161: lint ${CFLAGS} expreserve.c ! 162: ! 163: print: ! 164: @${PR} READ* BUGS ! 165: @${PR} makefile* ! 166: @${PR} /etc/termcap ! 167: @(size -l a.out ; size *.o) | ${PR} -h sizes ! 168: @${PR} -h errno.h ${INCLUDE}/errno.h ! 169: @${PR} -h setjmp.h ${INCLUDE}/setjmp.h ! 170: @${PR} -h sgtty.h ${INCLUDE}/sgtty.h ! 171: @${PR} -h signal.h ${INCLUDE}/signal.h ! 172: @${PR} -h sys/stat.h ${INCLUDE}/sys/stat.h ! 173: @${PR} -h sys/types.h ${INCLUDE}/sys/types.h ! 174: @ls -ls | ${PR} ! 175: @${CXREF} *.c | ${PR} -h XREF ! 176: @${PR} *.h *.c ! 177: vgrind: ! 178: tee index < /dev/null ! 179: ${VGRIND} -h ${VHDR} ${HDRS} ! 180: ${VGRIND} -h ${VHDR} ${SRC1} ! 181: ${VGRIND} -h ${VHDR} ${SRC2} ! 182: ${VGRIND} -h ${VHDR} ${SRC3} ! 183: ${VGRIND} -h ${VHDR} ${SRC4} ! 184: ${VGRIND} -h ${VHDR} ${SRC5} ! 185: ${VGRIND} -h ${VHDR} ${SRC6} ! 186: ${VGRIND} -n -h ${VHDR} ${MISC} ! 187: ${VGRIND} -i -h ${VHDR} index
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.