Hi there,

I have this problem that is surely an easy one. I am trying to convert a rather
big Palm OS app (55 KB PRC) from Windows/CodeWarrior to UNIX/GNU/prc-tools. I
have already resolved a bunch of other gotchas, but this one is stopping me.
After all .o's are produced successfully and it's time to link them all into
one COFF to be obj-res'ed, the linking fails miserably. It says "region coderes
is full", followed by screen after screen of messages of the form:

foo.o(.text+0xaa):foo.c: relocation truncated to fit: DISP16 BarMyFunction

Help! How can I fix this?

The messages about DISP16 suggest that it's using 16-bit displacements in
function call instructions. Is there any way to make it use 32-bit ones? I was
told that CodeWarrior has something called "large model" or something like that
which does exactly this, and the app I'm porting had that turned on. Does the
GNU m68k-palmos-coff toolchain have anything similar?

And what is that message about region coderes being full? Is it telling me that
I can't fit this app into one segment? Then how did it fit in a 55 KB PRC (with
resources) under CodeWarrior? gcc's gotta be a better optimizing compiler than
CodeWarrior, isn't it?

I'm using the prc-tools v0.5.0 kit, i.e., I have installed gcc v2.7.2.2 and
binutils v2.7 as instructed in the kit and applied the patches from that kit.

$ m68k-palmos-coff-gcc -v
Reading specs from 
/usr/local/gnu/lib/gcc-lib/m68k-palmos-coff/2.7.2.2-kgpd-071097/specs
gcc version 2.7.2.2-kgpd-071097
$ m68k-palmos-coff-as -v
GNU assembler version 2.7 (m68k-palmos-coff)

TIA for any help.

Michael Sokolov

Reply via email to