The following script returns an error "nonconstant expression for origin".
Any reasions why symbols are not allowed?

FLASH_START = 0x10000;
FLASH_END   = 0x20000;

RAM_START   = 0x80000;
RAM_END     = 0x90000;

MEMORY {
    FLASH : ORIGIN = FLASH_START, LENGTH = FLASH_END - FLASH_START
    RAM   : ORIGIN = RAM_START,   LENGTH = RAM_END - RAM_START
}


FYI: A similar problem is also described here
http://www.cygwin.com/ml/binutils/2004-03/msg00540.html

-- 
           Summary: linker scripts do not accept symbols in MEMORY section
           Product: binutils
           Version: 2.15
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: unassigned at sources dot redhat dot com
        ReportedBy: axelheider at gmx dot de
                CC: bug-binutils at gnu dot org
  GCC host triplet: i386/cygwin
GCC target triplet: ARM


http://sourceware.org/bugzilla/show_bug.cgi?id=4643

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


_______________________________________________
bug-binutils mailing list
bug-binutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-binutils

Reply via email to