[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [avr-chat] [AVR gcc linker error] relocation truncated to fit:R_AVR_
From: |
Weddington, Eric |
Subject: |
RE: [avr-chat] [AVR gcc linker error] relocation truncated to fit:R_AVR_13_PCREL ... |
Date: |
Fri, 18 Apr 2008 14:18:29 -0600 |
> -----Original Message-----
> From: address@hidden
> [mailto:address@hidden
> On Behalf Of eb
> Sent: Tuesday, April 15, 2008 9:46 AM
> To: address@hidden
> Subject: [avr-chat] [AVR gcc linker error] relocation
> truncated to fit:R_AVR_13_PCREL ...
>
>
> Hello,
> I get and install the last version of WinAVR (April 08 -GCC 4.3.0).
> I get this "relocation truncated to fit: R_AVR_13_PCREL"
> error during the
> link operation.
> I'm working with AVR Studio 4.12
>
> I've read i should add -lm to the linker command to avoid
> this...but no
> success :(
> So i need your help to avoid this problem!
<snip>
> Here is the build result:
> avr-gcc.exe -mmcu=atmega128 -lm -minit-stack=0xFF0
> -Wl,-Map=LCD.map main.o
> font8.o font74.o font62.o font54.o font48.o font46.o font36.o font72.o
> font24.o font12.o font106.o LCD128128fct.o lcd1font.o
> string_display_FR-EN.o
> usart.o eeprom.o Copernicus.o SP
> I16M.o GPS.o tactique.o ligne_depart.o SMG.o chrono_timer.o
> flash16M.o ADC.o
> angle_virement.o waypoint.o route.o USB16M.o histo_speed.o stats.o
> navigation_display.o sound.o display.o
> -L"C:\WinAVR-20080411\lib" -o
> LCD.elf
Try using the WinAVR Makefile Template (in <install>\sample), or MFile
(which uses the WinAVR Makefile Template internally) for your Makefile.
Typically -lm goes at the end of the command line.