Module Name: src
Committed By: matt
Date: Thu Aug 20 07:32:11 UTC 2009
Modified Files:
src/sys/arch/mips/conf [matt-nb5-mips64]: Makefile.mips
Log Message:
Add support for building N64 kernels. This is done by adding
makeoptions LP64="yes"
to your config file.
To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.50.24.1 src/sys/arch/mips/conf/Makefile.mips
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/mips/conf/Makefile.mips
diff -u src/sys/arch/mips/conf/Makefile.mips:1.50 src/sys/arch/mips/conf/Makefile.mips:1.50.24.1
--- src/sys/arch/mips/conf/Makefile.mips:1.50 Mon Feb 18 15:21:04 2008
+++ src/sys/arch/mips/conf/Makefile.mips Thu Aug 20 07:32:11 2009
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.mips,v 1.50 2008/02/18 15:21:04 tsutsui Exp $
+# $NetBSD: Makefile.mips,v 1.50.24.1 2009/08/20 07:32:11 matt Exp $
# Makefile for NetBSD
#
@@ -47,9 +47,20 @@
DEFGP?= -G 0
GP?= ${DEFGP}
CFLAGS+= ${GP} -mno-abicalls -msoft-float -ffixed-23
+.if defined(LP64) && ${LP64} == "yes"
.if ${MACHINE_ARCH} == "mips64eb" || ${MACHINE_ARCH} == "mips64el"
-CFLAGS+= -msym32
+CFLAGS+= -msym32 -mabi=64
+AFLAGS+= -msym32 -mabi=64
.endif
+.if ${MACHINE_ARCH} == "mips64eb"
+LDFLAGS+= -m elf64btsmip
+LINKFLAGS+= -m elf64btsmip
+.endif
+.if ${MACHINE_ARCH} == "mips64el"
+LDFLAGS+= -m elf64ltsmip
+LINKFLAGS+= -m elf64ltsmip
+.endif
+.endif # LP64=yes
AFLAGS+= -mno-abicalls -x assembler-with-cpp -traditional-cpp ${AOPTS}
##