Makefile revision 1.48
1# $NetBSD: Makefile,v 1.48 1999/02/05 22:19:47 tron Exp $ 2# @(#)Makefile 8.4 (Berkeley) 5/5/95 3 4YHEADER=1 5PROG= sh 6SHSRCS= alias.c cd.c echo.c error.c eval.c exec.c expand.c \ 7 histedit.c input.c jobs.c mail.c main.c memalloc.c miscbltin.c \ 8 mystring.c options.c parser.c redir.c show.c trap.c output.c var.c 9GENSRCS=arith.c arith.h arith_lex.c builtins.c builtins.h init.c nodes.c \ 10 nodes.h syntax.c syntax.h token.h 11SRCS= ${SHSRCS} ${GENSRCS} 12 13LDADD+= -ll -ledit -ltermcap 14DPADD+= ${LIBL} ${LIBEDIT} ${LIBTERMCAP} 15 16LFLAGS= -8 # 8-bit lex scanner for arithmetic 17YFLAGS= -d 18 19CPPFLAGS+=-DSHELL -I. -I${.CURDIR} 20 21.PATH: ${.CURDIR}/bltin ${.CURDIR}/../../usr.bin/printf 22 23CLEANFILES+= mkinit mknodes mksyntax 24CLEANFILES+= ${GENSRCS} y.tab.h 25 26token.h: mktokens 27 sh ${.ALLSRC} 28 29builtins.c builtins.h: mkbuiltins shell.h builtins.def 30 sh ${.ALLSRC} ${.OBJDIR} 31 32init.c: mkinit ${SHSRCS} 33 ./${.ALLSRC} 34 35nodes.c nodes.h: mknodes nodetypes nodes.c.pat 36 ./${.ALLSRC} 37 38syntax.c syntax.h: mksyntax 39 ./${.ALLSRC} 40 41mkinit: mkinit.c 42 ${HOST_LINK.c} -o mkinit ${.IMPSRC} 43 44mknodes: mknodes.c 45 ${HOST_LINK.c} -o mknodes ${.IMPSRC} 46 47.if (${MACHINE_ARCH} == "powerpc") || \ 48 (${MACHINE_ARCH} == "arm32") 49TARGET_CHARFLAG= -DTARGET_CHAR="u_int8_t" 50.else 51TARGET_CHARFLAG= -DTARGET_CHAR="int8_t" 52.endif 53 54mksyntax: mksyntax.c 55 ${HOST_LINK.c} ${TARGET_CHARFLAG} -o mksyntax ${.IMPSRC} 56 57.include <bsd.prog.mk> 58 59${OBJS}: builtins.h nodes.h syntax.h token.h 60