comparison target-utils/loadagent/Makefile @ 991:5cff3579814c

target-utils: libbase factored out of libcommon The library dependency order is now strictly unidirectional
author Mychaela Falconia <falcon@ivan.Harhan.ORG>
date Wed, 30 Dec 2015 20:48:12 +0000
parents e7ba9fcb3637
children
comparison
equal deleted inserted replaced
990:2a867e5768e9 991:5cff3579814c
6 6
7 INSTDIR=/usr/local/share/freecalypso 7 INSTDIR=/usr/local/share/freecalypso
8 8
9 PROG= loadagent 9 PROG= loadagent
10 OBJS= crt0.o cmdtab.o main.o mygetchar.o 10 OBJS= crt0.o cmdtab.o main.o mygetchar.o
11 LIBS= ../libcommon/libcommon.a ../libload/libload.a ../libprintf/libprintf.a 11 LIBS= ../libload/libload.a ../libcommon/libcommon.a ../libprintf/libprintf.a \
12 ../libbase/libbase.a
12 LDS= ../env/iram.lds 13 LDS= ../env/iram.lds
13 14
14 TC_LIBS=`${CC} -print-file-name=libc.a` \ 15 TC_LIBS=`${CC} -print-file-name=libc.a` \
15 `${CC} -print-file-name=libgcc.a` 16 `${CC} -print-file-name=libgcc.a`
16 17
19 crt0.S: ../env/crt0.S 20 crt0.S: ../env/crt0.S
20 ln -s $< . 21 ln -s $< .
21 22
22 ${PROG}.elf: ${OBJS} ${LIBS} ${LDS} 23 ${PROG}.elf: ${OBJS} ${LIBS} ${LDS}
23 ${LD} -N --defsym Base_addr=0x838000 --defsym stack_bottom=0x83FFFC \ 24 ${LD} -N --defsym Base_addr=0x838000 --defsym stack_bottom=0x83FFFC \
24 -T ${LDS} -o $@ ${OBJS} \ 25 -T ${LDS} -o $@ ${OBJS} ${LIBS} \
25 --start-group ${LIBS} --end-group \
26 --start-group ${TC_LIBS} --end-group 26 --start-group ${TC_LIBS} --end-group
27 27
28 ${PROG}.srec: ${PROG}.elf 28 ${PROG}.srec: ${PROG}.elf
29 ${OBJCOPY} -O srec --srec-forceS3 --srec-len=30 $< $@ 29 ${OBJCOPY} -O srec --srec-forceS3 --srec-len=30 $< $@
30 30