comparison target-utils/buzplayer/Makefile @ 76:5bbba2cab6f3

target-utils: buzplayer started
author Mychaela Falconia <falcon@freecalypso.org>
date Thu, 27 Oct 2016 03:50:40 +0000
parents
children 0f11da299b7d
comparison
equal deleted inserted replaced
75:bbc41034f14c 76:5bbba2cab6f3
1 CC= arm-elf-gcc
2 CFLAGS= -Os -fno-builtin
3 CPPFLAGS=-I../include
4 LD= arm-elf-ld
5 OBJCOPY=arm-elf-objcopy
6
7 INSTDIR=/opt/freecalypso/target-bin
8
9 PROG= buzplayer
10 OBJS= crt0.o cmdtab.o main.o mygetchar.o
11 LIBS= ../libcommon/libcommon.a ../libprintf/libprintf.a ../libbase/libbase.a
12 LDS= ../env/iram.lds
13
14 TC_LIBS=`${CC} -print-file-name=libc.a` \
15 `${CC} -print-file-name=libgcc.a`
16
17 all: ${PROG}.srec
18
19 crt0.S: ../env/crt0.S
20 ln -s $< .
21
22 ${PROG}.elf: ${OBJS} ${LIBS} ${LDS}
23 ${LD} -N --defsym Base_addr=0x800750 --defsym stack_bottom=0x83FFFC \
24 -T ${LDS} -o $@ ${OBJS} ${LIBS} \
25 --start-group ${TC_LIBS} --end-group
26
27 ${PROG}.srec: ${PROG}.elf
28 ${OBJCOPY} -O srec --srec-forceS3 --srec-len=30 $< $@
29
30 install:
31 mkdir -p ${INSTDIR}
32 install -c -m 644 ${PROG}.srec ${INSTDIR}
33
34 clean:
35 rm -f *.o *errs *core *.elf *.bin *.srec crt0.S
36
37 FRC: