* GAS 2.11.1 doesn't work for sh-hitachi-coff
@ 2001-06-11 23:54 Schirmer, Hartmut
2001-06-12 3:54 ` Nick Clifton
0 siblings, 1 reply; 7+ messages in thread
From: Schirmer, Hartmut @ 2001-06-11 23:54 UTC (permalink / raw)
To: 'binutils@sources.redhat.com'
Hi,
I can't build a GCC on
bash-2.05$ uname -a
CYGWIN_NT-4.0 SCHIRMER_H 1.3.2(0.39/3/2) 2001-05-20 23:28 i686 unknown
for target sh-hitachi-coff. GAS from 2.11.1pre1 fails:
/home/SchirmerH/gcc-sh/build-gcc/gcc/xgcc
-B/home/SchirmerH/gcc-sh/build-gcc/gcc
/ -B/gcc-3.0-sh/sh-hitachi-coff/bin/ -B/gcc-3.0-sh/sh-hitachi-coff/lib/
-isystem
/gcc-3.0-sh/sh-hitachi-coff/include -O2 -DCROSS_COMPILE -DIN_GCC -W
-Wall -
Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include
-g1
-DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I.
-I../../gcc-20010
611/gcc -I../../gcc-20010611/gcc/. -I../../gcc-20010611/gcc/config
-I../../gcc-2
0010611/gcc/../include -DL_muldi3 -c ../../gcc-20010611/gcc/libgcc2.c -o
libgcc
/./_muldi3.o
/cygdrive/c/TEMP/cc1oUj4A.s: Assembler messages:
/cygdrive/c/TEMP/cc1oUj4A.s:1: Fatal error: dwarf2 is not supported for this
obj
ect file format
2.11.1pre1 build out of the box using
bash-2.05$ gcc -v
Reading specs from /usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-4/specs
gcc version 2.95.3-4 (cygwin special)
Hartmut
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: GAS 2.11.1 doesn't work for sh-hitachi-coff
2001-06-11 23:54 GAS 2.11.1 doesn't work for sh-hitachi-coff Schirmer, Hartmut
@ 2001-06-12 3:54 ` Nick Clifton
0 siblings, 0 replies; 7+ messages in thread
From: Nick Clifton @ 2001-06-12 3:54 UTC (permalink / raw)
To: Schirmer, Hartmut; +Cc: 'binutils@sources.redhat.com'
Hi Hartmut,
> for target sh-hitachi-coff. GAS from 2.11.1pre1 fails:
> /cygdrive/c/TEMP/cc1oUj4A.s:1: Fatal error: dwarf2 is not supported
> for this object file format
This appears to be a gcc configuration problem. The COFF file format
does not support the DWARF2 debug format, so gcc should not be
producing it in the first place.
I would suggest that you investigate why the STABS debug format is not
being used by gcc.
Cheers
Nick
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: GAS 2.11.1 doesn't work for sh-hitachi-coff
@ 2001-06-13 9:21 Schirmer, Hartmut
0 siblings, 0 replies; 7+ messages in thread
From: Schirmer, Hartmut @ 2001-06-13 9:21 UTC (permalink / raw)
To: 'Nick Clifton'; +Cc: 'binutils@sources.redhat.com'
> Why is .file in COFF illegal and why did gas 2.10.1 accept it ?
>
> obj-coff.c has
>
> void
> c_dot_file_symbol (filename)
> char *filename;
> {
> symbolS *symbolP;
>
> symbolP = symbol_new (".file",
> SEG_DEBUG,
> 0,
> &zero_address_frag);
> ...
>
> I'll try and block out the two lines in tc-sh.c
It worked !
Hartmut
*** tc-sh.c.orig Thu Jun 7 03:15:32 2001
--- tc-sh.c Wed Jun 13 16:14:27 2001
***************
*** 97,104 ****
--- 97,106 ----
{"2byte", s_uacons, 2},
{"4byte", s_uacons, 4},
{"8byte", s_uacons, 8},
+ #ifdef BFD_ASSEMBLER
{"file", dwarf2_directive_file, 0 },
{"loc", dwarf2_directive_loc, 0 },
+ #endif
{0, 0, 0}
};
***************
*** 1940,1946 ****
--- 1942,1950 ----
}
}
+ #ifdef BFD_ASSEMBLER
dwarf2_emit_insn (size);
+ #endif
}
/* This routine is called each time a label definition is seen. It
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: GAS 2.11.1 doesn't work for sh-hitachi-coff
@ 2001-06-13 9:14 Schirmer, Hartmut
0 siblings, 0 replies; 7+ messages in thread
From: Schirmer, Hartmut @ 2001-06-13 9:14 UTC (permalink / raw)
To: 'Nick Clifton'; +Cc: 'binutils@sources.redhat.com'
> > dwarf2_directive_file gets called
>
> Oh dear - then gcc really is generating DWARF2 line number
> information. This should only happen if DWARF2_ASM_LINE_DEBUG_INFO is
> defined, and according to the latest CVS sources that is only defined
> in gcc/config/sh/elf.h. I assume that this header is not included in
> your sh-coff configuration (but you could check the Makefile in your
> gcc build directory to make sure), so maybe it is defined in another
> header that you are including. Can you check ?
No time to dig into, sorry. (I'll leave on vacations really soon now ...)
> Just supressing the support for .file and .loc in gas/config/tc-sh.c
> will not work, since they will turn up as unrecognised pseudo ops. We
> really need to find out why they are being generated by gcc for a COFF
> based configuration.
Why is .file in COFF illegal and why did gas 2.10.1 accept it ?
obj-coff.c has
void
c_dot_file_symbol (filename)
char *filename;
{
symbolS *symbolP;
symbolP = symbol_new (".file",
SEG_DEBUG,
0,
&zero_address_frag);
...
I'll try and block out the two lines in tc-sh.c
Hartmut
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: GAS 2.11.1 doesn't work for sh-hitachi-coff
2001-06-13 3:12 Schirmer, Hartmut
@ 2001-06-13 8:47 ` Nick Clifton
0 siblings, 0 replies; 7+ messages in thread
From: Nick Clifton @ 2001-06-13 8:47 UTC (permalink / raw)
To: Schirmer, Hartmut; +Cc: 'binutils@sources.redhat.com'
Hi Hartmut,
> this didn't help.
Darn :-(
> I noticed two additional dwarf2 calls in tc-sh.c
>
> const pseudo_typeS md_pseudo_table[] =
> {
> ...
> {"file", dwarf2_directive_file, 0 },
> {"loc", dwarf2_directive_loc, 0 },
>
> dwarf2_directive_file gets called
Oh dear - then gcc really is generating DWARF2 line number
information. This should only happen if DWARF2_ASM_LINE_DEBUG_INFO is
defined, and according to the latest CVS sources that is only defined
in gcc/config/sh/elf.h. I assume that this header is not included in
your sh-coff configuration (but you could check the Makefile in your
gcc build directory to make sure), so maybe it is defined in another
header that you are including. Can you check ?
Just supressing the support for .file and .loc in gas/config/tc-sh.c
will not work, since they will turn up as unrecognised pseudo ops. We
really need to find out why they are being generated by gcc for a COFF
based configuration.
Cheers
Nick
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: GAS 2.11.1 doesn't work for sh-hitachi-coff
@ 2001-06-13 3:12 Schirmer, Hartmut
2001-06-13 8:47 ` Nick Clifton
0 siblings, 1 reply; 7+ messages in thread
From: Schirmer, Hartmut @ 2001-06-13 3:12 UTC (permalink / raw)
To: 'Nick Clifton'; +Cc: 'binutils@sources.redhat.com'
Hi Nick,
this didn't help.
I noticed two additional dwarf2 calls in tc-sh.c
const pseudo_typeS md_pseudo_table[] =
{
...
{"file", dwarf2_directive_file, 0 },
{"loc", dwarf2_directive_loc, 0 },
dwarf2_directive_file gets called
Hartmut
> -----Original Message-----
> From: Nick Clifton [ mailto:nickc@cambridge.redhat.com ]
> Sent: Tuesday, June 12, 2001 3:06 PM
> To: Schirmer, Hartmut
> Subject: Re: GAS 2.11.1 doesn't work for sh-hitachi-coff
>
>
> Hi Hartmut,
>
> > Seems to be a general problem. Using gas 2.11.1 fails for my target
> > too. I don't use debug information here (no -g to GCC).
>
> Hmm, in which case please could try the enclosed patch and let me know
> if it works.
>
> Cheers
> Nick
>
> Index: gas/config/tc-sh.c
> ===================================================================
> RCS file: /cvs/src/src/gas/config/tc-sh.c,v
> retrieving revision 1.38
> diff -p -r1.38 tc-sh.c
> *** tc-sh.c 2001/04/05 04:21:36 1.38
> --- tc-sh.c 2001/06/12 13:03:19
> *************** md_assemble (str)
> *** 1945,1951 ****
> --- 1945,1953 ----
> }
> }
>
> + #ifdef BFD_ASSEMBLER
> dwarf2_emit_insn (size);
> + #endif
> }
>
> /* This routine is called each time a label definition is seen. It
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* RE: GAS 2.11.1 doesn't work for sh-hitachi-coff
@ 2001-06-12 3:59 Schirmer, Hartmut
0 siblings, 0 replies; 7+ messages in thread
From: Schirmer, Hartmut @ 2001-06-12 3:59 UTC (permalink / raw)
To: 'Nick Clifton'; +Cc: 'binutils@sources.redhat.com'
Hi Nick,
> > for target sh-hitachi-coff. GAS from 2.11.1pre1 fails:
>
> > /cygdrive/c/TEMP/cc1oUj4A.s:1: Fatal error: dwarf2 is not supported
> > for this object file format
>
> This appears to be a gcc configuration problem. The COFF file format
> does not support the DWARF2 debug format, so gcc should not be
> producing it in the first place.
I managed to build GCC using gas 2.10.1 without any problem.
> I would suggest that you investigate why the STABS debug format is not
> being used by gcc.
Seems to be a general problem. Using gas 2.11.1 fails for my target
too. I don't use debug information here (no -g to GCC).
Hartmut
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2001-06-13 9:21 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-11 23:54 GAS 2.11.1 doesn't work for sh-hitachi-coff Schirmer, Hartmut
2001-06-12 3:54 ` Nick Clifton
2001-06-12 3:59 Schirmer, Hartmut
2001-06-13 3:12 Schirmer, Hartmut
2001-06-13 8:47 ` Nick Clifton
2001-06-13 9:14 Schirmer, Hartmut
2001-06-13 9:21 Schirmer, Hartmut
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).