This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Another PA GAS testsuite fix


On Sat, 2001-12-08 at 03:03, Alan Modra wrote:
> On Fri, Dec 07, 2001 at 05:57:25PM -0700, law@redhat.com wrote:
> >   >  	* gas/all/incbin.s: Add spaces before directives.
> > Don't you also have to twiddle the expected output too?
> 
> Yeah.  You caught me making an "obvious" change without testing.
> This file includes itself..
> 
> 

I believe I'm to blame here. It doesn't seem like a good idea at all to
include the source file itself for the test. Really it should test including
a "binary" file different from the .s file itself, also I suspect that if
anybody would run the test on cygwin or similar platform it would fail because
of CRLF issues.

How about this patch, would that work on all platforms (including SOM)?
It adds another file called incbin.dat which unfortunately have to be
added as a binary otherwise various tools would insist on putting
a newline at the end.

2001-12-09  Anders Norlander  <anorland@synergenix.se>

	* gas/all/incbin.dat: New file.
	* gas/all/incbin.s: Use incbin.dat instead of incbin.s.
	* gas/all/incbin.d: Reflect change in incbin.s


-Anders



--- incbin.d.orig	Sat Dec  8 03:11:00 2001
+++ incbin.d	Sun Dec  9 14:24:02 2001
@@ -1,17 +1,13 @@
 #as: -I$srcdir/$subdir
-#objdump: -s -j .data
+#objdump: -s -j .text
 #name: incbin
 
 # Test the incbin pseudo-op
 
 .*: .*
 
-Contents of section .data:
- 0000 202e6461 74610a20 2e696e63 62696e20   .data. .incbin 
- 0010 22696e63 62696e2e 73220a20 2e696e63  "incbin.s". .inc
- 0020 62696e20 22696e63 62696e2e 73222c30  bin "incbin.s",0
- 0030 2c32380a 202e696e 6362696e 2022696e  ,28. .incbin "in
- 0040 6362696e 2e73222c 31352c39 0a202e70  cbin.s",15,9. .p
- 0050 32616c69 676e2034 0a202e64 6174610a  2align 4. .data.
- 0060 202e696e 6362696e 2022696e 6362696e   .incbin "incbin
- 0070 2e73220a 20202269 6e636269 6e2e0000  .s".  "incbin...
+Contents of section .text:
+ 0000 38383838 38383838 0c313232 3333330c  88888888.122333.
+ 0010 534f4d45 4d4f5245 44415441 44415441  SOMEMOREDATADATA
+ 0020 38383838 38383838 0c313232 3333330c  88888888.122333.
+ 0030 534f4d45 4d4f5245 44415441 44415441  SOMEMOREDATADATA
--- incbin.s.orig	Sat Dec  8 01:25:26 2001
+++ incbin.s	Sun Dec  9 14:21:17 2001
@@ -1,5 +1,5 @@
- .data
- .incbin "incbin.s"
- .incbin "incbin.s",0,28
- .incbin "incbin.s",15,9
- .p2align 4
+	.text
+	.incbin "incbin.dat"
+	.incbin "incbin.dat",0,8
+	.incbin "incbin.dat",8,8
+	.incbin "incbin.dat",16,16



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]