This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: How to debug "relocation truncated" error.
- To: Doug Broadwell <dougb at value dot net>
- Subject: Re: How to debug "relocation truncated" error.
- From: Carlo Wood <carlo at alinoe dot com>
- Date: Sat, 18 Aug 2001 17:51:12 +0200
- Cc: bug-gcc at gnu dot org
- References: <00d101c12756$f577e2b0$23fea8c0@value.net>
On Fri, Aug 17, 2001 at 12:58:14PM -0700, Doug Broadwell wrote:
> Hi,
>
> I'm cross compiling code using the m68k-pic-coff-gcc compiler, version
> 2.7.2.3-pic-060999, on an Intel Linux machine . The command line:
>
> m68k-pic-coff-gcc main.c monitor.o graph.o
>
> results in the error:
>
> monitor.o(.text+0xdf8):monitor.c: relocation truncated to fit: DISP16
> data
>
> I don't know how to go about debugging this error as the assembly output
> does not give address information (nor the C code interleaved with the
> assembly code). It does not generate the executable so I can't debug using
> GDB (assuming I got it set up to work on the remote machine).
>
> Help!
>
> Thanks, Doug Broadwell
The easiest way to find .text+0xdf8 is by doing:
nm monitor.o | sort
Then look for the symbol (function) name that starts on or before 0xdf8
(the first column). I don't know what "relocation truncated" means.
--
Carlo Wood <carlo@alinoe.com>