2012-02-05 14:01:28 -05:00
|
|
|
M2DIR=../..
|
2012-05-24 13:02:59 -04:00
|
|
|
include $(M2DIR)/software/common.mak
|
2012-02-03 06:08:17 -05:00
|
|
|
|
2013-05-19 13:44:00 -04:00
|
|
|
OBJECTS=setjmp.o libc.o errno.o crc16.o crc32.o console.o system.o id.o uart.o qsort.o strtod.o
|
2012-02-03 06:08:17 -05:00
|
|
|
|
2013-07-11 12:36:26 -04:00
|
|
|
all: crt0.o libbase.a libbase-nofloat.a
|
2012-02-05 14:01:28 -05:00
|
|
|
|
2012-02-03 06:25:55 -05:00
|
|
|
# pull in dependency info for *existing* .o files
|
|
|
|
-include $(OBJECTS:.o=.d)
|
|
|
|
|
2013-05-19 06:41:40 -04:00
|
|
|
libbase.a: $(OBJECTS) vsnprintf.o
|
|
|
|
$(AR) clr libbase.a $(OBJECTS) vsnprintf.o
|
2012-02-03 06:08:17 -05:00
|
|
|
$(RANLIB) libbase.a
|
|
|
|
|
2013-05-19 06:41:40 -04:00
|
|
|
libbase-nofloat.a: $(OBJECTS) vsnprintf-nofloat.o
|
|
|
|
$(AR) clr libbase-nofloat.a $(OBJECTS) vsnprintf-nofloat.o
|
|
|
|
$(RANLIB) libbase-nofloat.a
|
|
|
|
|
|
|
|
vsnprintf-nofloat.o: vsnprintf.c
|
|
|
|
$(call compile-dep,-DNO_FLOAT)
|
|
|
|
|
2012-05-31 14:17:33 -04:00
|
|
|
%.o: %.c
|
|
|
|
$(compile-dep)
|
|
|
|
|
2013-01-10 11:20:31 -05:00
|
|
|
%.o: %.S
|
|
|
|
$(assemble)
|
|
|
|
|
2012-02-03 06:08:17 -05:00
|
|
|
.PHONY: clean
|
|
|
|
|
|
|
|
clean:
|
2013-05-19 06:41:40 -04:00
|
|
|
$(RM) $(OBJECTS) $(OBJECTS:.o=.d) vsnprintf.o vsnprintf.d vsnprintf-nofloat.o vsnprintf-nofloat.d
|
|
|
|
$(RM) libbase.a libbase-nofloat.a .*~ *~
|