Every version of mini dev kit uses the same md.ld file. I was speaking about the ld file you can file on some XGCC for 68k cpu. Anyway i checked them and they are even more buggy...Chilly Willy wrote:As I mentioned above, it gave that error with every version of gcc from 3.4.0 to 4.1.1. I've decided to stick with 4.1.1 for the moment. Someone at Novell maintains the m68k cross compiler, updating to the current stable gcc and compiling rpms for 586 and x86_64 (the one I'm using).Stef wrote:So it's the md.ld file which is probably not compatible with your GCC version. I modified it compared to the original one, i did some minors tweaks and corrections but maybe they are not correct.
What version of GCC are you using ? I guess you need to replace all the binary and the libc file with your linux version ?
I recompiled all the lib files, and have it using the libgcc.a that comes with the cross compiler. A quick look at the code generated doesn't reveal anything out of the ordinary. I'm still using the md.ld from the version 4 devkit with BLOCK (0x4) removed. Should I try an older version?
Try to replace the
".data BLOCK (0x4) :"
by
".data 0xff0000 :"
In fact the .data section isn't usable with genesis as the compiler doesn't have code to init data in memory. We have to *always* use unitialised variable then initialize them in code otherwise the compiler generate an error message. Hopefully we can survive without it constantes are of course possible, only initialised variables is not allowed.
By the way, did you know a way to force the compiler to use register instead of stack to pass parameters ? i compiled severals version of GCC here and the optimisations are not good. I've the best result with -O1 and GCC 2.8 gives exactly the same result as 4.1... it's a bit disapointing :-/