This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
RE: forwarded message from Simpkins, Andy
- To: Mark Salter <msalter at redhat dot com>, jskov at redhat dot com
- Subject: RE: [ECOS] forwarded message from Simpkins, Andy
- From: "Simpkins, Andy" <Andy dot Simpkins at Transcomm dot uk dot com>
- Date: Fri, 17 Aug 2001 15:05:23 +0100
- Cc: ecos-discuss at sources dot redhat dot com
OK that stops the compiler error but I now get
arm-elf-gcc *.o ../../API/*/*.o -L /i/eCOSbuilds/a161_install/lib/
-Ttarget.ld -nostdlib -Xlinker -Map -Xlinker mapfile.txt
main.o: In function `main':
main.o(.text+0x1cc): relocation truncated to fit: R_ARM_PC24
flash_query(void *)
collect2: ld returned 1 exit status
any ideas?
Andy
> -----Original Message-----
> From: Mark Salter [mailto:msalter@redhat.com]
> Sent: 17 August 2001 14:56
> To: jskov@redhat.com
> Cc: ecos-discuss@sources.redhat.com
> Subject: Re: [ECOS] forwarded message from Simpkins, Andy
>
>
> >>>>> Jesper Skov writes:
>
> >> void flash_query(void* data) __attribute__ ((section
> >> (".2ram.flash_query")));
> >>
>
> > this always gives a compiler error :
>
> > parse error before `{'
>
> > when I have the following function
>
> > void flash_query(void* data) __attribute__ ((section
> (".2ram.flash_query")))
> > {
> > // do something
> > }
>
> The attribute has to come before the function name, right. This
> should work:
>
> void __attribute__ ((section (".2ram.flash_query")))
> flash_query(void* data)
> {
> // do something
> }
>
> --Mark
>