1 1.62 christos # $NetBSD: Makefile,v 1.62 2016/05/09 21:38:27 christos Exp $ 2 1.1 cgd # @(#)Makefile 8.1 (Berkeley) 6/4/93 3 1.1 cgd 4 1.23 lukem USE_SHLIBDIR= yes 5 1.23 lukem 6 1.50 matt WARNS?= 5 7 1.1 cgd LIB= edit 8 1.1 cgd 9 1.41 roy LIBDPLIBS+= terminfo ${.CURDIR}/../libterminfo 10 1.47 tron 11 1.47 tron .include "bsd.own.mk" 12 1.47 tron 13 1.47 tron COPTS+= -Wunused-parameter 14 1.48 joerg CWARNFLAGS.gcc+= -Wconversion 15 1.53 joerg CWARNFLAGS.clang+= -Wno-cast-qual 16 1.32 christos 17 1.62 christos SRCS = chared.c chartype.c common.c el.c eln.c emacs.c filecomplete.c \ 18 1.62 christos hist.c history.c historyn.c keymacro.c map.c \ 19 1.62 christos parse.c prompt.c read.c readline.c refresh.c search.c sig.c \ 20 1.62 christos terminal.c tokenizer.c tokenizern.c tty.c vi.c 21 1.1 cgd 22 1.59 christos MAN= editline.3 editrc.5 editline.7 23 1.5 lukem 24 1.61 wiz MLINKS= \ 25 1.60 christos editline.3 el_deletestr.3 \ 26 1.60 christos editline.3 el_end.3 \ 27 1.60 christos editline.3 el_get.3 \ 28 1.60 christos editline.3 el_getc.3 \ 29 1.60 christos editline.3 el_gets.3 \ 30 1.60 christos editline.3 el_init.3 \ 31 1.60 christos editline.3 el_init_fd.3 \ 32 1.60 christos editline.3 el_insertstr.3 \ 33 1.60 christos editline.3 el_line.3 \ 34 1.60 christos editline.3 el_parse.3 \ 35 1.60 christos editline.3 el_push.3 \ 36 1.60 christos editline.3 el_reset.3 \ 37 1.60 christos editline.3 el_resize.3 \ 38 1.60 christos editline.3 el_set.3 \ 39 1.60 christos editline.3 el_source.3 \ 40 1.60 christos editline.3 history.3 \ 41 1.60 christos editline.3 history_end.3 \ 42 1.60 christos editline.3 history_init.3 \ 43 1.60 christos editline.3 tok_end.3 \ 44 1.60 christos editline.3 tok_init.3 \ 45 1.60 christos editline.3 tok_line.3 \ 46 1.60 christos editline.3 tok_reset.3 \ 47 1.60 christos editline.3 tok_str.3 48 1.60 christos 49 1.60 christos MLINKS+= \ 50 1.60 christos editline.3 el_wdeletestr.3 \ 51 1.60 christos editline.3 el_wget.3 \ 52 1.60 christos editline.3 el_wgetc.3 \ 53 1.60 christos editline.3 el_wgets.3 \ 54 1.60 christos editline.3 el_winsertstr.3 \ 55 1.60 christos editline.3 el_wline.3 \ 56 1.60 christos editline.3 el_wparse.3 \ 57 1.60 christos editline.3 el_wpush.3 \ 58 1.60 christos editline.3 el_wset.3 \ 59 1.60 christos editline.3 history_w.3 \ 60 1.60 christos editline.3 history_wend.3 \ 61 1.60 christos editline.3 history_winit.3 \ 62 1.60 christos editline.3 tok_wend.3 \ 63 1.60 christos editline.3 tok_winit.3 \ 64 1.60 christos editline.3 tok_wline.3 \ 65 1.60 christos editline.3 tok_wreset.3 \ 66 1.60 christos editline.3 tok_wstr.3 67 1.5 lukem 68 1.18 christos LIBEDITDIR?=${.CURDIR} 69 1.18 christos 70 1.20 jdolecek INCS= histedit.h 71 1.7 christos INCSDIR=/usr/include 72 1.7 christos 73 1.58 christos CLEANFILES+=common.h.tmp emacs.h.tmp fcns.h.tmp func.h.tmp 74 1.58 christos CLEANFILES+=help.h.tmp vi.h.tmp tc1.o tc1 .depend 75 1.58 christos 76 1.54 christos CPPFLAGS+=-I. -I${LIBEDITDIR} 77 1.17 simonb CPPFLAGS+=-I. -I${.CURDIR} 78 1.56 christos #CPPFLAGS+=-DDEBUG_TTY -DDEBUG_KEY -DDEBUG_READ -DDEBUG -DDEBUG_REFRESH 79 1.56 christos #CPPFLAGS+=-DDEBUG_PASTE -DDEBUG_EDIT 80 1.1 cgd 81 1.54 christos AHDR=vi.h emacs.h common.h 82 1.18 christos ASRC=${LIBEDITDIR}/vi.c ${LIBEDITDIR}/emacs.c ${LIBEDITDIR}/common.c 83 1.1 cgd 84 1.58 christos DPSRCS+= ${AHDR} fcns.h func.h help.h 85 1.58 christos CLEANFILES+= ${AHDR} fcns.h func.h help.h 86 1.27 lukem 87 1.20 jdolecek SUBDIR= readline 88 1.20 jdolecek 89 1.58 christos .depend: ${AHDR} fcns.h func.h help.h 90 1.58 christos 91 1.31 dsl vi.h: vi.c makelist Makefile 92 1.33 lukem ${_MKTARGET_CREATE} 93 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -h ${LIBEDITDIR}/vi.c \ 94 1.25 christos > ${.TARGET}.tmp && \ 95 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 96 1.1 cgd 97 1.31 dsl emacs.h: emacs.c makelist Makefile 98 1.33 lukem ${_MKTARGET_CREATE} 99 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -h ${LIBEDITDIR}/emacs.c \ 100 1.25 christos > ${.TARGET}.tmp && \ 101 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 102 1.1 cgd 103 1.31 dsl common.h: common.c makelist Makefile 104 1.33 lukem ${_MKTARGET_CREATE} 105 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -h ${LIBEDITDIR}/common.c \ 106 1.25 christos > ${.TARGET}.tmp && \ 107 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 108 1.1 cgd 109 1.31 dsl fcns.h: ${AHDR} makelist Makefile 110 1.33 lukem ${_MKTARGET_CREATE} 111 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -fh ${AHDR} > ${.TARGET}.tmp && \ 112 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 113 1.1 cgd 114 1.58 christos func.h: ${AHDR} makelist Makefile 115 1.33 lukem ${_MKTARGET_CREATE} 116 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -fc ${AHDR} > ${.TARGET}.tmp && \ 117 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 118 1.1 cgd 119 1.31 dsl help.h: ${ASRC} makelist Makefile 120 1.33 lukem ${_MKTARGET_CREATE} 121 1.25 christos ${HOST_SH} ${LIBEDITDIR}/makelist -bh ${ASRC} > ${.TARGET}.tmp && \ 122 1.19 mrg mv ${.TARGET}.tmp ${.TARGET} 123 1.1 cgd 124 1.35 rpaulo tc1.o: ${LIBEDITDIR}/TEST/tc1.c 125 1.42 mrg 126 1.54 christos tc1: libedit.a tc1.o 127 1.33 lukem ${_MKTARGET_LINK} 128 1.41 roy ${CC} ${LDFLAGS} ${.ALLSRC} -o ${.TARGET} libedit.a ${LDADD} -ltermlib 129 1.16 itohy 130 1.27 lukem .include <bsd.lib.mk> 131 1.27 lukem .include <bsd.subdir.mk> 132 1.42 mrg 133 1.42 mrg # XXX 134 1.52 mrg .if defined(HAVE_GCC) 135 1.42 mrg COPTS.editline.c+= -Wno-cast-qual 136 1.42 mrg COPTS.tokenizer.c+= -Wno-cast-qual 137 1.42 mrg COPTS.tokenizern.c+= -Wno-cast-qual 138 1.42 mrg .endif 139