Makefile revision 60599
150471Speter# $FreeBSD: head/bin/csh/Makefile 60599 2000-05-15 14:24:32Z bde $ 21556Srgrimes# @(#)Makefile 8.1 (Berkeley) 5/31/93 31556Srgrimes# 41556Srgrimes# C Shell with process control; VM/UNIX VAX Makefile 51556Srgrimes# Bill Joy UC Berkeley; Jim Kulp IIASA, Austria 61556Srgrimes# 71556Srgrimes# To profile, put -DPROF in DEFS and -pg in CFLAGS, and recompile. 81556Srgrimes 959576SobrienTCSHDIR= ${.CURDIR}/../../contrib/tcsh 1059355Sobrien.PATH: ${TCSHDIR} 1159355Sobrien 121556SrgrimesPROG= csh 1359432SacheSUBDIR= nls 1459355SobrienDFLAGS= -D_PATH_TCSHELL='"${DESTDIR}/bin/${PROG}"' 1559576Sobrien.if defined(WANT_KANJI) 1659576SobrienDFLAGS+= -DWANT_KANJI 1759576Sobrien.endif 1859355SobrienCFLAGS+= -I${TCSHDIR} -I${.CURDIR} -I. ${DFLAGS} 1959355SobrienSRCS= sh.c sh.dir.c sh.dol.c sh.err.c sh.exec.c sh.char.c \ 2059355Sobrien sh.exp.c sh.file.c sh.func.c sh.glob.c sh.hist.c sh.init.c \ 2159355Sobrien sh.lex.c sh.misc.c sh.parse.c sh.print.c sh.proc.c sh.sem.c \ 2259355Sobrien sh.set.c sh.time.c sh.h sh.char.h sh.dir.h sh.proc.h 2359355SobrienSRCS+= sh.decls.h glob.c glob.h mi.termios.c mi.wait.h mi.varargs.h 2459355SobrienSRCS+= tw.decls.h tw.h tw.help.c tw.init.c tw.parse.c tw.spell.c \ 2559355Sobrien tw.comp.c tw.color.c 2659355SobrienSRCS+= ed.chared.c ed.decls.h ed.defns.c ed.h ed.init.c ed.inputl.c \ 2759355Sobrien ed.refresh.c ed.screen.c ed.xmap.c ed.term.c ed.term.h 2859355SobrienSRCS+= tc.alloc.c tc.bind.c tc.const.c tc.decls.h tc.disc.c \ 2959355Sobrien tc.func.c tc.os.c tc.os.h tc.printf.c tc.prompt.c \ 3059355Sobrien tc.sched.c tc.sig.c tc.sig.h tc.str.c sh.types.h tc.vers.c tc.wait.h \ 3159355Sobrien tc.who.c tc.h 3259355SobrienSRCS+= tc.defs.c 3360599SbdeGENHDRS= ed.defns.h sh.err.h tc.const.h 3460599SbdeSRCS+= ${GENHDRS} 351556Srgrimes 361864SwollmanMAN1= csh.1 3760029SjkoshyMLINKS= csh.1 tcsh.1 3851090Ssheldonh# MLINKS for Shell built in commands for which there are no userland 3951090Ssheldonh# utilities of the same name are handled with the associated manpage, 4051090Ssheldonh# builtin.1 in share/man/man1/. 4151090Ssheldonh 4260599SbdeDPADD= ${LIBNCURSES} ${LIBCRYPT} 4360599SbdeLDADD= -lncurses -lcrypt 441556Srgrimes 4559393SobrienLINKS= ${BINDIR}/csh ${BINDIR}/tcsh 4659393Sobrien 4760599SbdeCLEANFILES= ${GENHDRS} csh.1 4860599Sbde 4959355Sobriencsh.1: tcsh.man 5059355Sobrien ln -sf ${.ALLSRC} ${.TARGET} 511556Srgrimes 5259355Sobriened.defns.h: ed.defns.c 5327965Ssteve @rm -f ${.TARGET} 5427965Ssteve @echo '/* Do not edit this file, make creates it. */' > ${.TARGET} 5559355Sobrien @echo '#ifndef _h_ed_defns' >> ${.TARGET} 5659355Sobrien @echo '#define _h_ed_defns' >> ${.TARGET} 5759355Sobrien grep '[FV]_' ${TCSHDIR}/ed.defns.c | grep '^#define' >> ${.TARGET} 5859355Sobrien @echo '#endif /* _h_ed_defns */' >> ${.TARGET} 5959355Sobrien 6059355Sobriensh.err.h: sh.err.c 6159355Sobrien @rm -f ${.TARGET} 6259355Sobrien @echo '/* Do not edit this file, make creates it. */' > ${.TARGET} 6359355Sobrien @echo '#ifndef _h_sh_err' >> ${.TARGET} 6459355Sobrien @echo '#define _h_sh_err' >> ${.TARGET} 6527965Ssteve egrep 'ERR_' ${.ALLSRC} | egrep '^#define' >> ${.TARGET} 6659355Sobrien @echo '#endif /* _h_sh_err */' >> ${.TARGET} 671556Srgrimes 6859355Sobrientc.const.h: tc.const.c sh.char.h config.h config_f.h sh.types.h sh.err.h 6927969Ssteve @rm -f ${.TARGET} 7027969Ssteve @echo '/* Do not edit this file, make creates it. */' > ${.TARGET} 7159355Sobrien @echo '#ifndef _h_tc_const' >> ${.TARGET} 7259355Sobrien @echo '#define _h_tc_const' >> ${.TARGET} 7359355Sobrien ${CC} -E ${CFLAGS} ${.ALLSRC} -D_h_tc_const | egrep 'Char STR' | \ 741556Srgrimes sed -e 's/Char \([a-zA-Z0-9_]*\)\(.*\)/extern Char \1[];/' | \ 7527969Ssteve sort >> ${.TARGET} 7659355Sobrien @echo '#endif /* _h_tc_const */' >> ${.TARGET} 771556Srgrimes 781556Srgrimes.include <bsd.prog.mk> 79