Makefile revision 1.9
1#	$NetBSD: Makefile,v 1.9 2009/01/12 06:52:15 tsutsui Exp $
2
3WARNS?= 1
4S= ${.CURDIR}/../../../..
5
6OBJS= romcalls.o
7
8CFLAGS= -Os -ffreestanding -mmemcpy -mno-abicalls -msoft-float -G 0
9CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith
10
11CPPFLAGS+= -D_STANDALONE #-DBOOT_DEBUG
12CPPFLAGS+= -DHAVE_CHANGEDISK_HOOK
13CPPFLAGS+= -DLIBSA_USE_MEMSET -DLIBSA_USE_MEMCPY
14CPPFLAGS+= -I. -I${S}
15CPPFLAGS+= -D__daddr_t=int32_t
16
17AFLAGS= -D_LOCORE -mno-abicalls
18
19### find out what to use for libkern
20.include "${S}/lib/libkern/Makefile.inc"
21
22### find out what to use for libz
23.include "${S}/lib/libz/Makefile.inc"
24
25### find out what to use for libsa
26SAMISCMAKEFLAGS= SA_USE_CREAD=yes SA_USE_LOADFILE=yes
27.include "${S}/lib/libsa/Makefile.inc"
28
29.if !make(obj) && !make(clean) && !make(cleandir)
30.BEGIN:
31	@[ -h machine ] || ln -s ${S}/arch/${MACHINE}/include machine
32	@[ -h mips ] || ln -s ${S}/arch/mips/include mips
33.NOPATH: machine mips
34.endif
35CLEANFILES+= machine mips
36
37realall: ${OBJS} ${KERNLIB} ${ZLIB} ${SALIB}
38#	ln -s ${KERNLIB}
39#	ln -s ${ZLIB}
40#	ln -s ${SALIB}
41
42.include <bsd.prog.mk>
43