aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorJuli Mallett <jmallett@FreeBSD.org>2010-06-02 21:15:00 +0000
committerJuli Mallett <jmallett@FreeBSD.org>2010-06-02 21:15:00 +0000
commit8da70fdc4275593fe998d542f5d00e883525818b (patch)
treeb1c171831795265f835bce3c9b453dd236835e71 /gnu
parent580eefdf4f4157461da417f93d8b6a1cc9052b1d (diff)
Notes
Diffstat (limited to 'gnu')
-rw-r--r--gnu/usr.bin/cc/Makefile.inc8
1 files changed, 8 insertions, 0 deletions
diff --git a/gnu/usr.bin/cc/Makefile.inc b/gnu/usr.bin/cc/Makefile.inc
index 3f03d2683623..994d97937083 100644
--- a/gnu/usr.bin/cc/Makefile.inc
+++ b/gnu/usr.bin/cc/Makefile.inc
@@ -49,6 +49,14 @@ MIPS_ABI_DEFAULT=ABI_64
MIPS_ABI_DEFAULT?=ABI_32
CFLAGS += -DMIPS_ABI_DEFAULT=${MIPS_ABI_DEFAULT}
+# If we are compiling for the O32 ABI, we need to default to MIPS-III rather
+# than taking the ISA from the ABI requirements, since FreeBSD is built with
+# a number of MIPS-III features/instructions and that is the minimum ISA we
+# support, not the O32 default MIPS-I.
+.if ${MIPS_ABI_DEFAULT} == "ABI_32"
+TARGET_CPUTYPE?=mips3
+.endif
+
# GCC by default takes the ISA from the ABI's requirements. If world is built
# with a superior ISA, since we lack multilib, we have to set the right
# default ISA to be able to link against what's in /usr/lib. Terrible stuff.