This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gold link script problem


Hi all,

I'm currently in the process of converting an embedded project to using GCC4.6 with lto and gold and I'm running into a problem with some of my link scripts.

These scripts start with a MEMORY section:

MEMORY {
int_flash (rx) : ORIGIN = 0x00000000, LENGTH = 2M
int_sram (wiax) : ORIGIN = 0x40000000, LENGTH = 32k
int_srambb (wiax) : ORIGIN = 0x40008000, LENGTH = 32k /* battery backed */
ext_ram (wiax) : ORIGIN = 0x20000000, LENGTH = 512k
}


When gold encounters this it barfs with:

error: ./ppc/e7/boot.ld:5:5: syntax error, unexpected STRING, expecting ':'

on the int_sram line.

If i simplify the MEMORY section to:

MEMORY {
    int_flash (rx) :    ORIGIN = 0x00000000, LENGTH = 2M
}

I get:

error: ./ppc/e7/boot.ld:5:1: syntax error, unexpected '}', expecting ':'

BFD ld is able to parse these scripts without any issue.

Has anything changed in the syntax for gold link scripts? I have searched through the binutils documentation and found nothing mentioned.

Thanks,

Patrick








Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]