<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-15">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi all,<br>
I compiled a simple "Hello word" C program with sparc-rtems-gcc
v4.10.<br>
I tested it with TSIM sparc simulator and it works.<br>
I also developed a toolchain to load program on a leon2 board that
convert <br>
a .exe file into a .hex file but the program doesn't work.<br>
The same program, compiled with sparc-elf-gcc and converted with the
same<br>
toolchain works with no problem. <br>
Here's summerized my toolchain:<br>
<br>
<small>CC = sparc-rtems-gcc<br>
<br>
CFLAGS = -msoft-float -qleon2 -mcpu=v8<br>
LIBS = -lgcc -lm -msoft-float<br>
LDFLAGS = -mcpu=v8<br>
<br>
$(CC) $(LDFLAGS) $(SOURCES) $(LIBS) -o $@.exe<br>
cp $@.exe <a class="moz-txt-link-abbreviated" href="mailto:u$@.exe">u$@.exe</a> <br>
sparc-rtems-objdump -d $@.exe > $(<a class="moz-txt-link-abbreviated" href="mailto:OUTDIR)/$@.disas">OUTDIR)/$@.disas</a> <br>
sparc-rtems-strip $@.exe <br>
sparc-rtems-objcopy --remove-section=.comment $@.exe<br>
sparc-rtems-objdump -s $@.exe > $@.dat <br>
sparc-rtems-size $@.exe<br>
Dat2Hex.pl $@.dat text > code.hex<br>
Dat2Hex.pl $@.dat data > data.hex<br>
cat code.hex data.hex > program.hex</small><br>
<br>
I have two question:<br>
1) can the toolchain also be used for sparc-rtems-gcc?<br>
2) shall I necessary use mkprom to create a loadble program or <br>
another kind of toolchain can be used?<br>
<br>
Thank a lot for your answer<br>
<br>
Luca<br>
</body>
</html>