Spam:**********, Re: Spam:**********, Re: objcopy problems

Chris Johns <[email protected]> Tue, 12 Aug 2008 08:00:07 +1000
Newsgroups gmane.comp.hardware.motorola.microcontrollers.coldfire
Message-ID <[email protected]>
X-SpamDetect-Info: ------------- Start ASpam results ---------------
X-SpamDetect-Info: This message may be spam. This message BODY has been altered to show you the spam information 
X-SpamDetect: **********: 10.400001 From3consonants=0.3, SPF Soft=3.0, Symbol & DodgySrc=2.0, DodgySource=2.0, SPF Default Fail=2.5, X-Verify-SMTP present=0.6
X-SpamDetect-Info: ------------- End ASpam results -----------------

Jaysen Roper wrote:
> I installed the elf toolchain from codesourcery, it went on easily enough
> and after sorting out PATH environments it works fine alongside our original
> gnu install. I can use both toolchains independently.
> 
> But the elf-objcopy doesn't work when used with our coff-build (although it
> doesn't crash)
> 
> C:\Games\heber\demo>m68k-elf-objcopy --debugging -O ieee -R .id -R .system
> demo.cof demo.iee
> demo.cof: .stab: stab entry 1 is corrupt, strx = 0xd3000000, type = 8
> demo.cof: .stab: stab entry 3 is corrupt, strx = 0x0, type = 37
> demo.cof: .stab: stab entry 4 is corrupt, strx = 0x0, type = 84
> demo.cof: .stab: stab entry 5 is corrupt, strx = 0x0, type = 110
> demo.cof: .stab: stab entry 6 is corrupt, strx = 0x0, type = 162
> demo.cof: .stab: stab entry 7 is corrupt, strx = 0x0, type = 218
> demo.cof: .stab: stab entry 8 is corrupt, strx = 0x1, type = 23
> 
> ---------------------------
> 
> So it looks like I cant mix toolchain tools. (mix coff compilers and elf
> objcopy)

For my tools which are rtems ones the BFD support for coff is built into the 
elf build of objcopy. I suspect the Codesourcery tools are the same. This 
looks like a bug in the old compiler and the coff debug information.

$ /opt/rtems-4.9/bin/m68k-rtems4.9-objcopy
     [ snip ]
/opt/rtems-4.9/bin/m68k-rtems4.9-objcopy: supported targets: elf32-m68k 
coff-m68k versados ieee a.out-zero-big elf32-l             ittle elf32-big 
srec symbolsrec tekhex binary ihex

> I've tried a full rebuild with the new ELF toolchain but get architecture
> problems with our libraries at ld stage.
> The example below is a single example, every .o file in our library (3rd
> party, no src) produces this error.
> 
> m68k-elf-ld: m68k:68020 architecture of input file
> `/heber/pluto6/libs/gnu/pluto6\libdbug.a(dbug-outbyte.o)' is incompatible
> with m68k:isa-a:nodiv output

You need to provide the command line used to build the object file. At a guess 
it looks like the options you used to build the dbug-outbyte.o are wrong. 
Please try:

$ m68k-elf-gcc --target-help

and check your compile options.

> So It looks like my libraries are compiled as 68020 (and I cant change that)
> And the codesourcery tools are hardcoded to  isa-a (coldfire) 

I doubt this. I think they will have multilib'ed their tools.

> 
> Is there an old coff-objcopy out there I could use? I don't have the means
> to rebuild it though. My version is 2.9.1 (1997)
> 

Given the age of the tools you are using it will be difficult.

Regards
Chris
---
[email protected]              Send a post to the list.
[email protected]        Join the list.
[email protected]    Join the list in digest mode.
[email protected]     Leave the list.