Home | History | Annotate | Line # | Download | only in libedit
Makefile revision 1.4
      1 #	@(#)Makefile	8.1 (Berkeley) 6/4/93
      2 
      3 LIB=	edit
      4 
      5 OSRCS=	chared.c common.c el.c emacs.c hist.c key.c map.c parse.c \
      6 	prompt.c read.c refresh.c search.c sig.c term.c tty.c vi.c \
      7 	help.c fcns.c
      8 
      9 # For speed and debugging
     10 #SRCS=   ${OSRCS} tokenizer.c history.c
     11 # For protection
     12 SRCS=	editline.c tokenizer.c history.c
     13 
     14 CLEANFILES+=common.h emacs.h fcns.h help.h vi.h help.c fcns.c editline.c
     15 CFLAGS+=-I. -I${.CURDIR} 
     16 CFLAGS+=#-DDEBUG_TTY -DDEBUG_KEY -DDEBUG_READ -DDEBUG -DDEBUG_REFRESH
     17 CFLAGS+=#-DDEBUG_PASTE
     18 
     19 AHDR=vi.h emacs.h common.h 
     20 ASRC=${.CURDIR}/vi.c ${.CURDIR}/emacs.c ${.CURDIR}/common.c
     21 
     22 vi.h: vi.c makelist
     23 	sh ${.CURDIR}/makelist -h ${.CURDIR}/vi.c > ${.TARGET}
     24 
     25 emacs.h: emacs.c makelist
     26 	sh ${.CURDIR}/makelist -h ${.CURDIR}/emacs.c > ${.TARGET}
     27 
     28 common.h: common.c makelist
     29 	sh ${.CURDIR}/makelist -h ${.CURDIR}/common.c > ${.TARGET}
     30 
     31 fcns.h: ${AHDR} makelist
     32 	sh ${.CURDIR}/makelist -fh ${AHDR} > ${.TARGET}
     33 
     34 fcns.c: ${AHDR} fcns.h makelist
     35 	sh ${.CURDIR}/makelist -fc ${AHDR} > ${.TARGET}
     36 
     37 help.c: ${ASRC} makelist 
     38 	sh ${.CURDIR}/makelist -bc ${ASRC} > ${.TARGET}
     39 
     40 help.h: ${ASRC} makelist
     41 	sh ${.CURDIR}/makelist -bh ${ASRC} > ${.TARGET}
     42 
     43 editline.c: ${OSRCS}
     44 	sh ${.CURDIR}/makelist -e ${.ALLSRC:T} > ${.TARGET}
     45 
     46 .depend: vi.h emacs.h common.h fcns.h help.h help.c
     47 all: vi.h emacs.h common.h fcns.h help.h help.c
     48 
     49 
     50 test:	libedit.a test.o 
     51 	${CC} ${CFLAGS} ${.ALLSRC} -o ${.TARGET} libedit.a ${LDADD} -ltermcap
     52 
     53 includes:
     54 	-cd ${.CURDIR}; cmp -s histedit.h ${DESTDIR}/usr/include/histedit.h > \
     55 	    /dev/null 2>&1 || \
     56 	    ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 histedit.h \
     57 	    ${DESTDIR}/usr/include
     58 
     59 .include <bsd.lib.mk>
     60