VirtualBox

source: kBuild/trunk/src/ash/Makefile@ 1158

Last change on this file since 1158 was 626, checked in by bird, 18 years ago

Current libc code (based on NetBSD sh 2005-07-03).

  • Property svn:eol-style set to native
File size: 1.7 KB
Line 
1# $NetBSD: Makefile,v 1.80 2005/06/26 19:10:49 christos Exp $
2# @(#)Makefile 8.4 (Berkeley) 5/5/95
3
4.include <bsd.own.mk>
5
6YHEADER=1
7PROG= sh
8SHSRCS= alias.c cd.c echo.c error.c eval.c exec.c expand.c \
9 histedit.c input.c jobs.c mail.c main.c memalloc.c miscbltin.c \
10 mystring.c options.c parser.c redir.c show.c trap.c output.c var.c \
11 test.c kill.c syntax.c
12GENSRCS=arith.c arith_lex.c builtins.c init.c nodes.c
13GENHDRS=arith.h builtins.h nodes.h token.h
14SRCS= ${SHSRCS} ${GENSRCS}
15
16DPSRCS+=${GENHDRS}
17
18LDADD+= -ll -ledit -ltermcap
19DPADD+= ${LIBL} ${LIBEDIT} ${LIBTERMCAP}
20
21LFLAGS= -8 # 8-bit lex scanner for arithmetic
22YFLAGS= -d
23
24# The .depend file can get references to these temporary files
25.OPTIONAL: lex.yy.c y.tab.c
26
27.ifdef CRUNCHEDPROG
28LFLAGS+=-L
29YFLAGS+=-l
30.endif
31
32CPPFLAGS+=-DSHELL -I. -I${.CURDIR}
33#XXX: For testing only.
34#CPPFLAGS+=-DDEBUG=1
35#CFLAGS+=-funsigned-char
36#TARGET_CHARFLAG?= -DTARGET_CHAR="unsigned char" -funsigned-char
37
38.ifdef SMALLPROG
39CPPFLAGS+=-DSMALL
40.else
41SRCS+=printf.c
42.endif
43
44.PATH: ${.CURDIR}/bltin ${NETBSDSRCDIR}/bin/test \
45 ${NETBSDSRCDIR}/usr.bin/printf \
46 ${NETBSDSRCDIR}/bin/kill
47
48CLEANFILES+= ${GENSRCS} ${GENHDRS} y.tab.h
49CLEANFILES+= trace
50
51token.h: mktokens
52 ${_MKTARGET_CREATE}
53 ${HOST_SH} ${.ALLSRC}
54
55builtins.h: builtins.c
56 ${_MKTARGET_CREATE}
57
58builtins.c: mkbuiltins shell.h builtins.def
59 ${_MKTARGET_CREATE}
60 ${HOST_SH} ${.ALLSRC} ${.OBJDIR}
61 [ -f builtins.h ]
62
63init.c: mkinit.sh ${SHSRCS}
64 ${_MKTARGET_CREATE}
65 ${HOST_SH} ${.ALLSRC}
66
67nodes.h: nodes.c
68
69nodes.c: mknodes.sh nodetypes nodes.c.pat
70 ${_MKTARGET_CREATE}
71 ${HOST_SH} ${.ALLSRC} ${.OBJDIR}
72 [ -f nodes.h ]
73
74.if ${USETOOLS} == "yes"
75COMPATOBJDIR!= cd ${NETBSDSRCDIR}/tools/compat && ${PRINTOBJDIR}
76NBCOMPATLIB= -L${COMPATOBJDIR} -lnbcompat
77.endif
78
79.include <bsd.prog.mk>
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette