Module Name:    src
Committed By:   riastradh
Date:           Sat May 13 10:56:55 UTC 2023

Modified Files:
        src/compat/arm/eabi: bsd.eabi.mk
        src/compat/arm/eabihf: bsd.eabihf.mk
        src/share/mk: bsd.own.mk

Log Message:
compat: Disable relro in 32-bit arm compat.

Not supported by binutils:

ld: warning: -z relro ignored

PR toolchain/57405


To generate a diff of this commit:
cvs rdiff -u -r1.6 -r1.7 src/compat/arm/eabi/bsd.eabi.mk
cvs rdiff -u -r1.4 -r1.5 src/compat/arm/eabihf/bsd.eabihf.mk
cvs rdiff -u -r1.1318 -r1.1319 src/share/mk/bsd.own.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/compat/arm/eabi/bsd.eabi.mk
diff -u src/compat/arm/eabi/bsd.eabi.mk:1.6 src/compat/arm/eabi/bsd.eabi.mk:1.7
--- src/compat/arm/eabi/bsd.eabi.mk:1.6	Sat May 13 10:56:08 2023
+++ src/compat/arm/eabi/bsd.eabi.mk	Sat May 13 10:56:54 2023
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.eabi.mk,v 1.6 2023/05/13 10:56:08 riastradh Exp $
+#	$NetBSD: bsd.eabi.mk,v 1.7 2023/05/13 10:56:54 riastradh Exp $
 
 .if !defined(MLIBDIR)
 
@@ -62,6 +62,9 @@ LDADD+=			${EARM_COMPAT_FLAGS}
 LDFLAGS+=		${EARM_COMPAT_FLAGS}
 MKDEPFLAGS+=		${EARM_COMPAT_FLAGS}
 
+# sync with MKRELRO in bsd.own.mk
+NORELRO=		# defined
+
 .include "${.PARSEDIR}/../../Makefile.compat"
 
 .endif

Index: src/compat/arm/eabihf/bsd.eabihf.mk
diff -u src/compat/arm/eabihf/bsd.eabihf.mk:1.4 src/compat/arm/eabihf/bsd.eabihf.mk:1.5
--- src/compat/arm/eabihf/bsd.eabihf.mk:1.4	Sat May 13 10:56:08 2023
+++ src/compat/arm/eabihf/bsd.eabihf.mk	Sat May 13 10:56:55 2023
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.eabihf.mk,v 1.4 2023/05/13 10:56:08 riastradh Exp $
+#	$NetBSD: bsd.eabihf.mk,v 1.5 2023/05/13 10:56:55 riastradh Exp $
 
 .if !defined(MLIBDIR)
 
@@ -62,6 +62,9 @@ LDADD+=			${EARM_COMPAT_FLAGS}
 LDFLAGS+=		${EARM_COMPAT_FLAGS}
 MKDEPFLAGS+=		${EARM_COMPAT_FLAGS}
 
+# sync with MKRELRO in bsd.own.mk
+NORELRO=		# defined
+
 .include "${.PARSEDIR}/../../Makefile.compat"
 
 .endif

Index: src/share/mk/bsd.own.mk
diff -u src/share/mk/bsd.own.mk:1.1318 src/share/mk/bsd.own.mk:1.1319
--- src/share/mk/bsd.own.mk:1.1318	Fri May 12 11:49:47 2023
+++ src/share/mk/bsd.own.mk	Sat May 13 10:56:55 2023
@@ -1,4 +1,4 @@
-#	$NetBSD: bsd.own.mk,v 1.1318 2023/05/12 11:49:47 ryoon Exp $
+#	$NetBSD: bsd.own.mk,v 1.1319 2023/05/13 10:56:55 riastradh Exp $
 
 # This needs to be before bsd.init.mk
 .if defined(BSD_MK_COMPAT_FILE)
@@ -1137,6 +1137,9 @@ MKPIE?=		no
 #
 # RELRO is enabled on i386, amd64, and aarch64 by default
 #
+# sync with NORELRO in compat/*/*/bsd.*.mk for the relro-enabled 64-bit
+# platforms with relro-disabled 32-bit compat
+#
 .if ${MACHINE} == "i386" || \
     ${MACHINE} == "amd64" || \
     ${MACHINE_ARCH:Maarch64*}

Reply via email to