3.1.7 branch.
[minix.git] / kernel / Makefile
blobe624a3ed47dcb9cccfc62a983d740562d89edf69
1 # Makefile for kernel
2 .include <minix.own.mk>
4 PROG= kernel
6 # first-stage, arch-dependent startup code
7 SRCS= mpx.S
8 SRCS+= start.c table.c main.c proc.c \
9 system.c clock.c utility.c debug.c profile.c interrupt.c \
10 watchdog.c
12 DPADD+= ${LIBTIMERS} ${LIBSYS}
13 LDADD+= -ltimers -lsys
15 .if ${COMPILER_TYPE} == "ack"
16 LDFLAGS+= -.o
17 .elif ${COMPILER_TYPE} == "gnu"
18 CPPFLAGS+= -fno-builtin -ffreestanding -fno-stack-protector
19 LDFLAGS+= -T arch/${ARCH}/kernel.lds
20 LDFLAGS+= -nostdlib
21 DPADD+= ${LIBC}
22 LDADD+= -lc
23 .endif
25 CPPFLAGS+= -I${.CURDIR}/arch/${ARCH}/include -I${MINIXSRCDIR}
26 AFLAGS+= -I${.CURDIR}/arch/${ARCH}/include -I${MINIXSRCDIR}
28 INSTALLFLAGS+= -S 0
29 BINDIR= /usr/sbin
30 MAN=
32 .include "system/Makefile.inc"
33 .include "arch/${ARCH}/Makefile.inc"
34 .include <minix.prog.mk>