1 # $NetBSD: Makefile.booters,v 1.16 2009/03/15 15:20:12 tsutsui Exp $
3 .include <bsd.sys.mk> # for HOST_SH
5 # $S must correspond to the top of the 'sys' tree
6 S= ${.CURDIR}/../../../..
10 # XXX SHOULD NOT NEED TO DEFINE THESE!
18 .PATH: ${.CURDIR}/../common
19 AFLAGS+= -D_LOCORE -D_KERNEL -mno-abicalls
20 CPPFLAGS+= -nostdinc -D_STANDALONE -DNO_ABICALLS -I${.OBJDIR} -I${S}
21 # compiler flags for smallest code size
22 CFLAGS= -ffreestanding -Os -Wall -Werror -mno-abicalls -msoft-float -G 1024
23 .if ${MACHINE_ARCH} == "mips64eb"
27 CWARNFLAGS+= -Wall -Werror
28 CWARNFLAGS+= -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
29 CWARNFLAGS+= -Wno-pointer-sign
30 LDBUG= -T $S/arch/mips/conf/stand.ldscript
31 NETBSD_VERS!= ${HOST_SH} ${.CURDIR}/../../../../conf/osrelease.sh
32 CPPFLAGS+= -DNETBSD_VERS='"${NETBSD_VERS}"'
39 # We load the kernel at 420K in from the start of RAM to give the boot
40 # loader plenty of breathing room. Load the boot loader starting at
41 # the second page of RAM.
42 # A warm thank-you to SGI for making load addresses different :)
43 LOAD_ADDRESS?= 0x88002000
44 LOAD_ADDRESS_IP32?= 0x80002000
46 # if there is a 'version' file, add rule for vers.c and add it to SRCS
50 vers.c: ${.CURDIR}/version
51 ${HOST_SH} ${S}/conf/newvers_stand.sh ${.CURDIR}/version "sgimips"
57 ### find out what to use for libkern
59 .include "${S}/lib/libkern/Makefile.inc"
62 ### find out what to use for libz
64 .include "${S}/lib/libz/Makefile.inc"
67 ### find out what to use for libsa
69 SAMISCMAKEFLAGS+=SA_USE_LOADFILE=yes SA_USE_CREAD=yes
71 SAMISCMAKEFLAGS+=SA_INCLUDE_NET=no
72 .include "${S}/lib/libsa/Makefile.inc"
76 LIBS= ${LIBSA} ${LIBZ} ${LIBSA} ${LIBKERN}
78 .include <bsd.klinks.mk>
79 .include <bsd.prog.mk>