rx-elf FAIL: SHF_GNU_RETAIN sections 27

Alan Modra amodra@gmail.com
Mon Dec 14 03:33:43 GMT 2020


rx-elf is an odd target with non-standard names for default text, data
and bss sections.  This patch tweaks a new test to make it pass.

	* testsuite/gas/elf/section27.s: Reorder .text, .data and .bss
	so that output section order does not depend on those sections
	being already created.  Use ".section .text" rather than ".text".

diff --git a/gas/testsuite/gas/elf/section27.s b/gas/testsuite/gas/elf/section27.s
index 78e410ff95..5e74bde292 100644
--- a/gas/testsuite/gas/elf/section27.s
+++ b/gas/testsuite/gas/elf/section27.s
@@ -1,8 +1,8 @@
-	.section	.bss,"aw"
-	.global	discard0
-	.type	discard0, %object
-discard0:
-	.zero	2
+	.section	.text,"ax"
+	.global	discard2
+	.type	discard2, %function
+discard2:
+	.word	0
 
 	.section	.data,"aw"
 	.global	discard1
@@ -10,11 +10,11 @@ discard0:
 discard1:
 	.word	1
 
-	.text
-	.global	discard2
-	.type	discard2, %function
-discard2:
-	.word	0
+	.section	.bss,"aw"
+	.global	discard0
+	.type	discard0, %object
+discard0:
+	.zero	2
 
 	.section	.bss,"awR",%nobits
 	.global	retain0

-- 
Alan Modra
Australia Development Lab, IBM


More information about the Binutils mailing list