Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src 1. All Makefiles that use ARM_APCS_FLAGS add -marm unconditi...
details: https://anonhg.NetBSD.org/src/rev/2c97ea665f6b
branches: trunk
changeset: 464808:2c97ea665f6b
user: christos <christos%NetBSD.org@localhost>
date: Thu Oct 24 18:46:20 2019 +0000
description:
1. All Makefiles that use ARM_APCS_FLAGS add -marm unconditionally and
bsd.own.mk also adds it for gcc only (so we end up with 2 -marm for gcc).
Just add -marm unconditionally in bsd.own.mk in ARM_APCS_FLAGS and remove
it from everywhere else.
2. gcc-8 now warns about thumb internetwork in APCS mode. This does not make
sense because the documentation says that this flag does not make a
difference in apcs mode, but might produce larger code in non-APCS mode.
So we just add it to silence the warnings.
diffstat:
compat/arm/oabi/bsd.oabi.mk | 3 ++-
share/mk/bsd.own.mk | 6 +++---
sys/arch/acorn32/stand/Makefile.buildboot | 3 +--
sys/arch/evbarm/stand/boot2440/Makefile | 3 +--
sys/arch/evbarm/stand/bootimx23/Makefile | 3 +--
sys/arch/evbarm/stand/gzboot/Makefile.gzboot | 3 +--
sys/arch/zaurus/stand/zboot/Makefile | 3 +--
7 files changed, 10 insertions(+), 14 deletions(-)
diffs (122 lines):
diff -r 8e07b1895957 -r 2c97ea665f6b compat/arm/oabi/bsd.oabi.mk
--- a/compat/arm/oabi/bsd.oabi.mk Thu Oct 24 18:34:22 2019 +0000
+++ b/compat/arm/oabi/bsd.oabi.mk Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.oabi.mk,v 1.4 2015/06/24 22:20:24 matt Exp $
+# $NetBSD: bsd.oabi.mk,v 1.5 2019/10/24 18:46:20 christos Exp $
.if !defined(MLIBDIR)
MLIBDIR= oabi
@@ -11,6 +11,7 @@
LDFLAGS+= -Wl,-m,armelf_nbsd
COPTS+= -mcpu=cortex-a53
ARM_APCS_FLAGS= ${${ACTIVE_CC} == "clang":? -target arm--netbsdelf -B ${TOOLDIR}/aarch64--netbsd/bin :} -mabi=apcs-gnu -mfloat-abi=soft
+ARM_APCS_FLAGS+= ${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 8:? -mno-thumb-interwork :}
.elif !empty(MACHINE_ARCH:M*eb)
ARM_MACHINE_ARCH= armeb
ARM_LD= -m armelfb_nbsd
diff -r 8e07b1895957 -r 2c97ea665f6b share/mk/bsd.own.mk
--- a/share/mk/bsd.own.mk Thu Oct 24 18:34:22 2019 +0000
+++ b/share/mk/bsd.own.mk Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: bsd.own.mk,v 1.1157 2019/10/22 13:49:30 christos Exp $
+# $NetBSD: bsd.own.mk,v 1.1158 2019/10/24 18:46:20 christos Exp $
# This needs to be before bsd.init.mk
.if defined(BSD_MK_COMPAT_FILE)
@@ -890,8 +890,8 @@
.if !empty(MACHINE_ARCH:M*arm*)
# Flags to pass to CC for using the old APCS ABI on ARM for compat or stand.
-ARM_APCS_FLAGS= -mabi=apcs-gnu -mfloat-abi=soft
-ARM_APCS_FLAGS+=${${ACTIVE_CC} == "gcc":? -marm :}
+ARM_APCS_FLAGS= -mabi=apcs-gnu -mfloat-abi=soft -marm
+ARM_APCS_FLAGS+= ${${ACTIVE_CC} == "gcc" && ${HAVE_GCC:U0} >= 8:? -mno-thumb-interwork :}
ARM_APCS_FLAGS+=${${ACTIVE_CC} == "clang":? -target ${MACHINE_GNU_ARCH}--netbsdelf -B ${TOOLDIR}/${MACHINE_GNU_PLATFORM}/bin :}
.endif
diff -r 8e07b1895957 -r 2c97ea665f6b sys/arch/acorn32/stand/Makefile.buildboot
--- a/sys/arch/acorn32/stand/Makefile.buildboot Thu Oct 24 18:34:22 2019 +0000
+++ b/sys/arch/acorn32/stand/Makefile.buildboot Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.buildboot,v 1.24 2017/04/09 16:29:46 christos Exp $
+# $NetBSD: Makefile.buildboot,v 1.25 2019/10/24 18:46:20 christos Exp $
S?= ${.CURDIR}/../../../..
@@ -40,7 +40,6 @@
CPPFLAGS+= -I. -I${.CURDIR}/../../.. -I${.CURDIR}/../../../..
CPPFLAGS+= -I${.CURDIR}/../lib
CPPFLAGS+= ${ARM_APCS_FLAGS} -march=armv3m
-CPPFLAGS+= -marm
CPUFLAGS=
CFLAGS= -O2
CFLAGS+= -ffreestanding -fno-unwind-tables
diff -r 8e07b1895957 -r 2c97ea665f6b sys/arch/evbarm/stand/boot2440/Makefile
--- a/sys/arch/evbarm/stand/boot2440/Makefile Thu Oct 24 18:34:22 2019 +0000
+++ b/sys/arch/evbarm/stand/boot2440/Makefile Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2017/04/08 19:53:20 christos Exp $
+# $NetBSD: Makefile,v 1.19 2019/10/24 18:46:20 christos Exp $
S= ${.CURDIR}/../../../..
@@ -16,7 +16,6 @@
CPPFLAGS+= -DDEFAULT_BOOTFILE="ld0a:netbsd;net:"
CPPFLAGS+= -nostdinc -I. -I${.OBJDIR} -I${S} -I${S}/arch
CPPFLAGS+= -march=armv4 ${ARM_APCS_FLAGS}
-CPPFLAGS+= -marm
CPUFLAGS=
DBG= -Os
diff -r 8e07b1895957 -r 2c97ea665f6b sys/arch/evbarm/stand/bootimx23/Makefile
--- a/sys/arch/evbarm/stand/bootimx23/Makefile Thu Oct 24 18:34:22 2019 +0000
+++ b/sys/arch/evbarm/stand/bootimx23/Makefile Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $Id: Makefile,v 1.15 2017/02/22 13:14:45 maya Exp $
+# $Id: Makefile,v 1.16 2019/10/24 18:46:21 christos Exp $
S= ${.CURDIR}/../../../../
PROG= bootimx23
@@ -13,7 +13,6 @@
CPPFLAGS+= -DKERNEL_BOOT_ARGS=\"root=ld0a\"
CPPFLAGS+= -nostdinc -I. -I${.CURDIR} -I${.OBJDIR} -I${S} -I${S}/arch
CPPFLAGS+= ${ARM_APCS_FLAGS}
-CPPFLAGS+= -marm
#CPPFLAGS+= -DDEBUG
#CPPFLAGS+= -DDIAGNOSTIC
DBG= -g
diff -r 8e07b1895957 -r 2c97ea665f6b sys/arch/evbarm/stand/gzboot/Makefile.gzboot
--- a/sys/arch/evbarm/stand/gzboot/Makefile.gzboot Thu Oct 24 18:34:22 2019 +0000
+++ b/sys/arch/evbarm/stand/gzboot/Makefile.gzboot Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.gzboot,v 1.36 2017/04/08 19:53:20 christos Exp $
+# $NetBSD: Makefile.gzboot,v 1.37 2019/10/24 18:46:21 christos Exp $
NOMAN= # defined
@@ -37,7 +37,6 @@
CPPFLAGS+= -I${S} -I${S}/arch -I${S}/lib/libsa
CPPFLAGS+= -I${S}/../common/dist/zlib
CPPFLAGS+= ${ARM_APCS_FLAGS}
-CPPFLAGS+= -marm
CPPFLAGS+= -D_STANDALONE
diff -r 8e07b1895957 -r 2c97ea665f6b sys/arch/zaurus/stand/zboot/Makefile
--- a/sys/arch/zaurus/stand/zboot/Makefile Thu Oct 24 18:34:22 2019 +0000
+++ b/sys/arch/zaurus/stand/zboot/Makefile Thu Oct 24 18:46:20 2019 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.21 2019/09/23 13:42:37 christos Exp $
+# $NetBSD: Makefile,v 1.22 2019/10/24 18:46:21 christos Exp $
PROG= zboot
@@ -22,7 +22,6 @@
CPPFLAGS+= -D_STANDALONE -DHEAP_VARIABLE
CPPFLAGS+= -DLIBSA_ENABLE_LS_OP
CPPFLAGS+= ${ARM_APCS_FLAGS} -mcpu=xscale
-CPPFLAGS+= -marm
CPUFLAGS=
AFLAGS+= -D_LOCORE
LDFLAGS+= -nostdlib -Bstatic
Home |
Main Index |
Thread Index |
Old Index