FreeCalypso > hg > freecalypso-sw
annotate target-utils/helloapp/Makefile @ 1024:1886238653b8
loadtools/scripts/fcfam.config added
author | Mychaela Falconia <falcon@ivan.Harhan.ORG> |
---|---|
date | Tue, 03 May 2016 19:51:41 +0000 |
parents | 5cff3579814c |
children |
rev | line source |
---|---|
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
1 CC= arm-elf-gcc |
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
2 CFLAGS= -Os -fno-builtin |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
3 CPPFLAGS=-I../include |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
4 LD= arm-elf-ld |
6
5eaafa83be60
loadagent: generate binary and srec images
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
5
diff
changeset
|
5 OBJCOPY=arm-elf-objcopy |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
6 |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
7 PROG= helloapp |
14
f0501c4a8790
helloapp (proto-loadagent) compiles with r8/r16/r32 implemented
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
11
diff
changeset
|
8 OBJS= crt0.o cmdtab.o main.o mygetchar.o |
991
5cff3579814c
target-utils: libbase factored out of libcommon
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
629
diff
changeset
|
9 LIBS= ../libcommon/libcommon.a ../libprintf/libprintf.a ../libbase/libbase.a |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
10 LDS= ../env/iram.lds |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
11 |
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
12 TC_LIBS=`${CC} -print-file-name=libc.a` \ |
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
13 `${CC} -print-file-name=libgcc.a` |
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
14 |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
15 all: ${PROG}.srec |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
16 |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
17 crt0.S: ../env/crt0.S |
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
18 ln -s $< . |
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
19 |
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
20 ${PROG}.elf: ${OBJS} ${LIBS} ${LDS} |
629
e7ba9fcb3637
target-utils: move loadagent to 0x838000 in preparation for ramImages that
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
14
diff
changeset
|
21 ${LD} -N --defsym Base_addr=0x800750 --defsym stack_bottom=0x83FFFC \ |
991
5cff3579814c
target-utils: libbase factored out of libcommon
Mychaela Falconia <falcon@ivan.Harhan.ORG>
parents:
629
diff
changeset
|
22 -T ${LDS} -o $@ ${OBJS} ${LIBS} \ |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
23 --start-group ${TC_LIBS} --end-group |
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
24 |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
25 ${PROG}.srec: ${PROG}.elf |
6
5eaafa83be60
loadagent: generate binary and srec images
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
5
diff
changeset
|
26 ${OBJCOPY} -O srec --srec-forceS3 --srec-len=30 $< $@ |
5eaafa83be60
loadagent: generate binary and srec images
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
5
diff
changeset
|
27 |
2
ddda170fa6f4
loadagent.elf compiled and linked, no printf yet
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
diff
changeset
|
28 clean: |
11
40f607bb0a2c
target-utils refactored
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
6
diff
changeset
|
29 rm -f *.o *errs *core *.elf *.bin *.srec crt0.S |
5
4a7a325ed1b6
loadagent: printf hooked in
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
2
diff
changeset
|
30 |
4a7a325ed1b6
loadagent: printf hooked in
Michael Spacefalcon <msokolov@ivan.Harhan.ORG>
parents:
2
diff
changeset
|
31 FRC: |