Makefile revision 142425
150276Speter# @(#)Makefile 8.4 (Berkeley) 5/5/95 250276Speter# $FreeBSD: head/bin/sh/Makefile 127167 2004-03-18 10:55:47Z ru $ 3184989Srafan 450276SpeterPROG= sh 550276SpeterINSTALLFLAGS= -S 650276SpeterSHSRCS= alias.c arith.y arith_lex.l cd.c echo.c error.c eval.c exec.c expand.c \ 750276Speter histedit.c input.c jobs.c mail.c main.c memalloc.c miscbltin.c \ 850276Speter mystring.c options.c output.c parser.c redir.c show.c \ 950276Speter test.c trap.c var.c 1050276SpeterGENSRCS= builtins.c init.c nodes.c syntax.c 1150276SpeterGENHDRS= builtins.h nodes.h syntax.h token.h 1250276SpeterSRCS= ${SHSRCS} ${GENSRCS} ${GENHDRS} y.tab.h 1350276Speter 1450276Speter# MLINKS for Shell built in commands for which there are no userland 1550276Speter# utilities of the same name are handled with the associated manpage, 1650276Speter# builtin.1 in share/man/man1/. 1750276Speter 1850276SpeterDPADD= ${LIBL} ${LIBEDIT} ${LIBTERMCAP} 1950276SpeterLDADD= -ll -ledit -ltermcap 2050276Speter 2150276SpeterLFLAGS= -8 # 8-bit lex scanner for arithmetic 2250276SpeterCFLAGS+=-DSHELL -I. -I${.CURDIR} 2350276Speter# for debug: 2450276Speter# CFLAGS+= -g -DDEBUG=2 2550276SpeterWARNS?= 0 2650276SpeterWFORMAT=0 2750276Speter 2850276Speter.PATH: ${.CURDIR}/bltin \ 2950276Speter ${.CURDIR}/../../bin/test 30184989Srafan 3150276SpeterCLEANFILES+= mkinit mkinit.o mknodes mknodes.o \ 3250276Speter mksyntax mksyntax.o 3350276SpeterCLEANFILES+= ${GENSRCS} ${GENHDRS} 3466963Speter 3550276Speterbuild-tools: mkinit mknodes mksyntax 3650276Speter 3750276Speter.ORDER: builtins.c builtins.h 3850276Speterbuiltins.c builtins.h: mkbuiltins builtins.def 3950276Speter cd ${.CURDIR}; sh mkbuiltins ${.OBJDIR} 4050276Speter 4150276Speterinit.c: mkinit alias.c eval.c exec.c input.c jobs.c options.c parser.c \ 42174993Srafan redir.c trap.c var.c 43174993Srafan ./mkinit ${.ALLSRC:S/^mkinit$//} 44174993Srafan 4550276Speter# XXX this is just to stop the default .c rule being used, so that the 46166124Srafan# intermediate object has a fixed name. 47166124Srafan# XXX we have a default .c rule, but no default .o rule. 48166124Srafan.o: 49174993Srafan ${CC} ${CFLAGS} ${LDFLAGS} ${.IMPSRC} ${LDLIBS} -o ${.TARGET} 50174993Srafanmkinit: mkinit.o 51174993Srafanmknodes: mknodes.o 52174993Srafanmksyntax: mksyntax.o 53174993Srafan 54174993Srafan.ORDER: nodes.c nodes.h 55166124Srafannodes.c nodes.h: mknodes nodetypes nodes.c.pat 56166124Srafan ./mknodes ${.CURDIR}/nodetypes ${.CURDIR}/nodes.c.pat 57166124Srafan 58166124Srafan.ORDER: syntax.c syntax.h 59174993Srafansyntax.c syntax.h: mksyntax 60174993Srafan ./mksyntax 61174993Srafan 62174993Srafantoken.h: mktokens 6350276Speter sh ${.CURDIR}/mktokens 6450276Speter 6550276Speter.include <bsd.prog.mk> 6650276Speter