329 lines
9.8 KiB
Plaintext
329 lines
9.8 KiB
Plaintext
#ident "@(#)vi:port/makefile.usg 1.48.1.4"
|
|
# Makefile for vi
|
|
|
|
ROOT =
|
|
|
|
DIR = $(ROOT)/usr/bin
|
|
DIRS = $(ROOT)/var/preserve
|
|
|
|
LIBDIR = $(ROOT)/usr/lib
|
|
EX = ex
|
|
|
|
INC = $(ROOT)/usr/include
|
|
|
|
LDFLAGS = -s -lw -lcrypt_i -lgen -lcurses $(PERFLIBS)
|
|
|
|
OPTIONS = -DUSG -DSTDIO -DVMUNIX
|
|
|
|
DEBUGFLAGS = -DTRACE -g
|
|
NONDEBUGFLAGS = -O
|
|
DEB = $(NONDEBUGFLAGS)
|
|
|
|
CFLAGS = $(DEB) -I$(INC) $(OPTIONS) -DTABS=8 -DSINGLE
|
|
|
|
INS = install
|
|
|
|
STRIP = strip
|
|
|
|
SIZE = size
|
|
|
|
FOLD = ../misc/fold
|
|
CTAGS = ../misc/ctags
|
|
CXREF = ../misc/cxref
|
|
|
|
|
|
MAKEFILE = makefile.usg
|
|
|
|
|
|
MAINS = ex expreserve exrecover
|
|
|
|
OBJECTS = bcopy.o ex.o ex_addr.o ex_cmds.o ex_cmds2.o \
|
|
ex_cmdsub.o ex_data.o ex_extern.o ex_get.o \
|
|
ex_io.o ex_put.o ex_re.o ex_set.o ex_subr.o \
|
|
ex_temp.o ex_tty.o ex_unix.o ex_v.o ex_vadj.o \
|
|
ex_vget.o ex_vmain.o ex_voper.o ex_vops.o \
|
|
ex_vops2.o ex_vops3.o ex_vput.o ex_vwind.o \
|
|
printf.o expreserve.o exrecover.o textmem.o
|
|
|
|
SOURCES = bcopy.c ex.c ex_addr.c ex_cmds.c ex_cmds2.c \
|
|
ex_cmdsub.c ex_data.c ex_extern.c ex_get.c \
|
|
ex_io.c ex_put.c ex_re.c ex_set.c ex_subr.c \
|
|
ex_temp.c ex_tty.c ex_unix.c ex_v.c ex_vadj.c \
|
|
ex_vget.c ex_vmain.c ex_voper.c ex_vops.c \
|
|
ex_vops2.c ex_vops3.c ex_vput.c ex_vwind.c \
|
|
printf.c exrecover.c expreserve.c textmem.c
|
|
|
|
MISC = READ_ME makeoptions asfix.c70 ex.news makefile.370 makefile.c70 \
|
|
makefile.70 ovdoprnt.s ovprintf.c rofix
|
|
|
|
ALL: $(MAINS)
|
|
|
|
ex: bcopy.o ex.o ex_addr.o ex_cmds.o ex_cmds2.o \
|
|
ex_cmdsub.o ex_data.o ex_extern.o ex_get.o \
|
|
ex_io.o ex_put.o ex_re.o ex_set.o ex_subr.o \
|
|
ex_temp.o ex_tty.o ex_unix.o ex_v.o ex_vadj.o \
|
|
ex_vget.o ex_vmain.o ex_voper.o ex_vops.o \
|
|
ex_vops2.o ex_vops3.o ex_vput.o ex_vwind.o \
|
|
printf.o textmem.o
|
|
$(CC) $(CFLAGS) -o ex bcopy.o ex.o ex_addr.o ex_cmds.o ex_cmds2.o \
|
|
ex_cmdsub.o ex_data.o ex_extern.o ex_get.o \
|
|
ex_io.o ex_put.o ex_re.o ex_set.o ex_subr.o \
|
|
ex_temp.o ex_tty.o ex_unix.o ex_v.o ex_vadj.o \
|
|
ex_vget.o ex_vmain.o ex_voper.o ex_vops.o \
|
|
ex_vops2.o ex_vops3.o ex_vput.o ex_vwind.o \
|
|
printf.o textmem.o $(LDFLAGS)
|
|
|
|
expreserve: expreserve.o
|
|
$(CC) -s expreserve.o -o expreserve
|
|
|
|
exrecover: exrecover.o ex_extern.o textmem.o
|
|
$(CC) $(CFLAGS) -s -o exrecover exrecover.o ex_extern.o textmem.o $(LDFLAGS)
|
|
|
|
|
|
ex.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h $(INC)/setjmp.h \
|
|
$(INC)/sys/stat.h $(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h $(INC)/pfmt.h $(INC)/fcntl.h ex_tune.h \
|
|
ex_vars.h ex_argv.h ex_temp.h ex_tty.h
|
|
|
|
ex_addr.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_re.h
|
|
|
|
ex_cmds.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_argv.h ex_temp.h ex_tty.h ex_vis.h
|
|
|
|
ex_cmds2.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_argv.h ex_temp.h ex_tty.h ex_vis.h
|
|
|
|
ex_cmdsub.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_argv.h ex_temp.h ex_tty.h ex_vis.h $(INC)/stdio.h
|
|
|
|
ex_data.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h
|
|
|
|
ex_extern.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_argv.h ex_re.h ex_temp.h ex_tty.h ex_vis.h
|
|
|
|
ex_get.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h $(INC)/pfmt.h ex_tune.h \
|
|
ex_vars.h ex_tty.h
|
|
|
|
ex_io.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h ex_vars.h \
|
|
ex_argv.h ex_temp.h ex_tty.h ex_vis.h
|
|
|
|
ex_put.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_re.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_re.h
|
|
|
|
ex_set.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_temp.h ex_tty.h
|
|
|
|
ex_subr.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h $(INC)/pfmt.h ex_tune.h \
|
|
ex_vars.h ex_re.h ex_tty.h ex_vis.h
|
|
|
|
ex_temp.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_temp.h ex_vis.h ex_tty.h
|
|
|
|
ex_tty.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h
|
|
|
|
ex_unix.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_temp.h ex_tty.h ex_vis.h
|
|
|
|
ex_v.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_re.h ex_tty.h ex_vis.h
|
|
|
|
ex_vadj.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vget.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h $(INC)/pfmt.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vmain.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_voper.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vops.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vops2.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vops3.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vput.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
ex_vwind.o: ex.h $(INC)/sys/types.h $(INC)/ctype.h \
|
|
$(INC)/errno.h $(INC)/signal.h \
|
|
$(INC)/setjmp.h $(INC)/sys/stat.h \
|
|
$(INC)/termio.h $(INC)/sys/termio.h \
|
|
$(INC)/term.h ex_tune.h \
|
|
ex_vars.h ex_tty.h ex_vis.h
|
|
|
|
expreserve.o: $(INC)/stdio.h $(INC)/ctype.h \
|
|
$(INC)/sys/types.h $(INC)/sys/stat.h $(INC)/errno.h \
|
|
$(INC)/sys/dir.h $(INC)/pwd.h $(INC)/pfmt.h
|
|
$(CC) $(CFLAGS) -c -O expreserve.c
|
|
|
|
exrecover.o: $(INC)/stdio.h ex.h $(INC)/sys/types.h \
|
|
$(INC)/ctype.h $(INC)/errno.h \
|
|
$(INC)/signal.h $(INC)/setjmp.h \
|
|
$(INC)/sys/stat.h $(INC)/termio.h \
|
|
$(INC)/sys/termio.h $(INC)/term.h $(INC)/pfmt.h \
|
|
ex_tune.h ex_vars.h ex_temp.h ex_tty.h \
|
|
$(INC)/sys/dir.h
|
|
$(CC) $(CFLAGS) -c -O exrecover.c
|
|
|
|
printf.o: $(INC)/varargs.h $(INC)/unistd.h
|
|
|
|
GLOBALINCS = $(INC)/ctype.h $(INC)/errno.h \
|
|
$(INC)/pwd.h $(INC)/setjmp.h $(INC)/signal.h \
|
|
$(INC)/stdio.h $(INC)/sys/dir.h $(INC)/sys/stat.h \
|
|
$(INC)/sys/termio.h $(INC)/sys/types.h \
|
|
$(INC)/term.h $(INC)/termio.h $(INC)/varargs.h
|
|
|
|
LOCALINCS = ex.h ex_argv.h ex_re.h ex_temp.h ex_tty.h ex_tune.h ex_vars.h \
|
|
ex_vis.h
|
|
|
|
clean:
|
|
rm -f $(OBJECTS)
|
|
|
|
clobber:
|
|
rm -f $(OBJECTS) $(MAINS)
|
|
|
|
all : ALL
|
|
|
|
install: ALL $(DIRS)
|
|
$(INS) -f $(DIR) -m 555 -u bin -g bin -o $(EX);
|
|
ln -f $(DIR)/$(EX) $(DIR)/vi
|
|
ln -f $(DIR)/$(EX) $(DIR)/view
|
|
ln -f $(DIR)/$(EX) $(DIR)/edit
|
|
ln -f $(DIR)/$(EX) $(DIR)/vedit
|
|
$(INS) -f $(LIBDIR) -m 555 -u bin -g bin exrecover
|
|
$(INS) -f $(LIBDIR) -m 555 -u bin -g bin expreserve
|
|
|
|
$(DIRS):
|
|
mkdir $@
|
|
|
|
size: ALL
|
|
$(SIZE) $(MAINS)
|
|
|
|
strip: ALL
|
|
$(STRIP) $(MAINS)
|
|
|
|
# These targets are useful but optional
|
|
|
|
partslist:
|
|
@echo $(MAKEFILE) $(SOURCES) $(LOCALINCS) | tr ' ' '\012' | sort
|
|
|
|
productdir:
|
|
@echo $(DIR) | tr ' ' '\012' | sort
|
|
|
|
product:
|
|
@echo $(MAINS) | tr ' ' '\012' | \
|
|
sed 's;^;$(DIR)/;'
|
|
|
|
srcaudit:
|
|
@fileaudit $(MAKEFILE) $(LOCALINCS) $(SOURCES) $(MISC) -o $(OBJECTS) $(MAINS)
|