[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: Ashley Duncan
Subject: ld
Date: Wed, 26 Dec 2007 03:11:54 -0800

Hi there,
   I'm having some trouble using the linker...  I am using V4.1.2 as part of the WinAVR package.  The issue I am having is as follows...  The package includes a linker script named avr5.x.  In that script it has the line "PROVIDE(__heap_start = .)".  When I use the linker with --defsym=__heap_start=0x801100, the value generated for __heap_start by the provide is used (0x800124 in my case) rather than the --defsym value.  If I comment out the provide line in the linker script the compile fails with an error "Undefined reference to __heap_start" as my code references __heap_start to initialise the heap...  Should the --defsym not be providing __heap_start to my code in the absence of the provide() statement?  And the --defsym should also override the provide() statement!
   I am not 100% sure this is a bug, but cant find any other explanation.  Some forum searches reveled some mention of the command line not working in this case.  I image this would be a commonly used command line option so should be OK???
   Any help would be greatly appreciated...  I have attached the linker script and makefiles in case they are of use...

Attachment: Makefile
Description: Text document

Attachment: avr5.x
Description: Text document

reply via email to

[Prev in Thread] Current Thread [Next in Thread]