| @@ -1,41 +1,41 @@ | | | @@ -1,41 +1,41 @@ |
1 | # $NetBSD: Makefile,v 1.31 2013/11/07 19:52:56 christos Exp $ | | 1 | # $NetBSD: Makefile,v 1.32 2017/04/09 18:46:55 christos Exp $ |
2 | | | 2 | |
3 | # Logically src/sys | | 3 | # Logically src/sys |
4 | .include <bsd.own.mk> | | 4 | .include <bsd.own.mk> |
5 | S!= cd ${.CURDIR}/../../../..; pwd | | 5 | S!= cd ${.CURDIR}/../../../..; pwd |
6 | DIR_SA=${S}/lib/libsa | | 6 | DIR_SA=${S}/lib/libsa |
7 | DIR_KERN=${S}/lib/libkern ${S}/lib/libkern/arch/m68k | | 7 | DIR_KERN=${S}/lib/libkern ${S}/lib/libkern/arch/m68k |
8 | DIR_LIBC=${S}/../common/lib/libc | | 8 | DIR_LIBC=${S}/../common/lib/libc |
9 | | | 9 | |
10 | # DEBUG= -DDEBUG -DNETIF_DEBUG -DNFS_DEBUG -DRPC_DEBUG \ | | 10 | # DEBUG= -DDEBUG -DNETIF_DEBUG -DNFS_DEBUG -DRPC_DEBUG \ |
11 | # -DNET_DEBUG -DRARP_DEBUG -DETHER_DEBUG -DDEBUG_PROM | | 11 | # -DNET_DEBUG -DRARP_DEBUG -DETHER_DEBUG -DDEBUG_PROM |
12 | | | 12 | |
13 | CPUFLAGS= # ignore settings in /etc/mk.conf | | 13 | CPUFLAGS= # ignore settings in /etc/mk.conf |
14 | DEFS= -Dsun3 -D_STANDALONE -D__daddr_t=int32_t | | 14 | DEFS= -Dsun3 -D_STANDALONE -D__daddr_t=int32_t |
15 | INCL= -I. -I${.CURDIR} -I${S}/lib/libsa -I${S} -I${S}/arch | | 15 | INCL= -I. -I${.CURDIR} -I${S}/lib/libsa -I${S} -I${S}/arch |
16 | AFLAGS= -Wa,-mc68020 -Wa,-mc68851 | | 16 | AFLAGS= -Wa,-mc68020 -Wa,-mc68851 |
17 | .if defined(HAVE_GCC) && ${HAVE_GCC} >= 48 | | 17 | .if defined(HAVE_GCC) && ${HAVE_GCC} >= 48 |
18 | # gcc 4.8 convers -mc68000 to -mcpu=68000 and that breaks gas | | 18 | # gcc 4.8 convers -mc68000 to -mcpu=68000 and that breaks gas |
19 | # which works for -march=68010 but breaks for -mcpu=68010 | | 19 | # which works for -march=68010 but breaks for -mcpu=68010 |
20 | CFLAGS= -march=68010 | | 20 | CFLAGS= -march=68010 |
21 | .else | | 21 | .else |
22 | CFLAGS= -mc68000 -Wa,-mc68010 | | 22 | CFLAGS= -mc68000 -Wa,-mc68010 |
23 | .endif | | 23 | .endif |
24 | CFLAGS+= -Wa,-m68851 -msoft-float | | 24 | CFLAGS+= -Wa,-m68851 -msoft-float |
25 | CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith | | 25 | CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith |
26 | COPTS= -Os -fno-defer-pop -ffreestanding -fno-unwind-tables | | 26 | COPTS= -Os -fno-defer-pop -ffreestanding -fno-unwind-tables |
27 | CPPFLAGS= ${DEFS} ${DEBUG} ${INCL} | | 27 | CPPFLAGS= ${DEFS} ${DEBUG} ${INCL} |
28 | CLEANFILES= SRT0.o SRT1.o vers.c | | 28 | CLEANFILES= SRT0.o SRT1.o |
29 | | | 29 | |
30 | SRCS= SRT0.S SRT1.c | | 30 | SRCS= SRT0.S SRT1.c |
31 | OBJS= SRT0.o SRT1.o | | 31 | OBJS= SRT0.o SRT1.o |
32 | | | 32 | |
33 | realall: ${OBJS} | | 33 | realall: ${OBJS} |
34 | | | 34 | |
35 | .include <bsd.prog.mk> | | 35 | .include <bsd.prog.mk> |
36 | | | 36 | |
37 | ### find out what to use for libkern | | 37 | ### find out what to use for libkern |
38 | KERN_AS= library | | 38 | KERN_AS= library |
39 | .include "${S}/lib/libkern/Makefile.inc" | | 39 | .include "${S}/lib/libkern/Makefile.inc" |
40 | LIBKERN= ${KERNLIB} | | 40 | LIBKERN= ${KERNLIB} |
41 | | | 41 | |