FreeCalypso > hg > freecalypso-sw
diff nuc-fw/finlink/Makefile @ 80:39b1c369b67f
nuc-fw: links to an ELF image
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Fri, 16 Aug 2013 02:25:58 +0000 |
parents | |
children | 147861b15cda |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/nuc-fw/finlink/Makefile Fri Aug 16 02:25:58 2013 +0000 @@ -0,0 +1,35 @@ +CC= arm-elf-gcc +LD= arm-elf-ld +OBJCOPY=arm-elf-objcopy + +RAM_TARGET= ramImage.elf + +LIBC_A= `${CC} -print-file-name=libc.a -mthumb-interwork` +LIBC_T= `${CC} -print-file-name=libc.a -mthumb-interwork -mthumb` +LIBGCC_A= `${CC} -print-file-name=libgcc.a -mthumb-interwork` +LIBGCC_T= `${CC} -print-file-name=libgcc.a -mthumb-interwork -mthumb` + +LOCAL_LIBS= ../nucleus/libplus.iram.a ../nucleus/libplus.xip.a \ + ../sprintf/libsprintf.a + +INT_PIECES= ../sysglue/sysinit.o +EXT_PIECES= ../nucdemo/demo.o + +all: ${RAM_TARGET} +ramImage: ${RAM_TARGET} + +iramcode.o: ${INT_PIECES} + ${LD} -r -o $@ ${INT_PIECES} + +xipcode.o: ${EXT_PIECES} + ${LD} -r -o $@ ${EXT_PIECES} + +ramImage.elf: iramcode.o xipcode.o ${LOCAL_LIBS} xram.lds + ${LD} -N -T xram.lds -o $@ -Map ramImage.map iramcode.o xipcode.o \ + --start-group ${LOCAL_LIBS} --end-group \ + --start-group ${LIBC_A} ${LIBGCC_A} --end-group + +clean: + rm -f *.o *errs *core *.elf *.bin *.srec + +FRC: