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]

Can't Execute m68k Programs


Hello,
	I can compile and link programs successfully. I can also download and run 
programs that use the low level debug routines (putnum, print), however 
programs that contain standard routines (printf and puts) will not execute. 
My hello world program that uses printf generates an f-line exception. It is 
apparently trying to use hardware floating point calls even though I used 
-msoft-float. For the puts version, I get an illegal opcode, which appears to 
be in the memchr routine.
	My host is Redhat 7.1, my target is a MC68332 board 
running CPU32BUG. I believe I have the following installed correctly: 
binutils-2.9.1, gcc-2.95.1, and newlib-1.8.2. 
         I'm compiling with the following command:

m68k-coff-gcc -Wall -m68332 -mshort -msoft-float -c hello.c

I've modified the specs file to use bcc.ld and libbcc.a, I link with:

m68k-coff-gcc -Wall hello.o -o hello.s19

My questions:
1. Are there patches available for the versions of binutils, gcc, and newlib 
that I'm using, for m68k code generation?

2. Am I doing something wrong? I get no warnings or errors doing compiling, 
assembling, or linking.

3. Is this a gcc or newlib problem?

4. Is there a way to generate a complete listing file? One that has absolute 
addresses and assembly code? I can generate absolute addresses with 
m68-coff-nm, and individual assembly code by stopping gcc with -S. Is there a 
program that combines all these?

Thanks in Advance,
Larry D. Gray

------
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]