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

See the CrossGCC FAQ for lots more information.


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

Re: Help needed


Hua Ji wrote:
> 
> Hua: Thanks a lot. I tried with -msim. All done perfectly, after libc.a and
> __start symbol being linked from sim-crt0.o! This is exactly what I got
> stuck yesterday--the linker can't go **automatically** link my libc.a and
> __start codes. I guess the story behind my case is:
> When I did the cross compiler, I didn't(or couldnot?) specify Operating
> System target, but only specify a powerp elf target, so the gcc and the
> corresponding linker(ld) can't know how to look for which libc and __start
> symbols(or codes)? Am I right? Please continuly educate me. Thanks in
> advance.

 Yes, this is the case, the 'powerpc*-elf' and 'powerpc*-eabi' targets don't
have a default system for which to produce executables. So the '-m<board>'
must be used. This could be taken as a bug, adding the extra '-mads' or '-msim'
or something into the CFLAGS_FOR_TARGET for 'powerpc*-elf' and 'powerpc*-eabi'
targets during configure cannot be hard, just as there are those '-Os' additions
for some targets.

 One reason to the current situation could be that the user is tried to
educate with this way. But why the Motorola and MIPS chips are those lacking
the default while ARM, SH, H8/300, MN10200, MN10300, M32R etc. have a default
system I cannot explain... Perhaps they are thought to be more clever, while
the ARM, SH, etc. users must have everything working 'out of the box' ;-)

Cheers, Kai


------
Want more information?  See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/
Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.cygnus.com


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