summaryrefslogtreecommitdiffstats
path: root/src/target/firmware/comm/Makefile
blob: c2c6fcf01b640eb03dbe6dfd5efdc96315257bb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
INCLUDES=-I../include/
-include ../Makefile.inc

LIBNAME=comm
CSRCS=msgb.c sercomm.c sercomm_cons.c
SSRCS=

COBJS=$(CSRCS:.c=.o)
SOBJS=$(SSRCS:.S=.o)
OBJS=$(COBJS) $(SOBJS)

LST=$(OBJS:.o=.lst)

all:	lib$(LIBNAME).a

$(COBJS): %.o : %.c
	$(CROSS_COMPILE)$(CC) $(CFLAGS) -c -o $@ $^

$(SOBJS): %.o : %.S
	$(CROSS_COMPILE)$(CC) $(ASFLAGS) -c -o $@ $^

lib$(LIBNAME).a: $(OBJS)
	$(CROSS_COMPILE)$(AR) cru $@ $^

clean:
	rm -f *.a $(OBJS) $(LST)