Expand PMF_FN_* macros.
[netbsd-mini2440.git] / sys / arch / sgimips / stand / Makefile.booters
blob391c6b4efb8aca5842fca7424699337913b0c908
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}/../../../..
8 BINMODE?=       444
10 # XXX SHOULD NOT NEED TO DEFINE THESE!
11 LIBCRT0=
12 LIBC=
13 LIBCRTBEGIN=
14 LIBCRTEND=
16 realall: ${PROG}
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"
24 CPUFLAGS+=      -mabi=n32
25 LDFLAGS+=       -mabi=n32
26 .endif
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}"'
34 CPPFLAGS+=      -Dsgimips
36 # PROG set by parent.
37 NOMAN=          # defined
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
47 # and CLEANFILES
48 .if exists(version)
49 .PHONY: vers.c
50 vers.c: ${.CURDIR}/version
51         ${HOST_SH} ${S}/conf/newvers_stand.sh ${.CURDIR}/version "sgimips"
53 SRCS+=  vers.c
54 CLEANFILES+= vers.c
55 .endif
57 ### find out what to use for libkern
58 KERN_AS=        library
59 .include "${S}/lib/libkern/Makefile.inc"
60 LIBKERN=        ${KERNLIB}
62 ### find out what to use for libz
63 Z_AS=           library
64 .include "${S}/lib/libz/Makefile.inc"
65 LIBZ=           ${ZLIB}
67 ### find out what to use for libsa
68 SA_AS=          library
69 SAMISCMAKEFLAGS+=SA_USE_LOADFILE=yes SA_USE_CREAD=yes
70 # for now:
71 SAMISCMAKEFLAGS+=SA_INCLUDE_NET=no
72 .include "${S}/lib/libsa/Makefile.inc"
73 LIBSA=          ${SALIB}
76 LIBS=           ${LIBSA} ${LIBZ} ${LIBSA} ${LIBKERN}
78 .include <bsd.klinks.mk>
79 .include <bsd.prog.mk>