Re: [uCsimm] fprintf crashes

From: David McCullough (davidm@lineo.com)
Date: Mon Apr 23 2001 - 07:31:45 EDT


Jivin Ashwin lays it down ...
> Hello friends,
> I wrote small code which does nothing but use fprintf to print to stderr
> Here is the c code
> #include<stdio.h>
>
> main (int argc, char* argv[]) {
>
> int result;
>
> fprintf(stderr,"In Main\n");
>
> }
>
> my problem is that the same code works on 2.0.38.
> I compiled the same code for 2.4.x using m68k-elf gcc
> with command "m68k-elf-gcc -o fp.elf fp.c -Wl, -elf2flt"
> the code genrerated does not work and crashes while if the same code is compiled
> using m68k-pic-coff-gcc it works in the 2.4.x kernel .
> What might be the problem.
> Please help me out

Try the following:

        m68k-elf-gcc -m68000 -o fp.elf fp.c -Wl, -elf2flt

You need to tell the elf compiler which CPU type to use. For the uCsimm
this is 68000,

Cheers,
Davidm

-- 
David McCullough:  Ph: +61 7 3435 2815  Lineo (The Embedded Solutions Company)
davidm@lineo.com   Fx: +61 7 3891 3630  PO Box 925, Kenmore QLD 4069, Australia
This message resent by the ucsimm@uclinux.com list server http://www.uClinux.com/



This archive was generated by hypermail 2b30 : Sun Apr 07 2002 - 00:01:43 EST